|
|
|
|
Ext.namespace('Shipping');
|
|
|
|
|
|
|
|
|
|
Shipping.ChPayapplicationAudit = function (config) {
|
|
|
|
|
Ext.applyIf(this, config);
|
|
|
|
|
this.initUIComponents();
|
|
|
|
|
window.Shipping.ChPayapplicationAudit.superclass.constructor.call(this);
|
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
Ext.extend(Shipping.ChPayapplicationAudit, Ext.Panel, {
|
|
|
|
|
PageSize: 15,
|
|
|
|
|
OprationStatus: null, //仅当弹出界面时使用
|
|
|
|
|
SelectedRecord: null,
|
|
|
|
|
isAudit: '',
|
|
|
|
|
BodyPageSize: 50,
|
|
|
|
|
|
|
|
|
|
initUIComponents: function () {
|
|
|
|
|
this.formname = "formChPayapplicationAudit"
|
|
|
|
|
//定义数据集
|
|
|
|
|
this.worksql = getUrlParam('worksql');
|
|
|
|
|
this.BillSql = '';
|
|
|
|
|
this.billno = '11';
|
|
|
|
|
this.Parentsql = '1=2';
|
|
|
|
|
this.isuseexrate = 0;
|
|
|
|
|
this.YJFEENAME = '';
|
|
|
|
|
this.YJFEENAMEUSD = '';
|
|
|
|
|
Ext.define('MsOPGain', {
|
|
|
|
|
extend: 'Ext.data.Model',
|
|
|
|
|
idProperty: 'GId',
|
|
|
|
|
fields: [
|
|
|
|
|
{ name: 'CURR', type: 'string' },
|
|
|
|
|
{ name: 'NORATEDR', type: 'number' },
|
|
|
|
|
{ name: 'DR', type: 'number' },
|
|
|
|
|
{ name: 'BALDR', type: 'number' },
|
|
|
|
|
{ name: 'NORATECR', type: 'number' },
|
|
|
|
|
{ name: 'CR', type: 'number' },
|
|
|
|
|
{ name: 'NORATEPR', type: 'number' },
|
|
|
|
|
{ name: 'PR', type: 'number' },
|
|
|
|
|
{ name: 'PROFITRATE', type: 'number' }
|
|
|
|
|
|
|
|
|
|
]
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
this.storeList = Ext.create('Ext.data.Store', {
|
|
|
|
|
pageSize: this.PageSize,
|
|
|
|
|
model: 'MsChPayapplication',
|
|
|
|
|
remoteSort: true,
|
|
|
|
|
proxy: {
|
|
|
|
|
type: 'ajax',
|
|
|
|
|
url: '/Account/Chfee_payapplication/GetAuditDataList',
|
|
|
|
|
reader: {
|
|
|
|
|
id: 'BILLNO',
|
|
|
|
|
root: 'data',
|
|
|
|
|
totalProperty: 'totalCount'
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
this.initgirdcolums = [{
|
|
|
|
|
sortable: true,
|
|
|
|
|
dataIndex: 'BILLNO',
|
|
|
|
|
header: Zi.LAN.RequisitionNumber, //申请单号
|
|
|
|
|
width: 120
|
|
|
|
|
}, {
|
|
|
|
|
sortable: true,
|
|
|
|
|
dataIndex: 'BILLSTATUSREF',
|
|
|
|
|
header: Zi.LAN.status, //状态
|
|
|
|
|
width: 80,
|
|
|
|
|
renderer: function (value, meta, record) {
|
|
|
|
|
value = record.data.BILLSTATUSREF;
|
|
|
|
|
if (value == '审核通过') {
|
|
|
|
|
meta.tdCls = 'feestatus_pass';
|
|
|
|
|
value = Zi.LAN.SHENHETONGGUO;
|
|
|
|
|
} else if (value == '录入状态') {
|
|
|
|
|
value = Zi.LAN.LURUZHUAGNTAI;
|
|
|
|
|
} else if (value == '已提交') {
|
|
|
|
|
meta.tdCls = 'feestatus_refer';
|
|
|
|
|
value = Zi.LAN.TIJIAOSHENHE;
|
|
|
|
|
} else if (value == '部分结算') {
|
|
|
|
|
meta.tdCls = 'feestatus_refer';
|
|
|
|
|
value = Zi.LAN.BUFENJIESUAN;
|
|
|
|
|
} else if (value == '已结算') {
|
|
|
|
|
meta.tdCls = 'feestatus_settle';
|
|
|
|
|
value = Zi.LAN.JIESUANWANBI;
|
|
|
|
|
}
|
|
|
|
|
return value;
|
|
|
|
|
}
|
|
|
|
|
}, {
|
|
|
|
|
sortable: true,
|
|
|
|
|
dataIndex: 'CUSTOMERNAME',
|
|
|
|
|
header: Zi.LAN.SettlementUnit, //结算单位
|
|
|
|
|
width: 120
|
|
|
|
|
}, {
|
|
|
|
|
sortable: true,
|
|
|
|
|
dataIndex: 'CURR',
|
|
|
|
|
header: Zi.LAN.Currency, //币别
|
|
|
|
|
width: 50
|
|
|
|
|
}, {
|
|
|
|
|
sortable: true,
|
|
|
|
|
dataIndex: 'AMOUNTRMB',
|
|
|
|
|
header: 'RMB',
|
|
|
|
|
renderer: function (value, cellmeta, record, rowIndex, columnIndex, store) { try { var lsValue = usMoney(value, 2, '', false); if (lsValue != "NaN") { value = lsValue; if (parseFloat(lsValue) < 0) { return '<SPAN style="COLOR: red">' + lsValue + '</SPAN>'; } } else { return value; } } catch (e) { return value; } return value; },
|
|
|
|
|
align: 'right',
|
|
|
|
|
width: 120
|
|
|
|
|
}, {
|
|
|
|
|
sortable: true,
|
|
|
|
|
dataIndex: 'AMOUNTUSD',
|
|
|
|
|
header: 'USD',
|
|
|
|
|
renderer: function (value, cellmeta, record, rowIndex, columnIndex, store) { try { var lsValue = usMoney(value, 2, '', false); if (lsValue != "NaN") { value = lsValue; if (parseFloat(lsValue) < 0) { return '<SPAN style="COLOR: red">' + lsValue + '</SPAN>'; } } else { return value; } } catch (e) { return value; } return value; },
|
|
|
|
|
align: 'right',
|
|
|
|
|
width: 120
|
|
|
|
|
}, {
|
|
|
|
|
sortable: true,
|
|
|
|
|
dataIndex: 'AMOUNTOT',
|
|
|
|
|
header: Zi.LAN.OtherBi,
|
|
|
|
|
renderer: function (value, cellmeta, record, rowIndex, columnIndex, store) { try { var lsValue = usMoney(value, 2, '', false); if (lsValue != "NaN") { value = lsValue; if (parseFloat(lsValue) < 0) { return '<SPAN style="COLOR: red">' + lsValue + '</SPAN>'; } } else { return value; } } catch (e) { return value; } return value; },
|
|
|
|
|
align: 'right',
|
|
|
|
|
width: 120
|
|
|
|
|
}, {
|
|
|
|
|
sortable: true,
|
|
|
|
|
dataIndex: 'STLAMOUNT',
|
|
|
|
|
header: Zi.LAN.STLAMOUNT,
|
|
|
|
|
renderer: function (value, cellmeta, record, rowIndex, columnIndex, store) { try { var lsValue = usMoney(value, 2, '', false); if (lsValue != "NaN") { value = lsValue; if (parseFloat(lsValue) < 0) { return '<SPAN style="COLOR: red">' + lsValue + '</SPAN>'; } } else { return value; } } catch (e) { return value; } return value; },
|
|
|
|
|
align: 'right',
|
|
|
|
|
width: 120
|
|
|
|
|
}, {
|
|
|
|
|
sortable: true,
|
|
|
|
|
dataIndex: 'APPLYTIME',
|
|
|
|
|
header: Zi.LAN.DateApplication, //申请日期
|
|
|
|
|
width: 100
|
|
|
|
|
}, {
|
|
|
|
|
sortable: true,
|
|
|
|
|
dataIndex: 'APPLICANTNAME',
|
|
|
|
|
header: Zi.LAN.Applicant, //申请人
|
|
|
|
|
width: 100
|
|
|
|
|
}, {
|
|
|
|
|
sortable: true,
|
|
|
|
|
dataIndex: 'AUDITTIME',
|
|
|
|
|
header: Zi.LAN.FinalReviewDate, //最后审核日期
|
|
|
|
|
width: 100
|
|
|
|
|
}, {
|
|
|
|
|
sortable: true,
|
|
|
|
|
dataIndex: 'AUDITUSER',
|
|
|
|
|
header: Zi.LAN.lastReviewer, //最后审核人
|
|
|
|
|
width: 100
|
|
|
|
|
}, {
|
|
|
|
|
sortable: true,
|
|
|
|
|
dataIndex: 'PAYABLETIME',
|
|
|
|
|
header: Zi.LAN.ApplyPaymentDate, //申请支付日期
|
|
|
|
|
width: 100
|
|
|
|
|
}, {
|
|
|
|
|
sortable: true,
|
|
|
|
|
dataIndex: 'ISINVOICE',
|
|
|
|
|
header: Zi.LAN.Invoiced, //已开发票
|
|
|
|
|
width: 160,
|
|
|
|
|
renderer: function (value, meta) {
|
|
|
|
|
|
|
|
|
|
if (value == '是')
|
|
|
|
|
return Zi.LAN.YES; //是
|
|
|
|
|
else
|
|
|
|
|
return '';
|
|
|
|
|
}
|
|
|
|
|
}, {
|
|
|
|
|
sortable: true,
|
|
|
|
|
dataIndex: 'INVNO',
|
|
|
|
|
header: Zi.LAN.InvoiceNumber, //发票号
|
|
|
|
|
width: 160
|
|
|
|
|
}, {
|
|
|
|
|
sortable: true,
|
|
|
|
|
dataIndex: 'SETTLETYPEREF',
|
|
|
|
|
header: Zi.LAN.jstype, //委托单位
|
|
|
|
|
width: 160
|
|
|
|
|
}, {
|
|
|
|
|
sortable: true,
|
|
|
|
|
dataIndex: 'BS_CUSTOMERNAME',
|
|
|
|
|
header: Zi.LAN.Requester, //委托单位
|
|
|
|
|
width: 160
|
|
|
|
|
}, {
|
|
|
|
|
sortable: true,
|
|
|
|
|
dataIndex: 'REMARK',
|
|
|
|
|
header: Zi.LAN.Remarks, //备注
|
|
|
|
|
width: 160
|
|
|
|
|
}, {
|
|
|
|
|
sortable: true,
|
|
|
|
|
dataIndex: 'REASON',
|
|
|
|
|
header: Zi.LAN.REASON, //备注
|
|
|
|
|
width: 160
|
|
|
|
|
}, {
|
|
|
|
|
sortable: true,
|
|
|
|
|
dataIndex: 'SALECORP',
|
|
|
|
|
header: Zi.LAN.DepartmentName, //备注
|
|
|
|
|
width: 160
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
sortable: true,
|
|
|
|
|
id: '',
|
|
|
|
|
dataIndex: 'ISPRINT',
|
|
|
|
|
header: Zi.LAN.printy, //'应收费用',
|
|
|
|
|
align: 'center',
|
|
|
|
|
width: 60,
|
|
|
|
|
renderer: function (value, meta) {
|
|
|
|
|
|
|
|
|
|
if (value == '1')
|
|
|
|
|
return Zi.LAN.YES ; //是
|
|
|
|
|
else
|
|
|
|
|
return '';
|
|
|
|
|
}
|
|
|
|
|
}, {
|
|
|
|
|
sortable: true,
|
|
|
|
|
dataIndex: 'APPLICANTDEPT',
|
|
|
|
|
header: Zi.LAN.APPLICANTDEPT, //驳回原因
|
|
|
|
|
width: 80
|
|
|
|
|
}, {
|
|
|
|
|
sortable: true,
|
|
|
|
|
dataIndex: 'PRINTCOUNT',
|
|
|
|
|
header: Zi.LAN.PRINTCOUNT, //驳回原因
|
|
|
|
|
width: 80
|
|
|
|
|
}, {
|
|
|
|
|
sortable: true,
|
|
|
|
|
dataIndex: 'CUSTBANKNAME',
|
|
|
|
|
header: Zi.LAN.jsuanBank, //驳回原因
|
|
|
|
|
width: 80
|
|
|
|
|
}, {
|
|
|
|
|
sortable: true,
|
|
|
|
|
dataIndex: 'CUSTACCOUNT',
|
|
|
|
|
header: Zi.LAN.jsuanzh, //驳回原因
|
|
|
|
|
width: 80
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
];
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
this.Pagenum = Ext.create('Ext.form.field.Number', {
|
|
|
|
|
name: 'bottles',
|
|
|
|
|
fieldLabel: Zi.LAN.NumberOfpage,//每页记录数
|
|
|
|
|
labelAlign: 'right',
|
|
|
|
|
value: this.PageSize,
|
|
|
|
|
maxValue: 100000,
|
|
|
|
|
width: 180,
|
|
|
|
|
minValue: 0,
|
|
|
|
|
listeners: {
|
|
|
|
|
specialkey: function (field, e) {
|
|
|
|
|
if (e.getKey() == e.ENTER) {
|
|
|
|
|
_this.onRefreshClick();
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
this.girdcolums = this.initgirdcolums;
|
|
|
|
|
|
|
|
|
|
this.GridCheckBoxModel = Ext.create('Ext.selection.CheckboxModel');
|
|
|
|
|
//定义Grid
|
|
|
|
|
this.gridList = new Ext.grid.GridPanel({
|
|
|
|
|
store: this.storeList,
|
|
|
|
|
enableHdMenu: false,
|
|
|
|
|
height: 180,
|
|
|
|
|
region: 'north',
|
|
|
|
|
split: true,
|
|
|
|
|
loadMask: { msg: Zi.LAN.LoadData },
|
|
|
|
|
trackMouseOver: true,
|
|
|
|
|
disableSelection: false,
|
|
|
|
|
viewConfig: {
|
|
|
|
|
enableTextSelection: true
|
|
|
|
|
},
|
|
|
|
|
selModel: this.GridCheckBoxModel,
|
|
|
|
|
tbar: [{
|
|
|
|
|
text: Zi.LAN.Saveliststyle,
|
|
|
|
|
id: "btntest",
|
|
|
|
|
menu: [
|
|
|
|
|
{ text: Zi.LAN.Save,
|
|
|
|
|
handler: function (button, event) {
|
|
|
|
|
_this.girdcolums = DsTruck.SaveGridPanel(USERID, _this.formname, _this.gridList.columns, _this.girdcolums, 1, true);
|
|
|
|
|
}
|
|
|
|
|
}, { text: Zi.LAN.Initialization,
|
|
|
|
|
handler: function (menu, event) {
|
|
|
|
|
_this.girdcolums = DsTruck.SaveGridPanel(USERID, _this.formname, _this.gridList.columns, _this.initgirdcolums, 1, true);
|
|
|
|
|
}
|
|
|
|
|
}],
|
|
|
|
|
scope: this
|
|
|
|
|
}],
|
|
|
|
|
columns: this.girdcolums,
|
|
|
|
|
// paging bar on the bottom
|
|
|
|
|
bbar: [Ext.create('Ext.PagingToolbar', {
|
|
|
|
|
store: this.storeList,
|
|
|
|
|
displayInfo: true,
|
|
|
|
|
displayMsg: Zi.LAN.FenYe, //当前显示条数据
|
|
|
|
|
emptyMsg: Zi.LAN.Nodata//没有数据
|
|
|
|
|
}), this.Pagenum]
|
|
|
|
|
});
|
|
|
|
|
this.girdcolums = DsTruck.GetGridPanel(USERID, this.formname, this.girdcolums, 1); //使用者id,表名,中间column数组,跳过一开始的几列
|
|
|
|
|
this.girdcolums.unshift(new Ext.grid.RowNumberer());
|
|
|
|
|
this.gridList.reconfigure(this.storeList, this.girdcolums);
|
|
|
|
|
|
|
|
|
|
//#region formSearch
|
|
|
|
|
|
|
|
|
|
//#region formSearch枚举参照相关
|
|
|
|
|
|
|
|
|
|
//#endregion
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
this.storeAddDCType = Ext.create('Ext.data.Store', {
|
|
|
|
|
fields: ['DC', 'NAME']
|
|
|
|
|
});
|
|
|
|
|
this.storeAddDCType.add({ "DC": "", "NAME": Zi.LAN.All });
|
|
|
|
|
this.storeAddDCType.add({ "DC": "1", "NAME": Zi.LAN.NotAudited});
|
|
|
|
|
this.storeAddDCType.add({ "DC": "2", "NAME": Zi.LAN.Audited });
|
|
|
|
|
this.storeAddDCType.add({ "DC": "3", "NAME": Zi.LAN.MyAudited});
|
|
|
|
|
|
|
|
|
|
this.comboxaddDCType = Ext.create('DsExt.ux.RefTableCombox', {
|
|
|
|
|
fieldLabel: Zi.LAN.ApprovalStatus,
|
|
|
|
|
labelWidth: 60,
|
|
|
|
|
store: this.storeAddDCType,
|
|
|
|
|
valueField: 'DC',
|
|
|
|
|
displayField: 'NAME',
|
|
|
|
|
forceSelection: true,
|
|
|
|
|
name: 'DC',
|
|
|
|
|
value: '3',
|
|
|
|
|
enableKeyEvents: true,
|
|
|
|
|
listeners: {
|
|
|
|
|
keyup: function (field, e) {
|
|
|
|
|
if (e.getKey() == e.ENTER) {
|
|
|
|
|
_this.onRefreshClick();
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
});
|
|
|
|
|
this.storeCustCode = Ext.create('DsExt.ux.RefTableStore', {
|
|
|
|
|
model: 'DsShipping.ux.CustomRefModel',
|
|
|
|
|
proxy: { url: '/CommMng/BasicDataRef/GetCustomRefListRm' }
|
|
|
|
|
});
|
|
|
|
|
this.storeCustCode.load({ params: { condition: ""} });
|
|
|
|
|
this.comboxCustCode = Ext.create('DsExt.ux.RefTableCombox', {
|
|
|
|
|
fieldLabel: Zi.LAN.SettlementUnit, //结算单位
|
|
|
|
|
labelWidth: 60,
|
|
|
|
|
store: this.storeCustCode,
|
|
|
|
|
forceSelection: true,
|
|
|
|
|
queryMode: 'remote',
|
|
|
|
|
minChars: 1,
|
|
|
|
|
queryParam: 'CODENAME',
|
|
|
|
|
name: 'CustName',
|
|
|
|
|
valueField: 'CustName',
|
|
|
|
|
displayField: 'CodeAndName',
|
|
|
|
|
enableKeyEvents: true,
|
|
|
|
|
listeners: {
|
|
|
|
|
keyup: function (field, e) {
|
|
|
|
|
if (e.getKey() == e.ENTER) {
|
|
|
|
|
_this.onRefreshClick();
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
//人员信息加载
|
|
|
|
|
this.storeOpCode = Ext.create('DsExt.ux.RefTableStore', {
|
|
|
|
|
model: 'DsShipping.ux.UserRefModel',
|
|
|
|
|
proxy: { url: '/CommMng/BasicDataRef/GetUserRefList' }
|
|
|
|
|
});
|
|
|
|
|
this.storeOpCode.load();
|
|
|
|
|
//
|
|
|
|
|
this.comboxAPPLICANT = Ext.create('DsExt.ux.RefTableCombox', {
|
|
|
|
|
fieldLabel: Zi.LAN.Applicant,
|
|
|
|
|
store: this.storeOpCode,
|
|
|
|
|
forceSelection: true,
|
|
|
|
|
name: 'APPLICANT',
|
|
|
|
|
labelWidth: 50,
|
|
|
|
|
flex: 0.5,
|
|
|
|
|
valueField: 'GID',
|
|
|
|
|
displayField: 'CodeAndName',
|
|
|
|
|
enableKeyEvents: true,
|
|
|
|
|
listeners: {
|
|
|
|
|
keyup: function (field, e) {
|
|
|
|
|
if (e.getKey() == e.ENTER) {
|
|
|
|
|
_this.onRefreshClick();
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
this.formSearch = Ext.widget('form', {
|
|
|
|
|
frame: true,
|
|
|
|
|
region: 'center',
|
|
|
|
|
bodyPadding: 5,
|
|
|
|
|
fieldDefaults: {
|
|
|
|
|
margins: '2 2 2 2',
|
|
|
|
|
labelAlign: 'right',
|
|
|
|
|
flex: 1,
|
|
|
|
|
labelWidth: 90,
|
|
|
|
|
msgTarget: 'qtip'
|
|
|
|
|
},
|
|
|
|
|
|
|
|
|
|
items: [
|
|
|
|
|
{//fieldset 1
|
|
|
|
|
xtype: 'container',
|
|
|
|
|
defaultType: 'textfield',
|
|
|
|
|
layout: 'anchor',
|
|
|
|
|
defaults: {
|
|
|
|
|
anchor: '100%'
|
|
|
|
|
},
|
|
|
|
|
items: [{
|
|
|
|
|
xtype: 'container',
|
|
|
|
|
layout: 'hbox',
|
|
|
|
|
defaultType: 'textfield',
|
|
|
|
|
items: [{
|
|
|
|
|
fieldLabel: Zi.LAN.RequisitionNumber, //申请单号
|
|
|
|
|
name: 'BsNo',
|
|
|
|
|
labelWidth: 60,
|
|
|
|
|
enableKeyEvents: true,
|
|
|
|
|
listeners: {
|
|
|
|
|
specialkey: function (field, e) {
|
|
|
|
|
if (e.getKey() == e.ENTER) {
|
|
|
|
|
_this.onRefreshClick();
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}, {
|
|
|
|
|
fieldLabel: Zi.LAN.RelatedBusinessNumber, //相关业务号
|
|
|
|
|
name: 'sBsNo',
|
|
|
|
|
labelWidth: 70,
|
|
|
|
|
enableKeyEvents: true,
|
|
|
|
|
listeners: {
|
|
|
|
|
specialkey: function (field, e) {
|
|
|
|
|
if (e.getKey() == e.ENTER) {
|
|
|
|
|
_this.onRefreshClick();
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}, this.comboxCustCode, {
|
|
|
|
|
fieldLabel: Zi.LAN.FromDateApplication, //从付费申请日期
|
|
|
|
|
format: 'Y-m-d',
|
|
|
|
|
xtype: 'datefield',
|
|
|
|
|
name: 'ExpDateBgn',
|
|
|
|
|
enableKeyEvents: true,
|
|
|
|
|
listeners: {
|
|
|
|
|
specialkey: function (field, e) {
|
|
|
|
|
if (e.getKey() == e.ENTER) {
|
|
|
|
|
_this.onRefreshClick();
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}, {
|
|
|
|
|
fieldLabel: Zi.LAN.ToDateApplication,
|
|
|
|
|
format: 'Y-m-d',
|
|
|
|
|
xtype: 'datefield',
|
|
|
|
|
name: 'ExpDateEnd',
|
|
|
|
|
enableKeyEvents: true,
|
|
|
|
|
listeners: {
|
|
|
|
|
specialkey: function (field, e) {
|
|
|
|
|
if (e.getKey() == e.ENTER) {
|
|
|
|
|
_this.onRefreshClick();
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}, this.comboxAPPLICANT, this.comboxaddDCType
|
|
|
|
|
]
|
|
|
|
|
}
|
|
|
|
|
]//end items(fieldset 1)
|
|
|
|
|
}//end fieldset 1
|
|
|
|
|
]//end root items
|
|
|
|
|
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
//#endregion
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
//#region 明细
|
|
|
|
|
|
|
|
|
|
this.storeBodyListdetail = Ext.create('Ext.data.Store', {
|
|
|
|
|
model: 'Chfee_do_detail',
|
|
|
|
|
remoteSort: true,
|
|
|
|
|
pageSize: this.BodyPageSize,
|
|
|
|
|
proxy: {
|
|
|
|
|
type: 'ajax',
|
|
|
|
|
url: '/Account/Chfee_payapplication/GetBillAuditList',
|
|
|
|
|
reader: {
|
|
|
|
|
id: 'BSNO,FEEDOID',
|
|
|
|
|
root: 'data',
|
|
|
|
|
totalProperty: 'totalCount'
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
this.initgirdbillcolums = [{
|
|
|
|
|
sortable: true,
|
|
|
|
|
dataIndex: 'BILLNO',
|
|
|
|
|
header: 'BILL',
|
|
|
|
|
hidden: true,
|
|
|
|
|
width: 100
|
|
|
|
|
}, {
|
|
|
|
|
sortable: true,
|
|
|
|
|
dataIndex: 'BSNO',
|
|
|
|
|
header: 'BSNO',
|
|
|
|
|
hidden: true,
|
|
|
|
|
width: 100
|
|
|
|
|
}, {
|
|
|
|
|
sortable: true,
|
|
|
|
|
dataIndex: 'FEEDOID',
|
|
|
|
|
header: 'FEEDOID',
|
|
|
|
|
hidden: true,
|
|
|
|
|
width: 100
|
|
|
|
|
}, {
|
|
|
|
|
sortable: true,
|
|
|
|
|
dataIndex: 'CUSTNO',
|
|
|
|
|
header: Zi.LAN.DelegateNumber, //委托编号
|
|
|
|
|
width: 120
|
|
|
|
|
}, {
|
|
|
|
|
sortable: true,
|
|
|
|
|
dataIndex: 'MBLNO',
|
|
|
|
|
header: Zi.LAN.ZhuTDH,
|
|
|
|
|
width: 120
|
|
|
|
|
}, {
|
|
|
|
|
sortable: true,
|
|
|
|
|
dataIndex: 'HBLNO',
|
|
|
|
|
header: Zi.LAN.HBLNO,
|
|
|
|
|
width: 120
|
|
|
|
|
}, {
|
|
|
|
|
sortable: true,
|
|
|
|
|
dataIndex: 'CUSTOMERNAME',
|
|
|
|
|
header: Zi.LAN.Requester,
|
|
|
|
|
width: 100
|
|
|
|
|
}, {
|
|
|
|
|
sortable: true,
|
|
|
|
|
dataIndex: 'FEEOBJNAME',
|
|
|
|
|
header: Zi.LAN.SettlementUnit,
|
|
|
|
|
width: 100
|
|
|
|
|
}, {
|
|
|
|
|
sortable: true,
|
|
|
|
|
dataIndex: 'ETD',
|
|
|
|
|
header: Zi.LAN.SailingDate,
|
|
|
|
|
renderer: Ext.util.Format.dateRenderer('Y-m-d'),
|
|
|
|
|
width: 80
|
|
|
|
|
}, {
|
|
|
|
|
sortable: true,
|
|
|
|
|
dataIndex: 'BSSOURCE',
|
|
|
|
|
header: Zi.LAN.BusinessSource, //业务来源
|
|
|
|
|
width: 80
|
|
|
|
|
}, {
|
|
|
|
|
sortable: true,
|
|
|
|
|
dataIndex: 'FEENAME',
|
|
|
|
|
header: Zi.LAN.CostName, //费用名称
|
|
|
|
|
width: 80
|
|
|
|
|
}, {
|
|
|
|
|
sortable: true,
|
|
|
|
|
dataIndex: 'FEETYPEREF',
|
|
|
|
|
header: Zi.LAN.PayReceive, //收付
|
|
|
|
|
width: 40,
|
|
|
|
|
renderer: function (value, meta) {
|
|
|
|
|
if (value == '收') {
|
|
|
|
|
return Zi.LAN.DR;
|
|
|
|
|
} else if (value == '付') {
|
|
|
|
|
return Zi.LAN.CR;
|
|
|
|
|
} else {
|
|
|
|
|
return "";
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}, {
|
|
|
|
|
sortable: true,
|
|
|
|
|
dataIndex: 'AMOUNT',
|
|
|
|
|
header: Zi.LAN.WriteOffAmount, //核销金额
|
|
|
|
|
width: 80,
|
|
|
|
|
renderer: function (value, cellmeta, record, rowIndex, columnIndex, store) {
|
|
|
|
|
try {
|
|
|
|
|
var lsValue = usMoney(value, 2, '', false);
|
|
|
|
|
if (lsValue != "NaN") {
|
|
|
|
|
value = lsValue; if (parseFloat(lsValue) < 0) {
|
|
|
|
|
return '<SPAN style="COLOR: red">' + lsValue + '</SPAN>';
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
else {
|
|
|
|
|
return value;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
catch (e) {
|
|
|
|
|
return value;
|
|
|
|
|
}
|
|
|
|
|
return value;
|
|
|
|
|
}
|
|
|
|
|
}, {
|
|
|
|
|
sortable: true,
|
|
|
|
|
dataIndex: 'ORIGCURRENCY',
|
|
|
|
|
header: Zi.LAN.OriginalCurrency, //原始币别
|
|
|
|
|
width: 80
|
|
|
|
|
}, {
|
|
|
|
|
sortable: true,
|
|
|
|
|
dataIndex: 'ORIGEXCHANGERATE',
|
|
|
|
|
header: Zi.LAN.OriginalExchangeRate, //原始汇率
|
|
|
|
|
width: 80
|
|
|
|
|
}, {
|
|
|
|
|
sortable: true,
|
|
|
|
|
dataIndex: 'EXCHANGERATE',
|
|
|
|
|
header: Zi.LAN.ExchangeRate,
|
|
|
|
|
width: 80
|
|
|
|
|
}, {
|
|
|
|
|
sortable: true,
|
|
|
|
|
dataIndex: 'ORIGAMOUNT',
|
|
|
|
|
header: Zi.LAN.OriginalAmount,
|
|
|
|
|
width: 80,
|
|
|
|
|
renderer: function (value, cellmeta, record, rowIndex, columnIndex, store) {
|
|
|
|
|
try {
|
|
|
|
|
var lsValue = usMoney(value, 2, '', false);
|
|
|
|
|
if (lsValue != "NaN") {
|
|
|
|
|
value = lsValue; if (parseFloat(lsValue) < 0) {
|
|
|
|
|
return '<SPAN style="COLOR: red">' + lsValue + '</SPAN>';
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
else {
|
|
|
|
|
return value;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
catch (e) {
|
|
|
|
|
return value;
|
|
|
|
|
}
|
|
|
|
|
return value;
|
|
|
|
|
}
|
|
|
|
|
}, {
|
|
|
|
|
sortable: true,
|
|
|
|
|
dataIndex: 'TTLNODR',
|
|
|
|
|
header: Zi.LAN.TTLNODR,
|
|
|
|
|
width: 80,
|
|
|
|
|
renderer: function (value, cellmeta, record, rowIndex, columnIndex, store) {
|
|
|
|
|
try {
|
|
|
|
|
var lsValue = usMoney(value, 2, '', false);
|
|
|
|
|
if (lsValue != "NaN") {
|
|
|
|
|
value = lsValue; if (parseFloat(lsValue) < 0) {
|
|
|
|
|
return '<SPAN style="COLOR: red">' + lsValue + '</SPAN>';
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
else {
|
|
|
|
|
return value;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
catch (e) {
|
|
|
|
|
return value;
|
|
|
|
|
}
|
|
|
|
|
return value;
|
|
|
|
|
}
|
|
|
|
|
}, {
|
|
|
|
|
sortable: true,
|
|
|
|
|
dataIndex: 'INVOICENO',
|
|
|
|
|
header: Zi.LAN.InvoiceNumber, //发票号
|
|
|
|
|
width: 80
|
|
|
|
|
}, {
|
|
|
|
|
sortable: true,
|
|
|
|
|
dataIndex: 'OPTYPE',
|
|
|
|
|
header: Zi.LAN.ChangeSingle, //更改单
|
|
|
|
|
width: 80,
|
|
|
|
|
renderer: function (value, meta) {
|
|
|
|
|
if (value == '普通货')
|
|
|
|
|
return Zi.LAN.PUTONGHUO; //是
|
|
|
|
|
else
|
|
|
|
|
return Zi.LAN.GENGGAIDAN;
|
|
|
|
|
}
|
|
|
|
|
}, {
|
|
|
|
|
sortable: true,
|
|
|
|
|
dataIndex: 'ACCDATE',
|
|
|
|
|
header: Zi.LAN.AccountingPeriod,
|
|
|
|
|
width: 80
|
|
|
|
|
}, {
|
|
|
|
|
sortable: true,
|
|
|
|
|
dataIndex: 'BLISSUESTATUS',
|
|
|
|
|
header: Zi.LAN.SignatureStatus, //签单状态
|
|
|
|
|
width: 80
|
|
|
|
|
}, {
|
|
|
|
|
sortable: true,
|
|
|
|
|
dataIndex: 'SALE',
|
|
|
|
|
header: Zi.LAN.LanhuoPeople, //揽货人
|
|
|
|
|
width: 80
|
|
|
|
|
}, {
|
|
|
|
|
sortable: true,
|
|
|
|
|
dataIndex: 'Remark',
|
|
|
|
|
header: Zi.LAN.Remarks, //备注
|
|
|
|
|
width: 160
|
|
|
|
|
}, {
|
|
|
|
|
sortable: true,
|
|
|
|
|
dataIndex: 'INPUTMODE',
|
|
|
|
|
header: Zi.LAN.EntryMethod,
|
|
|
|
|
width: 160
|
|
|
|
|
}, {
|
|
|
|
|
sortable: true,
|
|
|
|
|
dataIndex: 'BSSTATUSREF',
|
|
|
|
|
header: Zi.LAN.BSSTATUSREF,
|
|
|
|
|
width: 80,
|
|
|
|
|
renderer: function (value, cellmeta) {
|
|
|
|
|
if (value == '锁定') {
|
|
|
|
|
return "<img src='../../../../TruckMng/Content/Images/Lock.png' />";
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}, {
|
|
|
|
|
sortable: true,
|
|
|
|
|
dataIndex: 'FEESTATUSREF',
|
|
|
|
|
header: Zi.LAN.FEESTATUSREF,
|
|
|
|
|
width: 80,
|
|
|
|
|
renderer: function (value, cellmeta) {
|
|
|
|
|
if (value == '锁定') {
|
|
|
|
|
return "<img src='../../../../TruckMng/Content/Images/Lock.png' />";
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}, {
|
|
|
|
|
sortable: true,
|
|
|
|
|
dataIndex: 'ORDERNO',
|
|
|
|
|
header: Zi.LAN.ORDERNO,
|
|
|
|
|
width: 80
|
|
|
|
|
}, {
|
|
|
|
|
sortable: true,
|
|
|
|
|
dataIndex: 'ISOPEN',
|
|
|
|
|
header: Zi.LAN.ISOPEN,
|
|
|
|
|
width: 80,
|
|
|
|
|
renderer: function (value, cellmeta) {
|
|
|
|
|
if (value) {
|
|
|
|
|
return "√";
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
];
|
|
|
|
|
this.girdbillcolums = this.initgirdbillcolums;
|
|
|
|
|
|
|
|
|
|
this.BodyPagenum = Ext.create('Ext.form.field.Number', {
|
|
|
|
|
name: 'bottles',
|
|
|
|
|
fieldLabel: Zi.LAN.NumberOfpage, //每页记录数
|
|
|
|
|
labelAlign: 'right',
|
|
|
|
|
value: this.BodyPageSize,
|
|
|
|
|
maxValue: 100000,
|
|
|
|
|
width: 180,
|
|
|
|
|
minValue: 0,
|
|
|
|
|
listeners: {
|
|
|
|
|
specialkey: function (field, e) {
|
|
|
|
|
if (e.getKey() == e.ENTER) {
|
|
|
|
|
_this.BodyPageSize = _this.BodyPagenum.getValue();
|
|
|
|
|
_this.storeBodyListdetail.pageSize = _this.BodyPageSize;
|
|
|
|
|
_this.storeBodyListdetail.reload();
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
this.gridListdetail = new Ext.grid.GridPanel({
|
|
|
|
|
store: this.storeBodyListdetail,
|
|
|
|
|
enableHdMenu: false,
|
|
|
|
|
region: 'center',
|
|
|
|
|
loadMask: { msg: Zi.LAN.LoadData },
|
|
|
|
|
trackMouseOver: true,
|
|
|
|
|
viewConfig: {
|
|
|
|
|
enableTextSelection: true
|
|
|
|
|
},
|
|
|
|
|
disableSelection: false,
|
|
|
|
|
tbar: [
|
|
|
|
|
{
|
|
|
|
|
text: Zi.LAN.Saveliststyle,
|
|
|
|
|
id: "btntestbody",
|
|
|
|
|
menu: [
|
|
|
|
|
{ text: Zi.LAN.Save,
|
|
|
|
|
handler: function (button, event) {
|
|
|
|
|
_this.girdbillcolums = DsTruck.SaveGridPanel(USERID, _this.formname + 'bill', _this.gridListdetail.columns, _this.girdbillcolums, 1, true);
|
|
|
|
|
}
|
|
|
|
|
}, { text: Zi.LAN.Initialization,
|
|
|
|
|
handler: function (menu, event) {
|
|
|
|
|
_this.girdbillcolums = DsTruck.SaveGridPanel(USERID, _this.formname + 'bill', _this.gridListdetail.columns, _this.initgirdbillcolums, 1, true);
|
|
|
|
|
}
|
|
|
|
|
}],
|
|
|
|
|
scope: this
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
],
|
|
|
|
|
columns: this.girdbillcolums,
|
|
|
|
|
// paging bar on the bottom
|
|
|
|
|
bbar: [Ext.create('Ext.PagingToolbar', {
|
|
|
|
|
store: this.storeBodyListdetail,
|
|
|
|
|
displayInfo: true,
|
|
|
|
|
displayMsg: Zi.LAN.FenYe, //当前显示条数据
|
|
|
|
|
emptyMsg: Zi.LAN.Nodata//没有数据
|
|
|
|
|
}), this.BodyPagenum]
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
this.girdbillcolums = DsTruck.GetGridPanel(USERID, this.formname + 'bill', this.girdbillcolums, 1); //使用者id,表名,中间column数组,跳过一开始的几列
|
|
|
|
|
this.girdbillcolums.unshift(new Ext.grid.RowNumberer());
|
|
|
|
|
this.gridListdetail.reconfigure(this.storeBodyListdetail, this.girdbillcolums);
|
|
|
|
|
|
|
|
|
|
this.storeBodySum = Ext.create('Ext.data.Store', {
|
|
|
|
|
model: 'Chfee_do_sum',
|
|
|
|
|
remoteSort: true,
|
|
|
|
|
proxy: {
|
|
|
|
|
type: 'ajax',
|
|
|
|
|
url: '/Account/Chfee_payapplication/GetBillSum',
|
|
|
|
|
reader: {
|
|
|
|
|
root: 'data',
|
|
|
|
|
totalProperty: 'totalCount'
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
this.gridSum = new Ext.grid.GridPanel({
|
|
|
|
|
store: this.storeBodySum,
|
|
|
|
|
enableHdMenu: false,
|
|
|
|
|
region: 'center',
|
|
|
|
|
loadMask: { msg: Zi.LAN.LoadData },
|
|
|
|
|
trackMouseOver: true,
|
|
|
|
|
disableSelection: false,
|
|
|
|
|
tbar: [{
|
|
|
|
|
xtype: 'label',
|
|
|
|
|
width: 120,
|
|
|
|
|
height: 22,
|
|
|
|
|
text: Zi.LAN.TotalAmount// '申请金额合计'
|
|
|
|
|
}],
|
|
|
|
|
columns: [{
|
|
|
|
|
sortable: true,
|
|
|
|
|
dataIndex: 'FEETYPEREF',
|
|
|
|
|
header: Zi.LAN.PayReceive, //收付
|
|
|
|
|
width: 40,
|
|
|
|
|
renderer: function (value, meta) {
|
|
|
|
|
if (value == '收') {
|
|
|
|
|
return Zi.LAN.DR;
|
|
|
|
|
} else if (value == '付') {
|
|
|
|
|
return Zi.LAN.CR;
|
|
|
|
|
} else {
|
|
|
|
|
return "";
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}, {
|
|
|
|
|
sortable: true,
|
|
|
|
|
dataIndex: 'CURRENCY',
|
|
|
|
|
header: Zi.LAN.Currency,
|
|
|
|
|
width: 80
|
|
|
|
|
}, {
|
|
|
|
|
sortable: true,
|
|
|
|
|
dataIndex: 'AMOUNT',
|
|
|
|
|
header: Zi.LAN.AmountOfMoney, //金额
|
|
|
|
|
width: 80,
|
|
|
|
|
renderer: function (value, cellmeta, record, rowIndex, columnIndex, store) {
|
|
|
|
|
try {
|
|
|
|
|
var lsValue = usMoney(value, 2, '', false);
|
|
|
|
|
if (lsValue != "NaN") {
|
|
|
|
|
value = lsValue; if (parseFloat(lsValue) < 0) {
|
|
|
|
|
return '<SPAN style="COLOR: red">' + lsValue + '</SPAN>';
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
else {
|
|
|
|
|
return value;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
catch (e) {
|
|
|
|
|
return value;
|
|
|
|
|
}
|
|
|
|
|
return value;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
]
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
this.gridListdetail.addListener('itemdblclick', function (dataview, record, item, index, e, b) {
|
|
|
|
|
this.SelectedRecord = record;
|
|
|
|
|
var openSet = "height=700, width=1024, toolbar=no, menubar=no,scrollbars=1, resizable=1,location=no, status=no,Top= " + (screen.height - 750) / 2 + ",Left= " + (screen.width - 1100) / 2
|
|
|
|
|
var openType = "_blank";
|
|
|
|
|
var openUrl = "";
|
|
|
|
|
openUrl = "../../MvcShipping/MsOpBill/MsOpFeeView?handle=check&bsno=" + record.data.BSNO;
|
|
|
|
|
|
|
|
|
|
window.open(openUrl, openType, openSet);
|
|
|
|
|
// DsOpenEditWin("/TruckMng/MsWlPc/Edit");
|
|
|
|
|
}, this);
|
|
|
|
|
|
|
|
|
|
this.gridListdetail.getSelectionModel().on('select', function (model, record, index) {
|
|
|
|
|
|
|
|
|
|
var pbsno = record.data.PARENTID;
|
|
|
|
|
var sql = "";
|
|
|
|
|
sql = " BSNO IN (select BSNO FROM V_OP_BILL WHERE PARENTID='" + pbsno + "')";
|
|
|
|
|
this.Parentsql = sql;
|
|
|
|
|
_this.storeBodyBillSum.load({ params: { condition: sql} });
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
}, this);
|
|
|
|
|
|
|
|
|
|
this.storeBodyBillSum = Ext.create('Ext.data.Store', {
|
|
|
|
|
model: 'MsOPGain',
|
|
|
|
|
remoteSort: false,
|
|
|
|
|
proxy: {
|
|
|
|
|
type: 'ajax',
|
|
|
|
|
url: '/MvcShipping/MsChFee/GetMBLGainList',
|
|
|
|
|
reader: {
|
|
|
|
|
root: 'data',
|
|
|
|
|
totalProperty: 'totalCount'
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
this.gridBillSum = new Ext.grid.GridPanel({
|
|
|
|
|
store: this.storeBodyBillSum,
|
|
|
|
|
enableHdMenu: false,
|
|
|
|
|
region: 'center',
|
|
|
|
|
// height: 150,
|
|
|
|
|
loadMask: { msg: Zi.LAN.LoadData },
|
|
|
|
|
trackMouseOver: true,
|
|
|
|
|
disableSelection: false,
|
|
|
|
|
// tbar: [{
|
|
|
|
|
// xtype: 'label',
|
|
|
|
|
// id:'lblbillsum',
|
|
|
|
|
// width: 120,
|
|
|
|
|
// height: 22,
|
|
|
|
|
// text: Zi.LAN.SumMoney// '当前此票费用合计'
|
|
|
|
|
// }, {
|
|
|
|
|
// xtype: 'label',
|
|
|
|
|
// id: 'lblbillsum2',
|
|
|
|
|
// width: 320,
|
|
|
|
|
// height: 22,
|
|
|
|
|
// html: "<font color='red'></font>"// '当前此票费用合计'
|
|
|
|
|
// }],
|
|
|
|
|
columns: [{
|
|
|
|
|
header: Zi.LAN.Currency, //"<a href='#'><font color='#FF0000'>总 计</font></a>",
|
|
|
|
|
sortable: false,
|
|
|
|
|
align: 'center',
|
|
|
|
|
dataIndex: 'CURR',
|
|
|
|
|
width: 40
|
|
|
|
|
}, {
|
|
|
|
|
|
|
|
|
|
header: Zi.LAN.YingShou, //'含税',
|
|
|
|
|
dataIndex: 'DR',
|
|
|
|
|
align: 'right',
|
|
|
|
|
renderer: function (value, cellmeta, record, rowIndex, columnIndex, store) { try { var lsValue = usMoney(value, 2, '', false); if (lsValue != "NaN") { value = lsValue; if (parseFloat(lsValue) < 0) { return '<SPAN style="COLOR: red">' + lsValue + '</SPAN>'; } } else { return value; } } catch (e) { return value; } return value; },
|
|
|
|
|
width: 75
|
|
|
|
|
|
|
|
|
|
}, {
|
|
|
|
|
header: Zi.LAN.YingFu, //'含税',
|
|
|
|
|
dataIndex: 'CR',
|
|
|
|
|
align: 'right',
|
|
|
|
|
renderer: function (value, cellmeta, record, rowIndex, columnIndex, store) { try { var lsValue = usMoney(value, 2, '', false); if (lsValue != "NaN") { value = lsValue; if (parseFloat(lsValue) < 0) { return '<SPAN style="COLOR: red">' + lsValue + '</SPAN>'; } } else { return value; } } catch (e) { return value; } return value; },
|
|
|
|
|
width: 75
|
|
|
|
|
|
|
|
|
|
}, {
|
|
|
|
|
header: Zi.LAN.Profit, //'含税',
|
|
|
|
|
dataIndex: 'PR',
|
|
|
|
|
align: 'right',
|
|
|
|
|
renderer: function (value, cellmeta, record, rowIndex, columnIndex, store) { try { var lsValue = usMoney(value, 2, '', false); if (lsValue != "NaN") { value = lsValue; if (parseFloat(lsValue) < 0) { return '<SPAN style="COLOR: red">' + lsValue + '</SPAN>'; } } else { return value; } } catch (e) { return value; } return value; },
|
|
|
|
|
width: 70
|
|
|
|
|
|
|
|
|
|
}, {
|
|
|
|
|
header: Zi.LAN.BalDr, //'含税',
|
|
|
|
|
dataIndex: 'BALDR',
|
|
|
|
|
align: 'right',
|
|
|
|
|
renderer: function (value, cellmeta, record, rowIndex, columnIndex, store) { try { var lsValue = usMoney(value, 2, '', false); if (lsValue != "NaN") { value = lsValue; if (parseFloat(lsValue) < 0) { return '<SPAN style="COLOR: red">' + lsValue + '</SPAN>'; } } else { return value; } } catch (e) { return value; } return value; },
|
|
|
|
|
width: 70
|
|
|
|
|
|
|
|
|
|
}, {
|
|
|
|
|
header: Zi.LAN.PROFITRATE, //'含税',
|
|
|
|
|
dataIndex: 'PROFITRATE',
|
|
|
|
|
align: 'right',
|
|
|
|
|
renderer: function (value, cellmeta, record, rowIndex, columnIndex, store) { try { var lsValue = usMoney(value, 2, '', false); if (lsValue != "NaN") { value = lsValue; if (parseFloat(lsValue) < 0) { return '<SPAN style="COLOR: red">' + lsValue + '</SPAN>'; } } else { return value; } } catch (e) { return value; } return value; },
|
|
|
|
|
width: 70
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
]
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
this.panelBillSum = new Ext.Panel({
|
|
|
|
|
layout: "border",
|
|
|
|
|
region: 'south',
|
|
|
|
|
height: 150,
|
|
|
|
|
title: Zi.LAN.SumMoney,
|
|
|
|
|
items: [this.gridBillSum]
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
//#region 按票合计
|
|
|
|
|
|
|
|
|
|
//定义数据集
|
|
|
|
|
this.storeListbillsum = Ext.create('Ext.data.Store', {
|
|
|
|
|
pageSize: this.PageSize,
|
|
|
|
|
fields: [
|
|
|
|
|
{ name: 'BSNO', type: 'string' },
|
|
|
|
|
{ name: 'OPLB', type: 'string' },
|
|
|
|
|
{ name: 'OPLBNAME', type: 'string' },
|
|
|
|
|
{ name: 'OPTYPE', type: 'string' },
|
|
|
|
|
{ name: 'BLTYPE', type: 'string' },
|
|
|
|
|
{ name: 'BLFRT', type: 'string' },
|
|
|
|
|
{ name: 'FEESTATUSREF', type: 'string' },
|
|
|
|
|
{ name: 'CUSTOMERNAME', type: 'string' },
|
|
|
|
|
{ name: 'CUSTFULLNAME', type: 'string' },
|
|
|
|
|
{ name: 'CUSTNO', type: 'string' },
|
|
|
|
|
{ name: 'MBLNO', type: 'string' },
|
|
|
|
|
{ name: 'HBLNO', type: 'string' },
|
|
|
|
|
{ name: 'ETD', type: 'string' },
|
|
|
|
|
{ name: 'ATD', type: 'string' },
|
|
|
|
|
{ name: 'VESSEL', type: 'string' },
|
|
|
|
|
{ name: 'VOYNO', type: 'string' },
|
|
|
|
|
{ name: 'INPUTBY', type: 'string' },
|
|
|
|
|
{ name: 'CREATETIME', type: 'string' },
|
|
|
|
|
{ name: 'BSSTATUS', type: 'string' },
|
|
|
|
|
{ name: 'SALE', type: 'string' },
|
|
|
|
|
{ name: 'OP', type: 'string' },
|
|
|
|
|
{ name: 'DOC', type: 'string' },
|
|
|
|
|
{ name: 'CUSTSERVICE', type: 'string' },
|
|
|
|
|
{ name: 'FRCUSTSERVICE', type: 'string' },
|
|
|
|
|
{ name: 'PORTLOAD', type: 'string' },
|
|
|
|
|
{ name: 'PORTDISCHARGE', type: 'string' },
|
|
|
|
|
{ name: 'DESTINATION', type: 'string' },
|
|
|
|
|
{ name: 'CUSTOMNO', type: 'string' },
|
|
|
|
|
{ name: 'ACCDATE', type: 'string' },
|
|
|
|
|
{ name: 'CARRIER', type: 'string' },
|
|
|
|
|
{ name: 'BSSOURCE', type: 'string' },
|
|
|
|
|
{ name: 'BSSOURCEDETAIL', type: 'string' },
|
|
|
|
|
{ name: 'LANE', type: 'string' },
|
|
|
|
|
{ name: 'ISCANCEL', type: 'string' },
|
|
|
|
|
{ name: 'CONTRACTNO', type: 'string' },
|
|
|
|
|
{ name: 'ORDERNO', type: 'string' },
|
|
|
|
|
{ name: 'FORWARDER', type: 'string' },
|
|
|
|
|
{ name: 'CNTRTOTAL', type: 'string' },
|
|
|
|
|
{ name: 'TRADETYPE', type: 'string' },
|
|
|
|
|
{ name: 'GOODSNAME', type: 'string' },
|
|
|
|
|
{ name: 'OPDATE', type: 'string' },
|
|
|
|
|
{ name: 'CUSTOMDATE', type: 'string' },
|
|
|
|
|
|
|
|
|
|
{ name: 'AGENTID', type: 'string' },
|
|
|
|
|
{ name: 'ETA', type: 'string' },
|
|
|
|
|
{ name: 'SALEDEPT', type: 'string' },
|
|
|
|
|
{ name: 'ISSUETYPE', type: 'string' },
|
|
|
|
|
{ name: 'CUSTOMSER', type: 'string' },
|
|
|
|
|
{ name: 'CLOSINGDATE', type: 'string' },
|
|
|
|
|
{ name: 'KINDPKGS', type: 'string' },
|
|
|
|
|
{ name: 'SALECORP', type: 'string' },
|
|
|
|
|
{ name: 'YARD', type: 'string' },
|
|
|
|
|
{ name: 'TEU', type: 'number' },
|
|
|
|
|
{ name: 'RMBDR', type: 'number' },
|
|
|
|
|
{ name: 'RMBCR', type: 'number' },
|
|
|
|
|
{ name: 'USDDR', type: 'number' },
|
|
|
|
|
{ name: 'USDCR', type: 'number' },
|
|
|
|
|
{ name: 'OTDR', type: 'number' },
|
|
|
|
|
{ name: 'OTCR', type: 'number' },
|
|
|
|
|
{ name: 'TTLDR', type: 'number' },
|
|
|
|
|
{ name: 'TTLCR', type: 'number' },
|
|
|
|
|
{ name: 'TTLTAXDR', type: 'number' },
|
|
|
|
|
{ name: 'TTLTAXCR', type: 'number' },
|
|
|
|
|
{ name: 'TTLTAXPROFIT', type: 'number' },
|
|
|
|
|
{ name: 'RMBPROFIT', type: 'number' },
|
|
|
|
|
{ name: 'USDPROFIT', type: 'number' },
|
|
|
|
|
{ name: 'OTPROFIT', type: 'number' },
|
|
|
|
|
{ name: 'TTLPROFIT', type: 'number' },
|
|
|
|
|
{ name: 'PROFITRATE', type: 'number' }
|
|
|
|
|
|
|
|
|
|
],
|
|
|
|
|
remoteSort: true,
|
|
|
|
|
proxy: {
|
|
|
|
|
type: 'ajax',
|
|
|
|
|
timeout: 120000,
|
|
|
|
|
url: '/Account/Chfee_payapplication/BsListData',
|
|
|
|
|
reader: {
|
|
|
|
|
id: '',
|
|
|
|
|
root: 'data',
|
|
|
|
|
totalProperty: 'totalCount'
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
//定义Grid
|
|
|
|
|
this.initgirdcolumsbillsum = [{
|
|
|
|
|
sortable: true,
|
|
|
|
|
dataIndex: 'BSNO',
|
|
|
|
|
text: '编号',
|
|
|
|
|
hidden: true,
|
|
|
|
|
width: 130
|
|
|
|
|
}, {
|
|
|
|
|
sortable: true,
|
|
|
|
|
dataIndex: 'OPLBNAME',
|
|
|
|
|
text: Zi.LAN.OPLBNAME,
|
|
|
|
|
width: 70,
|
|
|
|
|
renderer: function (value, cellmeta) {
|
|
|
|
|
if (value == '海运出口') {
|
|
|
|
|
return Zi.LAN.HYCK;
|
|
|
|
|
} else if (value == '海运进口') {
|
|
|
|
|
return Zi.LAN.HYJK;
|
|
|
|
|
} else {
|
|
|
|
|
return value;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}, {
|
|
|
|
|
sortable: true,
|
|
|
|
|
dataIndex: 'OPTYPE',
|
|
|
|
|
text: Zi.LAN.OPTYPE,
|
|
|
|
|
width: 70,
|
|
|
|
|
renderer: function (value, meta) {
|
|
|
|
|
if (value == '普通货')
|
|
|
|
|
return Zi.LAN.PUTONGHUO; //是
|
|
|
|
|
else
|
|
|
|
|
return Zi.LAN.GENGGAIDAN;
|
|
|
|
|
}
|
|
|
|
|
}, {
|
|
|
|
|
sortable: true,
|
|
|
|
|
dataIndex: 'FEESTATUSREF',
|
|
|
|
|
text: Zi.LAN.FEESTATUSREF,
|
|
|
|
|
width: 70,
|
|
|
|
|
renderer: function (value, cellmeta) {
|
|
|
|
|
if (value == '锁定') {
|
|
|
|
|
return "<img src='../../../../TruckMng/Content/Images/Lock.png' />";
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}, {
|
|
|
|
|
sortable: true,
|
|
|
|
|
dataIndex: 'BSSTATUS',
|
|
|
|
|
text: Zi.LAN.BSSTATUS,
|
|
|
|
|
width: 70,
|
|
|
|
|
renderer: function (value, cellmeta) {
|
|
|
|
|
if (value == '1') {
|
|
|
|
|
return "<img src='../../../../TruckMng/Content/Images/Lock.png' />";
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}, {
|
|
|
|
|
dataIndex: 'ISCANCEL',
|
|
|
|
|
header: Zi.LAN.ISCANCEL, //'退舱',
|
|
|
|
|
width: 60,
|
|
|
|
|
renderer: function (value, meta, record) {
|
|
|
|
|
if (value == '1')
|
|
|
|
|
return '√';
|
|
|
|
|
else if (value == '2')
|
|
|
|
|
return '申请退舱';
|
|
|
|
|
else if (value == '4')
|
|
|
|
|
return '驳回申请';
|
|
|
|
|
else
|
|
|
|
|
return '';
|
|
|
|
|
}
|
|
|
|
|
}, {
|
|
|
|
|
sortable: true,
|
|
|
|
|
dataIndex: 'BSTYPE',
|
|
|
|
|
text: Zi.LAN.BSTYPE,
|
|
|
|
|
width: 70
|
|
|
|
|
}, {
|
|
|
|
|
sortable: true,
|
|
|
|
|
dataIndex: 'BLTYPE',
|
|
|
|
|
text: Zi.LAN.BLTYPE,
|
|
|
|
|
width: 70
|
|
|
|
|
}, {
|
|
|
|
|
sortable: true,
|
|
|
|
|
dataIndex: 'BLFRT',
|
|
|
|
|
text: Zi.LAN.BLFRT,
|
|
|
|
|
width: 70
|
|
|
|
|
}, {
|
|
|
|
|
sortable: true,
|
|
|
|
|
dataIndex: 'ISSUETYPE',
|
|
|
|
|
text: Zi.LAN.ISSUETYPE,
|
|
|
|
|
width: 70
|
|
|
|
|
}, {
|
|
|
|
|
sortable: true,
|
|
|
|
|
dataIndex: 'OPDATE',
|
|
|
|
|
text: Zi.LAN.OPDATE,
|
|
|
|
|
width: 86
|
|
|
|
|
}, {
|
|
|
|
|
sortable: true,
|
|
|
|
|
dataIndex: 'CUSTOMDATE',
|
|
|
|
|
text: Zi.LAN.CUSTOMDATE,
|
|
|
|
|
width: 86
|
|
|
|
|
}, {
|
|
|
|
|
sortable: true,
|
|
|
|
|
dataIndex: 'CUSTOMERNAME',
|
|
|
|
|
text: Zi.LAN.CUSTOMERNAME,
|
|
|
|
|
width: 120
|
|
|
|
|
}, {
|
|
|
|
|
sortable: true,
|
|
|
|
|
dataIndex: 'CUSTFULLNAME',
|
|
|
|
|
text: Zi.LAN.CUSTFULLNAME,
|
|
|
|
|
width: 140
|
|
|
|
|
}, {
|
|
|
|
|
sortable: true,
|
|
|
|
|
dataIndex: 'CUSTNO',
|
|
|
|
|
text: Zi.LAN.CUSTNO,
|
|
|
|
|
width: 136
|
|
|
|
|
}, {
|
|
|
|
|
sortable: true,
|
|
|
|
|
dataIndex: 'FORWARDER',
|
|
|
|
|
text: Zi.LAN.FORWARDER,
|
|
|
|
|
width: 100
|
|
|
|
|
}, {
|
|
|
|
|
sortable: true,
|
|
|
|
|
dataIndex: 'MBLNO',
|
|
|
|
|
text: Zi.LAN.MBLNO,
|
|
|
|
|
width: 120
|
|
|
|
|
}, {
|
|
|
|
|
sortable: true,
|
|
|
|
|
dataIndex: 'HBLNO',
|
|
|
|
|
text: Zi.LAN.HBLNO,
|
|
|
|
|
width: 120
|
|
|
|
|
}, {
|
|
|
|
|
sortable: true,
|
|
|
|
|
dataIndex: 'ETD',
|
|
|
|
|
text: Zi.LAN.ETD,
|
|
|
|
|
width: 86
|
|
|
|
|
}, {
|
|
|
|
|
sortable: true,
|
|
|
|
|
dataIndex: 'RMBDR',
|
|
|
|
|
text: Zi.LAN.RMBDR,
|
|
|
|
|
renderer: function (value, cellmeta, record, rowIndex, columnIndex, store) { try { var lsValue = usMoney(value, 2, '', false); if (lsValue != "NaN") { value = lsValue; if (parseFloat(lsValue) < 0) { return '<SPAN style="COLOR: red">' + lsValue + '</SPAN>'; } } else { return value; } } catch (e) { return value; } return value; },
|
|
|
|
|
align: 'right',
|
|
|
|
|
width: 80
|
|
|
|
|
}, {
|
|
|
|
|
sortable: true,
|
|
|
|
|
dataIndex: 'RMBCR',
|
|
|
|
|
text: Zi.LAN.RMBCR,
|
|
|
|
|
renderer: function (value, cellmeta, record, rowIndex, columnIndex, store) { try { var lsValue = usMoney(value, 2, '', false); if (lsValue != "NaN") { value = lsValue; if (parseFloat(lsValue) < 0) { return '<SPAN style="COLOR: red">' + lsValue + '</SPAN>'; } } else { return value; } } catch (e) { return value; } return value; },
|
|
|
|
|
align: 'right',
|
|
|
|
|
width: 80
|
|
|
|
|
}, {
|
|
|
|
|
sortable: true,
|
|
|
|
|
dataIndex: 'RMBPROFIT',
|
|
|
|
|
text: Zi.LAN.RMBPROFIT,
|
|
|
|
|
renderer: function (value, cellmeta, record, rowIndex, columnIndex, store) { try { var lsValue = usMoney(value, 2, '', false); if (lsValue != "NaN") { value = lsValue; if (parseFloat(lsValue) < 0) { return '<SPAN style="COLOR: red">' + lsValue + '</SPAN>'; } } else { return value; } } catch (e) { return value; } return value; },
|
|
|
|
|
align: 'right',
|
|
|
|
|
width: 80
|
|
|
|
|
}, {
|
|
|
|
|
sortable: true,
|
|
|
|
|
dataIndex: 'USDDR',
|
|
|
|
|
text: Zi.LAN.USDDR,
|
|
|
|
|
renderer: function (value, cellmeta, record, rowIndex, columnIndex, store) { try { var lsValue = usMoney(value, 2, '', false); if (lsValue != "NaN") { value = lsValue; if (parseFloat(lsValue) < 0) { return '<SPAN style="COLOR: red">' + lsValue + '</SPAN>'; } } else { return value; } } catch (e) { return value; } return value; },
|
|
|
|
|
align: 'right',
|
|
|
|
|
width: 80
|
|
|
|
|
}, {
|
|
|
|
|
sortable: true,
|
|
|
|
|
dataIndex: 'USDCR',
|
|
|
|
|
text: Zi.LAN.USDCR,
|
|
|
|
|
renderer: function (value, cellmeta, record, rowIndex, columnIndex, store) { try { var lsValue = usMoney(value, 2, '', false); if (lsValue != "NaN") { value = lsValue; if (parseFloat(lsValue) < 0) { return '<SPAN style="COLOR: red">' + lsValue + '</SPAN>'; } } else { return value; } } catch (e) { return value; } return value; },
|
|
|
|
|
align: 'right',
|
|
|
|
|
width: 80
|
|
|
|
|
}, {
|
|
|
|
|
sortable: true,
|
|
|
|
|
dataIndex: 'USDPROFIT',
|
|
|
|
|
text: Zi.LAN.USDPROFIT,
|
|
|
|
|
renderer: function (value, cellmeta, record, rowIndex, columnIndex, store) { try { var lsValue = usMoney(value, 2, '', false); if (lsValue != "NaN") { value = lsValue; if (parseFloat(lsValue) < 0) { return '<SPAN style="COLOR: red">' + lsValue + '</SPAN>'; } } else { return value; } } catch (e) { return value; } return value; },
|
|
|
|
|
align: 'right',
|
|
|
|
|
width: 80
|
|
|
|
|
}, {
|
|
|
|
|
sortable: true,
|
|
|
|
|
dataIndex: 'OTDR',
|
|
|
|
|
text: Zi.LAN.OTDR,
|
|
|
|
|
renderer: function (value, cellmeta, record, rowIndex, columnIndex, store) { try { var lsValue = usMoney(value, 2, '', false); if (lsValue != "NaN") { value = lsValue; if (parseFloat(lsValue) < 0) { return '<SPAN style="COLOR: red">' + lsValue + '</SPAN>'; } } else { return value; } } catch (e) { return value; } return value; },
|
|
|
|
|
align: 'right',
|
|
|
|
|
width: 80
|
|
|
|
|
}, {
|
|
|
|
|
sortable: true,
|
|
|
|
|
dataIndex: 'OTCR',
|
|
|
|
|
text: Zi.LAN.OTCR,
|
|
|
|
|
renderer: function (value, cellmeta, record, rowIndex, columnIndex, store) { try { var lsValue = usMoney(value, 2, '', false); if (lsValue != "NaN") { value = lsValue; if (parseFloat(lsValue) < 0) { return '<SPAN style="COLOR: red">' + lsValue + '</SPAN>'; } } else { return value; } } catch (e) { return value; } return value; },
|
|
|
|
|
align: 'right',
|
|
|
|
|
width: 80
|
|
|
|
|
}, {
|
|
|
|
|
sortable: true,
|
|
|
|
|
dataIndex: 'OTPROFIT',
|
|
|
|
|
text: Zi.LAN.OTPROFIT,
|
|
|
|
|
renderer: function (value, cellmeta, record, rowIndex, columnIndex, store) { try { var lsValue = usMoney(value, 2, '', false); if (lsValue != "NaN") { value = lsValue; if (parseFloat(lsValue) < 0) { return '<SPAN style="COLOR: red">' + lsValue + '</SPAN>'; } } else { return value; } } catch (e) { return value; } return value; },
|
|
|
|
|
align: 'right',
|
|
|
|
|
width: 80
|
|
|
|
|
}, {
|
|
|
|
|
sortable: true,
|
|
|
|
|
dataIndex: 'TTLDR',
|
|
|
|
|
text: Zi.LAN.TTLDR,
|
|
|
|
|
renderer: function (value, cellmeta, record, rowIndex, columnIndex, store) { try { var lsValue = usMoney(value, 2, '', false); if (lsValue != "NaN") { value = lsValue; if (parseFloat(lsValue) < 0) { return '<SPAN style="COLOR: red">' + lsValue + '</SPAN>'; } } else { return value; } } catch (e) { return value; } return value; },
|
|
|
|
|
align: 'right',
|
|
|
|
|
width: 80
|
|
|
|
|
}, {
|
|
|
|
|
sortable: true,
|
|
|
|
|
dataIndex: 'TTLCR',
|
|
|
|
|
text: Zi.LAN.TTLCR,
|
|
|
|
|
renderer: function (value, cellmeta, record, rowIndex, columnIndex, store) { try { var lsValue = usMoney(value, 2, '', false); if (lsValue != "NaN") { value = lsValue; if (parseFloat(lsValue) < 0) { return '<SPAN style="COLOR: red">' + lsValue + '</SPAN>'; } } else { return value; } } catch (e) { return value; } return value; },
|
|
|
|
|
align: 'right',
|
|
|
|
|
width: 80
|
|
|
|
|
}, {
|
|
|
|
|
sortable: true,
|
|
|
|
|
dataIndex: 'TTLPROFIT',
|
|
|
|
|
text: Zi.LAN.TTLPROFIT,
|
|
|
|
|
renderer: function (value, cellmeta, record, rowIndex, columnIndex, store) { try { var lsValue = usMoney(value, 2, '', false); if (lsValue != "NaN") { value = lsValue; if (parseFloat(lsValue) < 0) { return '<SPAN style="COLOR: red">' + lsValue + '</SPAN>'; } } else { return value; } } catch (e) { return value; } return value; },
|
|
|
|
|
align: 'right',
|
|
|
|
|
width: 80
|
|
|
|
|
}, {
|
|
|
|
|
sortable: true,
|
|
|
|
|
dataIndex: 'PROFITRATE',
|
|
|
|
|
text: Zi.LAN.PROFITRATE,
|
|
|
|
|
width: 80,
|
|
|
|
|
renderer: function (value, meta) {
|
|
|
|
|
if (value != 0) value = value + '%';
|
|
|
|
|
return value;
|
|
|
|
|
}
|
|
|
|
|
}, {
|
|
|
|
|
sortable: true,
|
|
|
|
|
dataIndex: 'ETA',
|
|
|
|
|
text: Zi.LAN.ETA,
|
|
|
|
|
width: 86
|
|
|
|
|
}, {
|
|
|
|
|
sortable: true,
|
|
|
|
|
dataIndex: 'ATD',
|
|
|
|
|
text: Zi.LAN.ATD,
|
|
|
|
|
width: 86
|
|
|
|
|
}, {
|
|
|
|
|
sortable: true,
|
|
|
|
|
dataIndex: 'VESSEL',
|
|
|
|
|
text: Zi.LAN.VESSEL,
|
|
|
|
|
width: 200
|
|
|
|
|
}, {
|
|
|
|
|
sortable: true,
|
|
|
|
|
dataIndex: 'VOYNO',
|
|
|
|
|
text: Zi.LAN.VOYNO,
|
|
|
|
|
width: 50
|
|
|
|
|
}, {
|
|
|
|
|
sortable: true,
|
|
|
|
|
dataIndex: 'SALE',
|
|
|
|
|
text: Zi.LAN.SALE,
|
|
|
|
|
width: 80
|
|
|
|
|
}, {
|
|
|
|
|
sortable: true,
|
|
|
|
|
dataIndex: 'OP',
|
|
|
|
|
text: Zi.LAN.OP,
|
|
|
|
|
width: 80
|
|
|
|
|
}, {
|
|
|
|
|
sortable: true,
|
|
|
|
|
dataIndex: 'DOC',
|
|
|
|
|
text: Zi.LAN.DOC,
|
|
|
|
|
width: 80
|
|
|
|
|
}, {
|
|
|
|
|
sortable: true,
|
|
|
|
|
dataIndex: 'SALEDEPT',
|
|
|
|
|
text: Zi.LAN.SALEDEPT,
|
|
|
|
|
width: 80
|
|
|
|
|
}, {
|
|
|
|
|
sortable: true,
|
|
|
|
|
dataIndex: 'CUSTSERVICE',
|
|
|
|
|
text: Zi.LAN.CUSTSERVICE,
|
|
|
|
|
width: 80
|
|
|
|
|
}, {
|
|
|
|
|
sortable: true,
|
|
|
|
|
dataIndex: 'FRCUSTSERVICE',
|
|
|
|
|
text: Zi.LAN.FRCUSTSERVICE,
|
|
|
|
|
width: 80
|
|
|
|
|
}, {
|
|
|
|
|
sortable: true,
|
|
|
|
|
dataIndex: 'CONTRACTNO',
|
|
|
|
|
text: Zi.LAN.CONTRACTNO,
|
|
|
|
|
width: 80
|
|
|
|
|
}, {
|
|
|
|
|
sortable: true,
|
|
|
|
|
dataIndex: 'ORDERNO',
|
|
|
|
|
text: Zi.LAN.ORDERNO,
|
|
|
|
|
width: 80
|
|
|
|
|
}, {
|
|
|
|
|
sortable: true,
|
|
|
|
|
dataIndex: 'PORTLOAD',
|
|
|
|
|
text: Zi.LAN.PORTLOAD,
|
|
|
|
|
width: 80
|
|
|
|
|
}, {
|
|
|
|
|
sortable: true,
|
|
|
|
|
dataIndex: 'PORTDISCHARGE',
|
|
|
|
|
text: Zi.LAN.PORTDISCHARGE,
|
|
|
|
|
width: 150
|
|
|
|
|
}, {
|
|
|
|
|
sortable: true,
|
|
|
|
|
dataIndex: 'DESTINATION',
|
|
|
|
|
header: Zi.LAN.DESTINATION,
|
|
|
|
|
width: 150
|
|
|
|
|
}, {
|
|
|
|
|
sortable: true,
|
|
|
|
|
dataIndex: 'ACCDATE',
|
|
|
|
|
text: Zi.LAN.ACCDATE,
|
|
|
|
|
width: 80
|
|
|
|
|
}, {
|
|
|
|
|
sortable: true,
|
|
|
|
|
dataIndex: 'CARRIER',
|
|
|
|
|
text: Zi.LAN.CARRIER,
|
|
|
|
|
width: 80
|
|
|
|
|
}, {
|
|
|
|
|
sortable: true,
|
|
|
|
|
dataIndex: 'LANE',
|
|
|
|
|
text: Zi.LAN.LANE,
|
|
|
|
|
width: 80
|
|
|
|
|
}, {
|
|
|
|
|
sortable: true,
|
|
|
|
|
dataIndex: 'BSSOURCE',
|
|
|
|
|
text: Zi.LAN.BSSOURCE,
|
|
|
|
|
width: 120
|
|
|
|
|
}, {
|
|
|
|
|
sortable: true,
|
|
|
|
|
dataIndex: 'BSSOURCEDETAIL',
|
|
|
|
|
text: Zi.LAN.BSSOURCEDETAIL,
|
|
|
|
|
width: 120
|
|
|
|
|
}, {
|
|
|
|
|
sortable: true,
|
|
|
|
|
dataIndex: 'YARD',
|
|
|
|
|
text: Zi.LAN.YARD,
|
|
|
|
|
width: 120
|
|
|
|
|
}, {
|
|
|
|
|
sortable: true,
|
|
|
|
|
dataIndex: 'AGENTID',
|
|
|
|
|
text: Zi.LAN.AGENTID,
|
|
|
|
|
width: 120
|
|
|
|
|
}, {
|
|
|
|
|
sortable: true,
|
|
|
|
|
dataIndex: 'TEU',
|
|
|
|
|
text: Zi.LAN.TEU,
|
|
|
|
|
width: 80
|
|
|
|
|
},{
|
|
|
|
|
sortable: true,
|
|
|
|
|
dataIndex: 'GOODSNAME',
|
|
|
|
|
text: Zi.LAN.GOODSNAME,
|
|
|
|
|
width: 80
|
|
|
|
|
}, {
|
|
|
|
|
sortable: true,
|
|
|
|
|
dataIndex: 'CREATETIME',
|
|
|
|
|
text: Zi.LAN.CREATETIME,
|
|
|
|
|
width: 80
|
|
|
|
|
}, {
|
|
|
|
|
sortable: true,
|
|
|
|
|
dataIndex: 'CNTRTOTAL',
|
|
|
|
|
text: Zi.LAN.CNTRTOTAL,
|
|
|
|
|
width: 80
|
|
|
|
|
}
|
|
|
|
|
];
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
// this.girdcolums = this.initgirdcolums;
|
|
|
|
|
this.girdcolumsbillsum = DsTruck.GetGridPanel(USERID, this.formname + 'billsum', this.initgirdcolumsbillsum, 1);
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
this.gridListbillsum = new Ext.grid.GridPanel({
|
|
|
|
|
store: this.storeListbillsum,
|
|
|
|
|
enableHdMenu: false,
|
|
|
|
|
region: 'center',
|
|
|
|
|
loadMask: { msg: "数据加载中,请稍等..." },
|
|
|
|
|
trackMouseOver: true,
|
|
|
|
|
disableSelection: false,
|
|
|
|
|
viewConfig: {
|
|
|
|
|
enableTextSelection: true, //允许复制数据
|
|
|
|
|
autoFill: true
|
|
|
|
|
},
|
|
|
|
|
tbar: [{
|
|
|
|
|
text: Zi.LAN.Saveliststyle,
|
|
|
|
|
id: "btntestbillsum",
|
|
|
|
|
menu: [
|
|
|
|
|
{
|
|
|
|
|
text: Zi.LAN.Save,
|
|
|
|
|
handler: function (button, event) {
|
|
|
|
|
_this.girdcolums = DsTruck.SaveGridPanel(USERID, _this.formname + 'billsum', _this.gridListbillsum.columns, _this.girdcolumsbillsum, 1, true);
|
|
|
|
|
}
|
|
|
|
|
}, {
|
|
|
|
|
text: Zi.LAN.Initialization,
|
|
|
|
|
handler: function (menu, event) {
|
|
|
|
|
_this.girdcolums = DsTruck.SaveGridPanel(USERID, _this.formname + 'billsum', _this.gridListbillsum.columns, _this.initgirdcolumsbillsum, 1, true);
|
|
|
|
|
}
|
|
|
|
|
}],
|
|
|
|
|
scope: this
|
|
|
|
|
}],
|
|
|
|
|
columns: this.girdcolumsbillsum,
|
|
|
|
|
// paging bar on the bottom
|
|
|
|
|
bbar: [Ext.create('Ext.PagingToolbar', {
|
|
|
|
|
store: this.storeListbillsum,
|
|
|
|
|
displayInfo: true,
|
|
|
|
|
displayMsg: Zi.LAN.FenYe,
|
|
|
|
|
emptyMsg: Zi.LAN.Nodata
|
|
|
|
|
})]
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
this.panelttlBillSum = new Ext.Panel({
|
|
|
|
|
layout: "border",
|
|
|
|
|
region: 'center',
|
|
|
|
|
title: Zi.LAN.panelttlBillSum,
|
|
|
|
|
items: [this.gridListbillsum]
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
//this.gridListbillsum = new Ext.grid.GridPanel({
|
|
|
|
|
// store: this.storeListbillsum,
|
|
|
|
|
// enableHdMenu: false,
|
|
|
|
|
// region: 'center',
|
|
|
|
|
// loadMask: { msg: "数据加载中,请稍等..." },
|
|
|
|
|
// trackMouseOver: true,
|
|
|
|
|
// disableSelection: false,
|
|
|
|
|
// viewConfig: {
|
|
|
|
|
// enableTextSelection: true, //允许复制数据
|
|
|
|
|
// autoFill: true
|
|
|
|
|
// },
|
|
|
|
|
// columns: this.girdcolumsbillsum,
|
|
|
|
|
// // paging bar on the bottom
|
|
|
|
|
// bbar: [Ext.create('Ext.PagingToolbar', {
|
|
|
|
|
// store: this.storeListbillsum,
|
|
|
|
|
// displayInfo: true,
|
|
|
|
|
// displayMsg: '当前显示 {0} - {1}条记录 /共 {2}条记录',
|
|
|
|
|
// emptyMsg: "没有数据"
|
|
|
|
|
// })]
|
|
|
|
|
//});
|
|
|
|
|
|
|
|
|
|
//#endregion
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
//#endregion formSearch
|
|
|
|
|
|
|
|
|
|
//查询工具条
|
|
|
|
|
_this = this;
|
|
|
|
|
this.panelBtn = new Ext.Panel({
|
|
|
|
|
region: "north",
|
|
|
|
|
tbar: [
|
|
|
|
|
|
|
|
|
|
{
|
|
|
|
|
text: Zi.LAN.ExecuteQuery, //执行查询
|
|
|
|
|
iconCls: "btnrefresh",
|
|
|
|
|
handler: function (button, event) {
|
|
|
|
|
this.onRefreshClick(button, event);
|
|
|
|
|
},
|
|
|
|
|
scope: this
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
text: Zi.LAN.ResetCondition, //重置
|
|
|
|
|
iconCls: "btnreset",
|
|
|
|
|
handler: function (button, event) {
|
|
|
|
|
this.onClearSql(button, event);
|
|
|
|
|
},
|
|
|
|
|
scope: this
|
|
|
|
|
}, '-', {
|
|
|
|
|
text: Zi.LAN.ExaminationPassed, //审核通过
|
|
|
|
|
iconCls: "btnadd",
|
|
|
|
|
handler: function (button, event) {
|
|
|
|
|
this.onAuditPassClick();
|
|
|
|
|
},
|
|
|
|
|
scope: this
|
|
|
|
|
},
|
|
|
|
|
'-',
|
|
|
|
|
{
|
|
|
|
|
text: Zi.LAN.DismissedSubmission, //驳回提交
|
|
|
|
|
iconCls: "btndelete",
|
|
|
|
|
handler: function (button, event) {
|
|
|
|
|
this.onAuditBackClick();
|
|
|
|
|
},
|
|
|
|
|
scope: this
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
, '-', {
|
|
|
|
|
text: Zi.LAN.ExaminationPassedAll, //全部审核通过
|
|
|
|
|
iconCls: "btnadd",
|
|
|
|
|
handler: function (button, event) {
|
|
|
|
|
this.onAllAuditClick();
|
|
|
|
|
},
|
|
|
|
|
scope: this
|
|
|
|
|
}
|
|
|
|
|
, {
|
|
|
|
|
xtype: 'button',
|
|
|
|
|
width: 90,
|
|
|
|
|
text: Zi.LAN.AdvancedSearch,
|
|
|
|
|
iconCls: "btnmore",
|
|
|
|
|
handler: function (button, event) {
|
|
|
|
|
var sql = _this.getCondition();
|
|
|
|
|
var winAccess = new Shipping.DsQuery({
|
|
|
|
|
|
|
|
|
|
});
|
|
|
|
|
winAccess.StoreList = _this.storeList;
|
|
|
|
|
winAccess.formname = _this.formname;
|
|
|
|
|
winAccess.condition = sql;
|
|
|
|
|
winAccess.show();
|
|
|
|
|
return;
|
|
|
|
|
}
|
|
|
|
|
}, '-', {
|
|
|
|
|
text: Zi.LAN.print, //打印
|
|
|
|
|
tooltip: Zi.LAN.printbb, //打印报表
|
|
|
|
|
menu:
|
|
|
|
|
[
|
|
|
|
|
{
|
|
|
|
|
text: Zi.LAN.printlb, //打印列表
|
|
|
|
|
handler: function (menu, event) {
|
|
|
|
|
_this.Print();
|
|
|
|
|
}
|
|
|
|
|
}, {
|
|
|
|
|
text: Zi.LAN.printxz, //打印选中
|
|
|
|
|
handler: function (menu, event) {
|
|
|
|
|
_this.PrintSelect(menu, event, 1);
|
|
|
|
|
}
|
|
|
|
|
}],
|
|
|
|
|
scope: this
|
|
|
|
|
}, '-',
|
|
|
|
|
{
|
|
|
|
|
text: Zi.LAN.SetNoprint, //打印
|
|
|
|
|
id: "btnSetNoprint",
|
|
|
|
|
handler: function (button, event) {
|
|
|
|
|
this.SetNoPrint();
|
|
|
|
|
},
|
|
|
|
|
scope: this
|
|
|
|
|
}, '-', {
|
|
|
|
|
text: Zi.LAN.ExportExcel, //导出EXcel
|
|
|
|
|
id: "btnExportExcel",
|
|
|
|
|
iconCls: 'btnexportexcel',
|
|
|
|
|
handler: function (button, event) {
|
|
|
|
|
this.onExportClick(button, event);
|
|
|
|
|
},
|
|
|
|
|
scope: this
|
|
|
|
|
}, {
|
|
|
|
|
text: Zi.LAN.xswork, //显示工作流
|
|
|
|
|
id: "btnShowMap",
|
|
|
|
|
iconCls: 'btnexportexcel',
|
|
|
|
|
handler: function (button, event) {
|
|
|
|
|
var selections = this.gridList.getSelectionModel().getSelection();
|
|
|
|
|
var record = selections[0];
|
|
|
|
|
var bsno = record.data.BILLNO;
|
|
|
|
|
var openSet = "height=700, width=1024, toolbar=no, menubar=no,scrollbars=1, resizable=1,location=no, status=no,Top= " + (screen.height - 750) / 2 + ",Left= " + (screen.width - 1100) / 2
|
|
|
|
|
var openType = "_blank";
|
|
|
|
|
var openUrl = "";
|
|
|
|
|
openUrl = "../../Account/Chfee_payapplication/Map?bsno=" + bsno;
|
|
|
|
|
|
|
|
|
|
window.open(openUrl, openType, openSet);
|
|
|
|
|
},
|
|
|
|
|
scope: this
|
|
|
|
|
}
|
|
|
|
|
]
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
//#region 附件信息
|
|
|
|
|
this.storeChfeeFile = Ext.create('Ext.data.Store', {
|
|
|
|
|
model: 'FeeFileModel',
|
|
|
|
|
remoteSort: false,
|
|
|
|
|
proxy: {
|
|
|
|
|
type: 'ajax',
|
|
|
|
|
url: '/Account/Chfee_payapplication/GetFileList',
|
|
|
|
|
reader: {
|
|
|
|
|
id: 'GID',
|
|
|
|
|
root: 'data',
|
|
|
|
|
totalProperty: 'totalCount'
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
});
|
|
|
|
|
//表格
|
|
|
|
|
this.FeeFileColumns = [
|
|
|
|
|
{
|
|
|
|
|
sortable: true, hidden: true,
|
|
|
|
|
dataIndex: 'GID', readOnly: true,
|
|
|
|
|
header: 'GID',
|
|
|
|
|
width: 80
|
|
|
|
|
}, {
|
|
|
|
|
sortable: true, hidden: false,
|
|
|
|
|
dataIndex: 'File_OriginalName', readOnly: true,
|
|
|
|
|
header: Zi.LAN.FileName,
|
|
|
|
|
width: 80
|
|
|
|
|
}, {
|
|
|
|
|
sortable: true, hidden: false,
|
|
|
|
|
dataIndex: 'UpdateTime', readOnly: true,
|
|
|
|
|
header: Zi.LAN.FileDate,
|
|
|
|
|
width: 80
|
|
|
|
|
}, {
|
|
|
|
|
sortable: true, hidden: false,
|
|
|
|
|
dataIndex: 'Operator', readOnly: true,
|
|
|
|
|
header: Zi.LAN.FilePerson,
|
|
|
|
|
width: 80
|
|
|
|
|
}, {
|
|
|
|
|
sortable: true, hidden: true,
|
|
|
|
|
dataIndex: 'File_Name', readOnly: true,
|
|
|
|
|
header: Zi.LAN.FileWName,
|
|
|
|
|
width: 80
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
sortable: true, hidden: true,
|
|
|
|
|
dataIndex: 'File_Path',
|
|
|
|
|
header: 'File_Path',
|
|
|
|
|
width: 80
|
|
|
|
|
}, {
|
|
|
|
|
xtype: 'actioncolumn',
|
|
|
|
|
width: 50,
|
|
|
|
|
text: Zi.LAN.Operating,
|
|
|
|
|
items: [{
|
|
|
|
|
icon: '/images/icons/btnSearch.gif', // Use a URL in the icon config
|
|
|
|
|
tooltip: '预览',
|
|
|
|
|
handler: function (grid, rowIndex, colIndex) {
|
|
|
|
|
var rec = grid.getStore().getAt(rowIndex);
|
|
|
|
|
var filePath = "/Areas/Account/Files/" + rec.get('BillNo') + '/' + rec.get('File_Name');
|
|
|
|
|
//var imgView = new Shipping.FileView({ filePath: filePath });
|
|
|
|
|
//imgView.show();
|
|
|
|
|
DsOpenEditWin(filePath, "", "650", "1250");
|
|
|
|
|
}
|
|
|
|
|
}]
|
|
|
|
|
}
|
|
|
|
|
];
|
|
|
|
|
var selCertModel = Ext.create('Ext.selection.CheckboxModel');
|
|
|
|
|
this.fileGrid = new Ext.grid.GridPanel({
|
|
|
|
|
store: this.storeChfeeFile,
|
|
|
|
|
enableHdMenu: false,
|
|
|
|
|
layout: 'border',
|
|
|
|
|
region: 'center',
|
|
|
|
|
loadMask: { msg: Zi.LAN.LoadData },
|
|
|
|
|
trackMouseOver: true,
|
|
|
|
|
disableSelection: false,
|
|
|
|
|
selModel: selCertModel,
|
|
|
|
|
singleSelect: true,
|
|
|
|
|
selType: 'rowmodel',
|
|
|
|
|
columns: this.FeeFileColumns
|
|
|
|
|
});
|
|
|
|
|
//#endregion
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
this.panelTop = new Ext.Panel({
|
|
|
|
|
layout: "border",
|
|
|
|
|
region: "north",
|
|
|
|
|
height: 80,
|
|
|
|
|
items: [this.formSearch, this.panelBtn]
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
this.panelSum = new Ext.Panel({
|
|
|
|
|
layout: "border",
|
|
|
|
|
region: 'east',
|
|
|
|
|
width: 330,
|
|
|
|
|
split: true,
|
|
|
|
|
margin: '2 2',
|
|
|
|
|
items: [this.gridSum, this.panelBillSum]
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
this.paneldetail = new Ext.Panel({
|
|
|
|
|
layout: "border",
|
|
|
|
|
region: 'center',
|
|
|
|
|
|
|
|
|
|
items: [
|
|
|
|
|
this.gridListdetail, this.panelSum
|
|
|
|
|
]
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
//#region 增加附件tab
|
|
|
|
|
this.page_1 = new Ext.Panel({
|
|
|
|
|
id: "page_1",
|
|
|
|
|
title: Zi.LAN.PaymentApplicationDetails, //付费申请明细
|
|
|
|
|
// autoScroll: true,
|
|
|
|
|
layout: "border",
|
|
|
|
|
region: 'center',
|
|
|
|
|
//closable:true,
|
|
|
|
|
items: [this.paneldetail]
|
|
|
|
|
});
|
|
|
|
|
this.page_2 = new Ext.Panel({
|
|
|
|
|
id: "page_2",
|
|
|
|
|
title: Zi.LAN.AttachmentInformation,
|
|
|
|
|
// autoScroll: true,
|
|
|
|
|
layout: "border",
|
|
|
|
|
region: 'center',
|
|
|
|
|
//closable:true,
|
|
|
|
|
items: [this.fileGrid]
|
|
|
|
|
});
|
|
|
|
|
this.MainTab = new Ext.tab.Panel({
|
|
|
|
|
layout: "border",
|
|
|
|
|
// height: 250,
|
|
|
|
|
region: "center", split: true,
|
|
|
|
|
items: [
|
|
|
|
|
this.page_1
|
|
|
|
|
, this.page_2
|
|
|
|
|
, this.panelttlBillSum
|
|
|
|
|
],
|
|
|
|
|
//tab切换事件
|
|
|
|
|
listeners: {
|
|
|
|
|
'tabchange': function (tabPanel, newCard, oldCard, eOpts) {
|
|
|
|
|
_this.RpttabChange(tabPanel, newCard, oldCard, eOpts);
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
});
|
|
|
|
|
//#endregion
|
|
|
|
|
|
|
|
|
|
Ext.apply(this, {
|
|
|
|
|
items: [this.panelTop, this.gridList, this.MainTab]
|
|
|
|
|
});
|
|
|
|
|
_this = this;
|
|
|
|
|
this.storeList.on('beforeload', function (store) {
|
|
|
|
|
var sql = this.getCondition();
|
|
|
|
|
Ext.apply(store.proxy.extraParams, { condition: sql, isaudit: this.isAudit });
|
|
|
|
|
}, this);
|
|
|
|
|
|
|
|
|
|
this.storeBodyListdetail.on('beforeload', function (store) {
|
|
|
|
|
var sql = " BILLNO='" + _this.billno + "'";
|
|
|
|
|
Ext.apply(store.proxy.extraParams, { condition: sql });
|
|
|
|
|
}, this);
|
|
|
|
|
|
|
|
|
|
this.storeBodyBillSum.on('beforeload', function (store) {
|
|
|
|
|
var sql = this.Parentsql;
|
|
|
|
|
Ext.apply(store.proxy.extraParams, { condition: sql });
|
|
|
|
|
}, this);
|
|
|
|
|
|
|
|
|
|
if (this.worksql != undefined && this.worksql != '') {
|
|
|
|
|
this.worksql = this.worksql.replace(/@@/g, '=')
|
|
|
|
|
this.sqlcontext = this.worksql;
|
|
|
|
|
this.onDsQuery();
|
|
|
|
|
|
|
|
|
|
} else {
|
|
|
|
|
|
|
|
|
|
this.onRefreshClick();
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
this.storeList.on('load', function (store, records) {
|
|
|
|
|
//if (store.getCount() > 0) {
|
|
|
|
|
// this.gridList.getSelectionModel().select(0);
|
|
|
|
|
|
|
|
|
|
//}
|
|
|
|
|
}, this);
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
this.gridList.getSelectionModel().on('select', function (model, record, index) {
|
|
|
|
|
|
|
|
|
|
_this.billno = record.data.BILLNO;
|
|
|
|
|
var sql = "";
|
|
|
|
|
sql = " BILLNO='" + _this.billno + "'";
|
|
|
|
|
_this.BodyPageSize = _this.BodyPagenum.getValue();
|
|
|
|
|
_this.storeBodyListdetail.pageSize = _this.BodyPageSize;
|
|
|
|
|
_this.storeBodyListdetail.load({ params: { start: 0, limit: _this.BodyPageSize, condition: sql} });
|
|
|
|
|
_this.storeBodySum.load({ params: { condition: sql} });
|
|
|
|
|
_this.storeChfeeFile.load({ params: { start: 0, limit: 9999, BillNo: _this.billno} });
|
|
|
|
|
_this.storeBodyBillSum.removeAll();
|
|
|
|
|
var CUSTOMERNAME = record.data.CUSTOMERNAME;
|
|
|
|
|
Ext.Ajax.request({
|
|
|
|
|
waitMsg: '',
|
|
|
|
|
url: '/MvcShipping/MsChFee/GetFeeBalAmount',
|
|
|
|
|
params: {
|
|
|
|
|
condition: " FEETYPE=1 AND CUSTOMERNAME='" + CUSTOMERNAME + "'"
|
|
|
|
|
},
|
|
|
|
|
callback: function (options, success, response) {
|
|
|
|
|
if (success) {
|
|
|
|
|
var result = Ext.JSON.decode(response.responseText);
|
|
|
|
|
if (result.Data == 0) {
|
|
|
|
|
_this.panelBillSum.setTitle(Zi.LAN.SumMoney, false);
|
|
|
|
|
} else {
|
|
|
|
|
_this.panelBillSum.setTitle(Zi.LAN.SumMoney + "<font color='red'>(" + Zi.LAN.ffkhczysfy+ result.Data + ")</font>", false);
|
|
|
|
|
}
|
|
|
|
|
} else {
|
|
|
|
|
_this.panelBillSum.setTitle(Zi.LAN.SumMoney, false);
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
},
|
|
|
|
|
scope: this
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
if (this.MainTab.getActiveTab() == this.panelttlBillSum) {
|
|
|
|
|
|
|
|
|
|
var sql = " B.BSNO IN (SELECT BSNO FROM CH_FEE_DO WHERE BILLNO='" + _this.billno + "') ";
|
|
|
|
|
this.storeListbillsum.load({ params: { start: 0, limit: _this.BodyPageSize, condition: sql } });
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
//var sql = " BSNO IN (SELECT BSNO FROM CH_FEE_DO WHERE BILLNO='" + _this.billno+"') ";
|
|
|
|
|
//_this.storeListbillsum.load({ params: { start: 0, limit: _this.BodyPageSize, condition: sql } });
|
|
|
|
|
|
|
|
|
|
}, this);
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Ext.Ajax.request({
|
|
|
|
|
waitMsg: '',
|
|
|
|
|
url: '/MvcShipping/MsSysParamSet/GetData',
|
|
|
|
|
params: {
|
|
|
|
|
condition: "PARAMNAME='PAYAUDITEXRATE'"
|
|
|
|
|
},
|
|
|
|
|
callback: function (options, success, response) {
|
|
|
|
|
if (success) {
|
|
|
|
|
var result = Ext.JSON.decode(response.responseText);
|
|
|
|
|
if (result.Success != true) {
|
|
|
|
|
|
|
|
|
|
} else {
|
|
|
|
|
var data = result.data;
|
|
|
|
|
if (data.PARAMVALUE == '1') {
|
|
|
|
|
this.isuseexrate = 1;
|
|
|
|
|
} else {
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
} else {
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
},
|
|
|
|
|
scope: this
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
Ext.Ajax.request({
|
|
|
|
|
waitMsg: '',
|
|
|
|
|
url: '/MvcShipping/MsSysParamSet/GetData',
|
|
|
|
|
params: {
|
|
|
|
|
condition: "PARAMNAME='YJFEENAME'"
|
|
|
|
|
},
|
|
|
|
|
callback: function (options, success, response) {
|
|
|
|
|
if (success) {
|
|
|
|
|
var result = Ext.JSON.decode(response.responseText);
|
|
|
|
|
if (result.Success != true) {
|
|
|
|
|
|
|
|
|
|
} else {
|
|
|
|
|
var data = result.data;
|
|
|
|
|
this.YJFEENAME = data.PARAMVALUE;
|
|
|
|
|
}
|
|
|
|
|
} else {
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
},
|
|
|
|
|
scope: this
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
Ext.Ajax.request({
|
|
|
|
|
waitMsg: '',
|
|
|
|
|
url: '/MvcShipping/MsSysParamSet/GetData',
|
|
|
|
|
params: {
|
|
|
|
|
condition: "PARAMNAME='YJFEENAME(USD)'"
|
|
|
|
|
},
|
|
|
|
|
callback: function (options, success, response) {
|
|
|
|
|
if (success) {
|
|
|
|
|
var result = Ext.JSON.decode(response.responseText);
|
|
|
|
|
if (result.Success != true) {
|
|
|
|
|
|
|
|
|
|
} else {
|
|
|
|
|
var data = result.data;
|
|
|
|
|
this.YJFEENAMEUSD = data.PARAMVALUE;
|
|
|
|
|
}
|
|
|
|
|
} else {
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
},
|
|
|
|
|
scope: this
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
//#region 结算汇率和金额
|
|
|
|
|
|
|
|
|
|
Ext.define('MsFeeCurr', {
|
|
|
|
|
extend: 'Ext.data.Model',
|
|
|
|
|
idProperty: 'CURR',
|
|
|
|
|
fields: [
|
|
|
|
|
{ name: 'CURR', type: 'string' },
|
|
|
|
|
{ name: 'DEFRATE', type: 'number' },
|
|
|
|
|
{ name: 'CRDEFRATE', type: 'number' }
|
|
|
|
|
]
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
this.StoreCurr = Ext.create('DsExt.ux.RefTableStore', {
|
|
|
|
|
model: 'MsFeeCurr',
|
|
|
|
|
proxy: { url: '/MvcShipping/MsChFee/GetFeeCurrList' }
|
|
|
|
|
});
|
|
|
|
|
this.StoreCurr.load({ params: { condition: ""} });
|
|
|
|
|
|
|
|
|
|
this.comboxStlCurr = Ext.create('DsExt.ux.RefTableCombox', {
|
|
|
|
|
fieldLabel: Zi.LAN.STLCURR,
|
|
|
|
|
store: this.StoreCurr,
|
|
|
|
|
forceSelection: true,
|
|
|
|
|
name: 'STLCURR',
|
|
|
|
|
value: 'RMB',
|
|
|
|
|
valueField: 'CURR',
|
|
|
|
|
displayField: 'CURR'
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
this.formAuditStlShow = Ext.widget('form', {
|
|
|
|
|
frame: true,
|
|
|
|
|
region: 'center',
|
|
|
|
|
bodyPadding: 5,
|
|
|
|
|
fieldDefaults: {
|
|
|
|
|
margins: '2 2 2 2',
|
|
|
|
|
labelAlign: 'right',
|
|
|
|
|
flex: 1,
|
|
|
|
|
labelWidth: 80,
|
|
|
|
|
msgTarget: 'qtip'
|
|
|
|
|
},
|
|
|
|
|
|
|
|
|
|
items: [
|
|
|
|
|
{//fieldset 1
|
|
|
|
|
xtype: 'container',
|
|
|
|
|
defaultType: 'textfield',
|
|
|
|
|
layout: 'anchor',
|
|
|
|
|
defaults: {
|
|
|
|
|
anchor: '100%'
|
|
|
|
|
},
|
|
|
|
|
items: [{
|
|
|
|
|
xtype: 'container',
|
|
|
|
|
layout: 'hbox',
|
|
|
|
|
defaultType: 'textfield',
|
|
|
|
|
items: [this.comboxStlCurr, {
|
|
|
|
|
fieldLabel: Zi.LAN.ExchangeRate,
|
|
|
|
|
name: 'STLRATE'
|
|
|
|
|
}
|
|
|
|
|
]//end items(fieldset 1)
|
|
|
|
|
}, {
|
|
|
|
|
xtype: 'container',
|
|
|
|
|
layout: 'hbox',
|
|
|
|
|
defaultType: 'textfield',
|
|
|
|
|
items: [{
|
|
|
|
|
fieldLabel: Zi.LAN.STLAMOUNT,
|
|
|
|
|
name: 'STLAMOUNT'
|
|
|
|
|
}
|
|
|
|
|
]//end items(fieldset 1)
|
|
|
|
|
}
|
|
|
|
|
]//end items(fieldset 1)
|
|
|
|
|
}//end fieldset 1
|
|
|
|
|
]//end root items
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
this.winAuditStlShow = Ext.create('Ext.window.Window', {
|
|
|
|
|
title: Zi.LAN.AuditStl, //"发送预配舱单",
|
|
|
|
|
width: 450,
|
|
|
|
|
//height : 120,
|
|
|
|
|
//plain : true,
|
|
|
|
|
iconCls: "addicon",
|
|
|
|
|
resizable: false,
|
|
|
|
|
// 是否可以拖动
|
|
|
|
|
// draggable:false,
|
|
|
|
|
collapsible: true, // 允许缩放条
|
|
|
|
|
closeAction: 'close',
|
|
|
|
|
closable: true,
|
|
|
|
|
modal: 'true',
|
|
|
|
|
buttonAlign: "center",
|
|
|
|
|
bodyStyle: "padding:0 0 0 0",
|
|
|
|
|
items: [this.formAuditStlShow],
|
|
|
|
|
buttons: [{
|
|
|
|
|
text: Zi.LAN.ExaminationPassed, //"确定发送",
|
|
|
|
|
minWidth: 70,
|
|
|
|
|
handler: function () {
|
|
|
|
|
var stlcurr = _this.formAuditStlShow.getForm().findField('STLCURR').getValue();
|
|
|
|
|
var stlrate = _this.formAuditStlShow.getForm().findField('STLRATE').getValue();
|
|
|
|
|
var stlamount = _this.formAuditStlShow.getForm().findField('STLAMOUNT').getValue();
|
|
|
|
|
_this.onAuditExratePassClick(stlcurr, stlrate, stlamount);
|
|
|
|
|
}
|
|
|
|
|
}, {
|
|
|
|
|
text: Zi.LAN.close, //"关闭",
|
|
|
|
|
minWidth: 70,
|
|
|
|
|
handler: function () {
|
|
|
|
|
_this.winAuditStlShow.close();
|
|
|
|
|
}
|
|
|
|
|
}]
|
|
|
|
|
});
|
|
|
|
|
// #endregion
|
|
|
|
|
|
|
|
|
|
var btnSetNoprint = Ext.getCmp('btnSetNoprint');
|
|
|
|
|
|
|
|
|
|
Ext.Ajax.request({
|
|
|
|
|
waitMsg: '正在查询',
|
|
|
|
|
url: '/MvcShipping/MsBaseInfo/GetUserModuleEnable',
|
|
|
|
|
params: {
|
|
|
|
|
modulename: 'modPayFeeAuditNotPrint'
|
|
|
|
|
},
|
|
|
|
|
callback: function (options, success, response) {
|
|
|
|
|
if (success) {
|
|
|
|
|
var result = Ext.JSON.decode(response.responseText);
|
|
|
|
|
if (result.Success) {
|
|
|
|
|
btnSetNoprint.hide();
|
|
|
|
|
|
|
|
|
|
} else {
|
|
|
|
|
btnSetNoprint.show();
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
},
|
|
|
|
|
scope: this
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
}, //end initUIComponents
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
onAuditPassClick: function () {
|
|
|
|
|
|
|
|
|
|
var selections = this.gridList.getSelectionModel().getSelection();
|
|
|
|
|
if (selections.length == 0) {
|
|
|
|
|
Ext.Msg.show({ title: Zi.LAN.Prompt, msg: Zi.LAN.SelectDanJu, icon: Ext.Msg.INFO, buttons: Ext.Msg.OK });
|
|
|
|
|
return;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
var isAuditExrate = false;
|
|
|
|
|
|
|
|
|
|
var bodyAddDatas = [];
|
|
|
|
|
for (var i = 0; i < selections.length; i++) {
|
|
|
|
|
var rec = selections[i];
|
|
|
|
|
var BILLSTATUS = rec.data.BILLSTATUS;
|
|
|
|
|
var IsAudit = rec.data.IsAudit;
|
|
|
|
|
if ((BILLSTATUS == '6' || BILLSTATUS == '2') && (IsAudit != 0)) {
|
|
|
|
|
bodyAddDatas.push(rec);
|
|
|
|
|
|
|
|
|
|
} else {
|
|
|
|
|
Ext.Msg.show({ title: Zi.LAN.Prompt, msg: Zi.LAN.NoShenHe, icon: Ext.Msg.INFO, buttons: Ext.Msg.OK });
|
|
|
|
|
return;
|
|
|
|
|
};
|
|
|
|
|
}
|
|
|
|
|
if (this.isuseexrate == 1) {
|
|
|
|
|
for (var i = 0; i < this.storeBodyListdetail.getCount(); i += 1) {
|
|
|
|
|
var member = this.storeBodyListdetail.getAt(i);
|
|
|
|
|
if ((member.data.FEENAME == this.YJFEENAME) || (member.data.FEENAME == this.YJFEENAMEUSD))
|
|
|
|
|
isAuditExrate = true;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
if (isAuditExrate && selections.length == 1) {
|
|
|
|
|
_this.formAuditStlShow.getForm().findField('STLAMOUNT').setValue(0)
|
|
|
|
|
_this.winAuditStlShow.show();
|
|
|
|
|
return;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
var jsonbodyAddDatas = ConvertRecordsToJsonAll(bodyAddDatas);
|
|
|
|
|
|
|
|
|
|
_this = this;
|
|
|
|
|
|
|
|
|
|
Ext.MessageBox.confirm(Zi.LAN.Prompt, Zi.LAN.SureShenHe, function (btn) {
|
|
|
|
|
if (btn == 'yes') {
|
|
|
|
|
Ext.Msg.wait(Zi.LAN.NowShenHe);
|
|
|
|
|
Ext.Ajax.request({
|
|
|
|
|
waitMsg: Zi.LAN.NowShenHe,
|
|
|
|
|
url: '/Account/Chfee_payapplication/AuditList',
|
|
|
|
|
params: {
|
|
|
|
|
data: jsonbodyAddDatas
|
|
|
|
|
},
|
|
|
|
|
callback: function (options, success, response) {
|
|
|
|
|
if (success) {
|
|
|
|
|
var jsonresult = Ext.JSON.decode(response.responseText);
|
|
|
|
|
if (jsonresult.Success) {
|
|
|
|
|
|
|
|
|
|
_this.storeList.reload();
|
|
|
|
|
if (jsonresult.Message != '审核通过') {
|
|
|
|
|
Ext.Msg.show({ title: Zi.LAN.Prompt, msg: jsonresult.Message, icon: Ext.Msg.INFO, buttons: Ext.Msg.OK });
|
|
|
|
|
} else Ext.Msg.hide();
|
|
|
|
|
}
|
|
|
|
|
else {
|
|
|
|
|
Ext.Msg.show({ title: Zi.LAN.Error, msg: jsonresult.Message, icon: Ext.Msg.ERROR, buttons: Ext.Msg.OK });
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
},
|
|
|
|
|
failure: function (response, options) {
|
|
|
|
|
Ext.Msg.show({ title: Zi.LAN.Caveat, msg: Zi.LAN.FuWuQiError, icon: Ext.Msg.INFO, buttons: Ext.Msg.OK });
|
|
|
|
|
},
|
|
|
|
|
success: function (response, options) {
|
|
|
|
|
},
|
|
|
|
|
scope: this
|
|
|
|
|
}); //end Ext.Ajax.request
|
|
|
|
|
}
|
|
|
|
|
}, this);
|
|
|
|
|
|
|
|
|
|
},
|
|
|
|
|
|
|
|
|
|
onAuditExratePassClick: function (stlcurr, stlrate, stlamount) {
|
|
|
|
|
|
|
|
|
|
var selections = this.gridList.getSelectionModel().getSelection();
|
|
|
|
|
if (selections.length == 0) {
|
|
|
|
|
Ext.Msg.show({ title: Zi.LAN.Prompt, msg: Zi.LAN.SelectDanJu, icon: Ext.Msg.INFO, buttons: Ext.Msg.OK });
|
|
|
|
|
return;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
var isAuditExrate = false;
|
|
|
|
|
|
|
|
|
|
var bodyAddDatas = [];
|
|
|
|
|
for (var i = 0; i < selections.length; i++) {
|
|
|
|
|
var rec = selections[i];
|
|
|
|
|
var BILLSTATUS = rec.data.BILLSTATUS;
|
|
|
|
|
var IsAudit = rec.data.IsAudit;
|
|
|
|
|
if ((BILLSTATUS == '6' || BILLSTATUS == '2') && (IsAudit != 0)) {
|
|
|
|
|
rec.data.STLCURR = stlcurr;
|
|
|
|
|
rec.data.STLRATE = stlrate;
|
|
|
|
|
rec.data.STLAMOUNT = stlamount;
|
|
|
|
|
bodyAddDatas.push(rec);
|
|
|
|
|
} else {
|
|
|
|
|
Ext.Msg.show({ title: Zi.LAN.Prompt, msg: Zi.LAN.NoShenHe, icon: Ext.Msg.INFO, buttons: Ext.Msg.OK });
|
|
|
|
|
return;
|
|
|
|
|
};
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
var jsonbodyAddDatas = ConvertRecordsToJsonAll(bodyAddDatas);
|
|
|
|
|
|
|
|
|
|
_this = this;
|
|
|
|
|
|
|
|
|
|
Ext.MessageBox.confirm(Zi.LAN.Prompt, Zi.LAN.SureShenHe, function (btn) {
|
|
|
|
|
if (btn == 'yes') {
|
|
|
|
|
Ext.Msg.wait(Zi.LAN.NowShenHe);
|
|
|
|
|
Ext.Ajax.request({
|
|
|
|
|
waitMsg: Zi.LAN.NowShenHe,
|
|
|
|
|
url: '/Account/Chfee_payapplication/AuditList',
|
|
|
|
|
params: {
|
|
|
|
|
data: jsonbodyAddDatas
|
|
|
|
|
},
|
|
|
|
|
callback: function (options, success, response) {
|
|
|
|
|
if (success) {
|
|
|
|
|
var jsonresult = Ext.JSON.decode(response.responseText);
|
|
|
|
|
if (jsonresult.Success) {
|
|
|
|
|
_this.storeList.reload();
|
|
|
|
|
_this.winAuditStlShow.close();
|
|
|
|
|
if (jsonresult.Message != '审核通过') {
|
|
|
|
|
Ext.Msg.show({ title: Zi.LAN.Prompt, msg: jsonresult.Message, icon: Ext.Msg.INFO, buttons: Ext.Msg.OK });
|
|
|
|
|
} else
|
|
|
|
|
Ext.Msg.hide();
|
|
|
|
|
// Ext.Msg.show({ title: Zi.LAN.Prompt, msg: jsonresult.Message, icon: Ext.Msg.INFO, buttons: Ext.Msg.OK });
|
|
|
|
|
}
|
|
|
|
|
else {
|
|
|
|
|
Ext.Msg.show({ title: Zi.LAN.Error, msg: jsonresult.Message, icon: Ext.Msg.ERROR, buttons: Ext.Msg.OK });
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
},
|
|
|
|
|
failure: function (response, options) {
|
|
|
|
|
Ext.Msg.show({ title: Zi.LAN.Caveat, msg: Zi.LAN.FuWuQiError, icon: Ext.Msg.INFO, buttons: Ext.Msg.OK });
|
|
|
|
|
},
|
|
|
|
|
success: function (response, options) {
|
|
|
|
|
},
|
|
|
|
|
scope: this
|
|
|
|
|
}); //end Ext.Ajax.request
|
|
|
|
|
}
|
|
|
|
|
}, this);
|
|
|
|
|
|
|
|
|
|
},
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
onAuditBackClick: function () {
|
|
|
|
|
|
|
|
|
|
var selections = this.gridList.getSelectionModel().getSelection();
|
|
|
|
|
if (selections.length == 0) {
|
|
|
|
|
Ext.Msg.show({ title: Zi.LAN.Prompt, msg: Zi.LAN.DismissDocuments, icon: Ext.Msg.INFO, buttons: Ext.Msg.OK });
|
|
|
|
|
return;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
var bodyAddDatas = [];
|
|
|
|
|
for (var i = 0; i < selections.length; i++) {
|
|
|
|
|
var rec = selections[i];
|
|
|
|
|
var BILLSTATUS = rec.data.BILLSTATUS;
|
|
|
|
|
var IsAudit = rec.data.IsAudit;
|
|
|
|
|
if ((BILLSTATUS == '0' || BILLSTATUS == '2') && (IsAudit != -1)) {
|
|
|
|
|
bodyAddDatas.push(rec);
|
|
|
|
|
} else {
|
|
|
|
|
Ext.Msg.show({ title: Zi.LAN.Prompt, msg: Zi.LAN.DismissDocumentsNo, icon: Ext.Msg.INFO, buttons: Ext.Msg.OK });
|
|
|
|
|
return;
|
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
var jsonbodyAddDatas = ConvertRecordsToJsonAll(bodyAddDatas);
|
|
|
|
|
|
|
|
|
|
_this = this;
|
|
|
|
|
|
|
|
|
|
Ext.MessageBox.show({
|
|
|
|
|
title: Zi.LAN.Tishi7,
|
|
|
|
|
msg: Zi.LAN.Tishi8,
|
|
|
|
|
width: 300,
|
|
|
|
|
buttons: Ext.MessageBox.OKCANCEL,
|
|
|
|
|
multiline: true,
|
|
|
|
|
fn: function (btn, text) {
|
|
|
|
|
if (btn == "ok") {
|
|
|
|
|
Ext.Ajax.request({
|
|
|
|
|
waitMsg: Zi.LAN.DismissDocumentsNow,
|
|
|
|
|
url: '/Account/Chfee_payapplication/AuditBackList',
|
|
|
|
|
params: {
|
|
|
|
|
data: jsonbodyAddDatas,
|
|
|
|
|
reason: text
|
|
|
|
|
},
|
|
|
|
|
callback: function (options, success, response) {
|
|
|
|
|
if (success) {
|
|
|
|
|
var jsonresult = Ext.JSON.decode(response.responseText);
|
|
|
|
|
if (jsonresult.Success) {
|
|
|
|
|
_this.storeList.reload();
|
|
|
|
|
Ext.Msg.hide();
|
|
|
|
|
}
|
|
|
|
|
else {
|
|
|
|
|
Ext.Msg.show({ title: Zi.LAN.Error, msg: jsonresult.Message, icon: Ext.Msg.ERROR, buttons: Ext.Msg.OK });
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
},
|
|
|
|
|
failure: function (response, options) {
|
|
|
|
|
Ext.Msg.show({ title: Zi.LAN.Caveat, msg: Zi.LAN.FuWuQiError, icon: Ext.Msg.INFO, buttons: Ext.Msg.OK });
|
|
|
|
|
},
|
|
|
|
|
success: function (response, options) {
|
|
|
|
|
},
|
|
|
|
|
scope: this
|
|
|
|
|
}); //end Ext.Ajax.request
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
// Ext.MessageBox.confirm(Zi.LAN.Prompt, Zi.LAN.DismissDocumentsSure, function (btn) {
|
|
|
|
|
// if (btn == 'yes') {
|
|
|
|
|
// Ext.Msg.wait(Zi.LAN.DismissDocumentsNow);
|
|
|
|
|
// Ext.Ajax.request({
|
|
|
|
|
// waitMsg: Zi.LAN.DismissDocumentsNow,
|
|
|
|
|
// url: '/Account/Chfee_payapplication/AuditBackList',
|
|
|
|
|
// params: {
|
|
|
|
|
// data: jsonbodyAddDatas
|
|
|
|
|
// },
|
|
|
|
|
// callback: function (options, success, response) {
|
|
|
|
|
// if (success) {
|
|
|
|
|
// var jsonresult = Ext.JSON.decode(response.responseText);
|
|
|
|
|
// if (jsonresult.Success) {
|
|
|
|
|
// _this.storeList.reload();
|
|
|
|
|
// Ext.Msg.show({ title: Zi.LAN.Prompt, msg: Zi.LAN.DismissSuccess, icon: Ext.Msg.INFO, buttons: Ext.Msg.OK });
|
|
|
|
|
// }
|
|
|
|
|
// else {
|
|
|
|
|
// Ext.Msg.show({ title: Zi.LAN.Error, msg: jsonresult.Message, icon: Ext.Msg.ERROR, buttons: Ext.Msg.OK });
|
|
|
|
|
// }
|
|
|
|
|
// }
|
|
|
|
|
// },
|
|
|
|
|
// failure: function (response, options) {
|
|
|
|
|
// Ext.Msg.show({ title: Zi.LAN.Caveat, msg: Zi.LAN.FuWuQiError, icon: Ext.Msg.INFO, buttons: Ext.Msg.OK });
|
|
|
|
|
// },
|
|
|
|
|
// success: function (response, options) {
|
|
|
|
|
// },
|
|
|
|
|
// scope: this
|
|
|
|
|
// }); //end Ext.Ajax.request
|
|
|
|
|
// }
|
|
|
|
|
// }, this);
|
|
|
|
|
|
|
|
|
|
},
|
|
|
|
|
|
|
|
|
|
onAllAuditClick: function (menu, event) {
|
|
|
|
|
|
|
|
|
|
if (this.storeList.length == 0) {
|
|
|
|
|
Ext.Msg.show({ title: Zi.LAN.Prompt, msg: Zi.LAN.NoAudit, icon: Ext.Msg.INFO, buttons: Ext.Msg.OK });
|
|
|
|
|
return;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
_this = this;
|
|
|
|
|
Ext.MessageBox.confirm(Zi.LAN.Prompt, Zi.LAN.SureShenHeAll, function (btn) {
|
|
|
|
|
if (btn == 'yes') {
|
|
|
|
|
Ext.Msg.wait(Zi.LAN.NowAudit);
|
|
|
|
|
Ext.Ajax.request({
|
|
|
|
|
waitMsg: Zi.LAN.Zhengzaisuoding,
|
|
|
|
|
url: '/Account/Chfee_payapplication/AllAudit',
|
|
|
|
|
params: {
|
|
|
|
|
condition: _this.BillSql
|
|
|
|
|
},
|
|
|
|
|
callback: function (options, success, response) {
|
|
|
|
|
if (success) {
|
|
|
|
|
var result = Ext.JSON.decode(response.responseText);
|
|
|
|
|
if (!result.Success) {
|
|
|
|
|
Ext.Msg.show({
|
|
|
|
|
title: Zi.LAN.Prompt,
|
|
|
|
|
msg: result.Message,
|
|
|
|
|
icon: Ext.MessageBox.ERROR,
|
|
|
|
|
buttons: Ext.Msg.OK
|
|
|
|
|
});
|
|
|
|
|
return;
|
|
|
|
|
} else {
|
|
|
|
|
|
|
|
|
|
Ext.Msg.hide();
|
|
|
|
|
_this.onRefreshClick();
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
} else {
|
|
|
|
|
Ext.MessageBox.alert(Zi.LAN.FuWuQiError, response.responseText);
|
|
|
|
|
}
|
|
|
|
|
},
|
|
|
|
|
scope: this
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
}, this);
|
|
|
|
|
|
|
|
|
|
},
|
|
|
|
|
|
|
|
|
|
onClearSql: function () {
|
|
|
|
|
var form = this.formSearch.getForm();
|
|
|
|
|
form.reset();
|
|
|
|
|
}, //onDeleteClick
|
|
|
|
|
|
|
|
|
|
onRefreshClick: function (button, event) {
|
|
|
|
|
var sql = this.getCondition();
|
|
|
|
|
this.BillSql = sql;
|
|
|
|
|
_this.panelBillSum.setTitle(Zi.LAN.SumMoney, false);
|
|
|
|
|
|
|
|
|
|
this.PageSize = this.Pagenum.getValue();
|
|
|
|
|
this.storeList.pageSize = this.PageSize;
|
|
|
|
|
this.storeList.load({
|
|
|
|
|
params: { start: 0, limit: this.PageSize, sort: '', condition: sql, isaudit: this.isAudit },
|
|
|
|
|
waitMsg: Zi.LAN.NowSelect,
|
|
|
|
|
callback: function (r, options, success) {
|
|
|
|
|
if (success) {
|
|
|
|
|
if (r.length == 0) {
|
|
|
|
|
|
|
|
|
|
var sql = " BILLNO='11111111' ";
|
|
|
|
|
this.storeBodyListdetail.load({ params: { start: 0, limit: _this.BodyPageSize,condition: sql} });
|
|
|
|
|
this.storeBodySum.load({ params: { condition: sql} });
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
},
|
|
|
|
|
scope: this
|
|
|
|
|
});
|
|
|
|
|
},
|
|
|
|
|
onDsQuery: function () {
|
|
|
|
|
//var girdcolums = this.gridList.getColumnMode();
|
|
|
|
|
var sql = this.sqlcontext;
|
|
|
|
|
this.PageSize = this.Pagenum.getValue();
|
|
|
|
|
this.storeList.pageSize = this.PageSize;
|
|
|
|
|
this.storeList.load({
|
|
|
|
|
params: { start: 0, limit: this.PageSize, sort: '', condition: sql },
|
|
|
|
|
waitMsg: Zi.LAN.NowSelect,
|
|
|
|
|
scope: this
|
|
|
|
|
});
|
|
|
|
|
},
|
|
|
|
|
RpttabChange: function (tabPanel, newCard, oldCard, eOpts) {
|
|
|
|
|
if (newCard == this.panelttlBillSum) {
|
|
|
|
|
|
|
|
|
|
var sql = " B.BSNO IN (SELECT BSNO FROM CH_FEE_DO WHERE BILLNO='" + _this.billno + "') ";
|
|
|
|
|
this.storeListbillsum.load({ params: { start: 0, limit: _this.BodyPageSize, condition: sql } });
|
|
|
|
|
}
|
|
|
|
|
},
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
onExportClick: function (button, event) {
|
|
|
|
|
|
|
|
|
|
_this = this;
|
|
|
|
|
GridExportExcelPage(this.gridList);
|
|
|
|
|
},
|
|
|
|
|
|
|
|
|
|
Print: function () {
|
|
|
|
|
|
|
|
|
|
var selections = this.gridList.getSelectionModel().getSelection();
|
|
|
|
|
if (selections.length == 0) {
|
|
|
|
|
Ext.Msg.show({ title: Zi.LAN.Prompt, msg: Zi.LAN.SelectDanju, icon: Ext.Msg.INFO, buttons: Ext.Msg.OK });
|
|
|
|
|
return;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
var record = selections[0];
|
|
|
|
|
var billNo = record.data.BILLNO;
|
|
|
|
|
|
|
|
|
|
var sortstr = ' b.VESSEL,b.VOYNO,b.MBLNO ';
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
var printType = 'MSCHFEEPAYAPPLICATION';
|
|
|
|
|
var sql1 = "SELECT p.*,(select ShowName from [user] where GID=p.APPLICANT) as APPLICANTNAME,(select bankname from info_client_bank where gid=p.CUSTACCOUNTGID) CUSTBANKNAME,";
|
|
|
|
|
sql1 = sql1 + "(select ACCOUNT from info_client_bank where gid=p.CUSTACCOUNTGID) CUSTACCOUNT,(select DESCRIPTION from info_client where SHORTNAME=p.CUSTOMERNAME) CUSTFULLNAME FROM ch_fee_payapplication p WHERE BILLNO='" + billNo + "'";
|
|
|
|
|
var sql2 = "SELECT c.GID,c.BSNO,c.FEEID,c.FEENAME,c.CURRENCY,c.AMOUNT,c.DOAMOUNT,c.ORIGCURRENCY,c.ORIGAMOUNT,c.EXCHANGERATE,FEETYPE ";
|
|
|
|
|
sql2 = sql2 + ",b.CUSTOMERNAME,b.VESSEL,b.VOYNO,b.ETD,b.PORTLOAD";
|
|
|
|
|
sql2 = sql2 + " ,b.PORTDISCHARGE,b.INPUTBY,b.OP,b.CUSTSERVICE,b.DOC,b.SALE,b.MBLNO,b.CUSTNO"
|
|
|
|
|
sql2 = sql2 + " FROM ch_fee_do c left join v_op_bill b on (b.bsno=c.bsno)";
|
|
|
|
|
sql2 = sql2 + " WHERE C.BILLNO='" + billNo + "' ORDER BY " + sortstr;
|
|
|
|
|
|
|
|
|
|
var sql3 = "";
|
|
|
|
|
var sql4 = "";
|
|
|
|
|
var sql5 = "";
|
|
|
|
|
var sql6 = "";
|
|
|
|
|
PrintComm(printType, sql1, sql2, sql3, sql4, sql5, sql6);
|
|
|
|
|
},
|
|
|
|
|
SetNoPrint: function () {
|
|
|
|
|
var selections = this.gridList.getSelectionModel().getSelection();
|
|
|
|
|
if (selections.length == 0) {
|
|
|
|
|
Ext.Msg.show({ title: Zi.LAN.Prompt, msg: Zi.LAN.SelectDanju, icon: Ext.Msg.INFO, buttons: Ext.Msg.OK });
|
|
|
|
|
return;
|
|
|
|
|
}
|
|
|
|
|
var feeGidSql = '';
|
|
|
|
|
for (var i = 0; i < selections.length; i++) {
|
|
|
|
|
var record = selections[i];
|
|
|
|
|
var feeGId = "'" + record.get('BILLNO') + "'";
|
|
|
|
|
if (feeGidSql == '') {
|
|
|
|
|
feeGidSql = feeGId;
|
|
|
|
|
} else {
|
|
|
|
|
feeGidSql = feeGidSql + "," + feeGId;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
Ext.Ajax.request({
|
|
|
|
|
waitMsg: '',
|
|
|
|
|
url: '/Account/Chfee_payapplication/UpdateNoPrint',
|
|
|
|
|
params: {
|
|
|
|
|
billnos: feeGidSql
|
|
|
|
|
},
|
|
|
|
|
callback: function (options, success, response) {
|
|
|
|
|
if (success) {
|
|
|
|
|
var result = Ext.JSON.decode(response.responseText);
|
|
|
|
|
if (!result.Success) {
|
|
|
|
|
Ext.Msg.show({//提示
|
|
|
|
|
title: Zi.LAN.Prompt,
|
|
|
|
|
msg: result.Message,
|
|
|
|
|
icon: Ext.MessageBox.ERROR,
|
|
|
|
|
buttons: Ext.Msg.OK
|
|
|
|
|
});
|
|
|
|
|
return;
|
|
|
|
|
} else {
|
|
|
|
|
Ext.Msg.show({ title: '提示', msg: result.Message, icon: Ext.Msg.INFO, buttons: Ext.Msg.OK });
|
|
|
|
|
_this.storeList.reload();
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
} else {//请求出现错误,请重试
|
|
|
|
|
Ext.MessageBox.alert(Zi.LAN.FuWuQiError, response.responseText);
|
|
|
|
|
}
|
|
|
|
|
},
|
|
|
|
|
scope: this
|
|
|
|
|
});
|
|
|
|
|
},
|
|
|
|
|
|
|
|
|
|
PrintSelect: function () {
|
|
|
|
|
|
|
|
|
|
var selections = this.gridList.getSelectionModel().getSelection();
|
|
|
|
|
if (selections.length == 0) {
|
|
|
|
|
//Ext.Msg.show({ title: Zi.LAN.Prompt, msg: Zi.LAN.SelectDanju, icon: Ext.Msg.INFO, buttons: Ext.Msg.OK });
|
|
|
|
|
return;
|
|
|
|
|
}
|
|
|
|
|
var isaudit = 1;
|
|
|
|
|
var isprint = 0;
|
|
|
|
|
var feeGidSql = '';
|
|
|
|
|
for (var i = 0; i < selections.length; i++) {
|
|
|
|
|
var record = selections[i];
|
|
|
|
|
var feeGId = "'" + record.get('BILLNO') + "'";
|
|
|
|
|
if (feeGidSql == '') {
|
|
|
|
|
feeGidSql = feeGId;
|
|
|
|
|
} else {
|
|
|
|
|
feeGidSql = feeGidSql + "," + feeGId;
|
|
|
|
|
}
|
|
|
|
|
if (record.data.BILLSTATUSREF != '审核通过' && record.data.BILLSTATUSREF != '已结算' && record.data.BILLSTATUSREF != '部分结算') {
|
|
|
|
|
isaudit = 0;
|
|
|
|
|
}
|
|
|
|
|
if (record.data.ISPRINT == '1') {
|
|
|
|
|
isprint = 1;
|
|
|
|
|
}
|
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
var record = selections[0];
|
|
|
|
|
var billNo = record.data.BILLNO;
|
|
|
|
|
|
|
|
|
|
var printType = 'MSCHFEEPAYAPPLICATIONSEL';
|
|
|
|
|
var sql1 = "SELECT p.*,(select ShowName from [user] where GID=p.APPLICANT) as APPLICANTNAME,(select bankname from info_client_bank where gid=p.CUSTACCOUNTGID) CUSTBANKNAME,";
|
|
|
|
|
sql1 = sql1 + "(select ACCOUNT from info_client_bank where gid=p.CUSTACCOUNTGID) CUSTACCOUNT,dbo.GetStlByPayNo(p.BILLNO) as BALBILLNO FROM ch_fee_payapplication p WHERE BILLNO IN (" + feeGidSql + ") ";
|
|
|
|
|
var sql2 = "";
|
|
|
|
|
|
|
|
|
|
var sql3 = "";
|
|
|
|
|
var sql4 = "";
|
|
|
|
|
var sql5 = "";
|
|
|
|
|
var sql6 = "";
|
|
|
|
|
|
|
|
|
|
if (isaudit == 1 && isprint == 0) {
|
|
|
|
|
PrintComm(printType, sql1, sql2, sql3, sql4, sql5, sql6);
|
|
|
|
|
Ext.Ajax.request({
|
|
|
|
|
waitMsg: '',
|
|
|
|
|
url: '/Account/Chfee_payapplication/UpdatePrint',
|
|
|
|
|
params: {
|
|
|
|
|
billnos: feeGidSql
|
|
|
|
|
},
|
|
|
|
|
callback: function (options, success, response) {
|
|
|
|
|
if (success) {
|
|
|
|
|
_this.storeList.reload();
|
|
|
|
|
} else {
|
|
|
|
|
}
|
|
|
|
|
},
|
|
|
|
|
scope: this
|
|
|
|
|
});
|
|
|
|
|
} else {
|
|
|
|
|
|
|
|
|
|
Ext.Ajax.request({
|
|
|
|
|
waitMsg: '',
|
|
|
|
|
url: '/MvcShipping/MsSysParamSet/GetData',
|
|
|
|
|
params: {
|
|
|
|
|
condition: "PARAMNAME='PAYAPPPRINTAFTERAUDIT'"
|
|
|
|
|
},
|
|
|
|
|
callback: function (options, success, response) {
|
|
|
|
|
if (success) {
|
|
|
|
|
var result = Ext.JSON.decode(response.responseText);
|
|
|
|
|
if (result.Success != true) {
|
|
|
|
|
|
|
|
|
|
} else {
|
|
|
|
|
var data = result.data;
|
|
|
|
|
if (data.PARAMVALUE == '1' && isaudit == 0) {
|
|
|
|
|
Ext.Msg.show({ title: Zi.LAN.Error, msg: Zi.LAN.shtgprint, icon: Ext.Msg.ERROR, buttons: Ext.Msg.OK });
|
|
|
|
|
return;
|
|
|
|
|
|
|
|
|
|
} else {
|
|
|
|
|
Ext.Ajax.request({
|
|
|
|
|
waitMsg: '',
|
|
|
|
|
url: '/MvcShipping/MsSysParamSet/GetData',
|
|
|
|
|
params: {
|
|
|
|
|
condition: "PARAMNAME='PAYAPPONLYPRINTONE'"
|
|
|
|
|
},
|
|
|
|
|
callback: function (options, success, response) {
|
|
|
|
|
if (success) {
|
|
|
|
|
var result = Ext.JSON.decode(response.responseText);
|
|
|
|
|
if (result.Success != true) {
|
|
|
|
|
|
|
|
|
|
} else {
|
|
|
|
|
var data = result.data;
|
|
|
|
|
if (data.PARAMVALUE == '1' && isprint == 1) {
|
|
|
|
|
Ext.Msg.show({ title: Zi.LAN.Error, msg: Zi.LAN.notcfprint, icon: Ext.Msg.ERROR, buttons: Ext.Msg.OK });
|
|
|
|
|
return;
|
|
|
|
|
|
|
|
|
|
} else {
|
|
|
|
|
Ext.Ajax.request({
|
|
|
|
|
waitMsg: '',
|
|
|
|
|
url: '/Account/Chfee_payapplication/UpdatePrint',
|
|
|
|
|
params: {
|
|
|
|
|
billnos: feeGidSql
|
|
|
|
|
},
|
|
|
|
|
callback: function (options, success, response) {
|
|
|
|
|
if (success) {
|
|
|
|
|
_this.storeList.reload();
|
|
|
|
|
} else {
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
},
|
|
|
|
|
scope: this
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
PrintComm(printType, sql1, sql2, sql3, sql4, sql5, sql6);
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
} else {
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
},
|
|
|
|
|
scope: this
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
// PrintComm(printType, sql1, sql2, sql3, sql4, sql5, sql6);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
} else {
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
},
|
|
|
|
|
scope: this
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
},
|
|
|
|
|
|
|
|
|
|
getCondition: function () {
|
|
|
|
|
var form = this.formSearch.getForm();
|
|
|
|
|
if (!form.isValid()) {
|
|
|
|
|
Ext.Msg.alert(Zi.LAN.Prompt, Zi.LAN.SelectError);
|
|
|
|
|
return '';
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
var sql = '';
|
|
|
|
|
|
|
|
|
|
var customNo = form.findField('BsNo').getValue();
|
|
|
|
|
sql = sql + getAndConSql(sql, customNo, "BILLNO like '%" + customNo + "%'");
|
|
|
|
|
|
|
|
|
|
var sBsNo = form.findField('sBsNo').getValue();
|
|
|
|
|
sql = sql + getAndConSql(sql, sBsNo, " EXISTS (select 1 from ch_fee_do d where d.BILLNO=i.BILLNO AND d.BSNO IN (SELECT BSNO FROM V_OP_BILL WHERE CUSTNO like '%" + sBsNo + "%' or MBLNO like '%" + sBsNo + "%' or HBLNO like '%" + sBsNo + "%' or CUSTOMNO like '%" + sBsNo + "%' or ORDERNO like '%" + sBsNo + "%'))");
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
var custName = form.findField('CustName').getValue();
|
|
|
|
|
sql = sql + getAndConSql(sql, custName, "CUSTOMERNAME like '%" + custName + "%'");
|
|
|
|
|
|
|
|
|
|
var expDateBgn = form.findField('ExpDateBgn').getRawValue();
|
|
|
|
|
sql = sql + getAndConSql(sql, expDateBgn, "APPLYTIME >='" + expDateBgn + "'");
|
|
|
|
|
|
|
|
|
|
var expDateEnd = form.findField('ExpDateEnd').getRawValue();
|
|
|
|
|
sql = sql + getAndConSql(sql, expDateEnd, "APPLYTIME <='" + expDateEnd + "'");
|
|
|
|
|
|
|
|
|
|
var APPLICANT = form.findField('APPLICANT').getValue();
|
|
|
|
|
sql = sql + getAndConSql(sql, APPLICANT, "APPLICANT= '" + APPLICANT + "'");
|
|
|
|
|
|
|
|
|
|
this.isAudit = form.findField('DC').getValue();
|
|
|
|
|
|
|
|
|
|
return sql;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
|