You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
4123 lines
143 KiB
JavaScript
4123 lines
143 KiB
JavaScript
//集运管理-路单查询
|
|
Ext.namespace('Shipping');
|
|
|
|
Shipping.MsRptOpXsListIndex = function (config) {
|
|
Ext.applyIf(this, config);
|
|
this.initUIComponents();
|
|
window.Shipping.MsRptOpXsListIndex.superclass.constructor.call(this);
|
|
};
|
|
|
|
Ext.extend(Shipping.MsRptOpXsListIndex, Ext.Panel, {
|
|
PageSize: 100,
|
|
OprationStatus: null, //仅当弹出界面时使用
|
|
SelectedRecord: null,
|
|
sqlcontext: '1=2',
|
|
feesqlcontext:'',
|
|
bslistsortfield: '',
|
|
bslistsortdire: '',
|
|
salelistsortfield: '',
|
|
salelistsortdire: '',
|
|
custlistsortfield: '',
|
|
custlistsortdire: '',
|
|
deptlistsortfield: '',
|
|
deptlistsortdire: '',
|
|
oplistsortfield: '',
|
|
oplistsortdire: '',
|
|
bssourcelistsortfield: '',
|
|
bssourcelistsortdire: '',
|
|
bssourcedetaillistsortfield: '',
|
|
bssourcedetaillistsortdire: '',
|
|
carrierlistsortfield: '',
|
|
carrierlistsortdire: '',
|
|
lanelistsortfield: '',
|
|
lanelistsortdire: '',
|
|
destinationlistsortfield: '',
|
|
destinationlistsortdire: '',
|
|
|
|
initUIComponents: function () {
|
|
|
|
|
|
Ext.Ajax.timeout = 120000;
|
|
this.formname = 'MsRptOpXsListIndex';
|
|
this.storectndisp = Ext.create('DsExt.ux.RefTableStore', {
|
|
model: 'DsShipping.ux.CtnDispModel',
|
|
proxy: { url: '/CommMng/BasicDataRef/GetCtnDisp' }
|
|
});
|
|
|
|
this.sqlcontext = '1=2';
|
|
|
|
//定义数据集
|
|
this.storeList = Ext.create('Ext.data.Store', {
|
|
pageSize: this.PageSize,
|
|
fields: [
|
|
{ name: 'BSNO', type: 'string' },
|
|
{ name: 'OPLB', type: 'string' },
|
|
{ name: 'OPLBNAME', type: 'string' },
|
|
{ name: 'BSTYPE', type: 'string' },
|
|
{ name: 'BLTYPE', type: 'string' },
|
|
{ name: 'ISCANCEL', type: 'string' },
|
|
{ name: 'FEESTATUSREF', type: 'string' },
|
|
{ name: 'CUSTOMERNAME', type: 'string' },
|
|
{ name: 'CUSTFULLNAME', type: 'string' },
|
|
{ name: 'YARD', type: 'string' },
|
|
{ name: 'CUSTNO', type: 'string' },
|
|
{ name: 'MBLNO', type: 'string' },
|
|
{ name: 'HBLNO', type: 'string' },
|
|
{ name: 'ETD', 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: '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: 'LANE', 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: 'ENTERP', type: 'string' },
|
|
{ name: 'REMARK', type: 'string' },
|
|
{ name: 'PKGS', type: 'number' },
|
|
{ name: 'CBM', type: 'number' },
|
|
{ name: 'KGS', type: 'number' },
|
|
{ name: 'NETWEIGHT', type: 'number' },
|
|
{ name: 'TEU', type: 'number' },
|
|
{ name: 'CNTR1', type: 'number' },
|
|
{ name: 'CNTR2', type: 'number' },
|
|
{ name: 'CNTR3', type: 'number' },
|
|
{ name: 'CNTR4', type: 'number' },
|
|
{ name: 'CNTR5', type: 'number' },
|
|
{ name: 'CNTR6', type: 'number' },
|
|
{ name: 'CNTR7', type: 'number' },
|
|
{ name: 'CNTR8', type: 'number' },
|
|
{ name: 'CNTR9', type: 'number' },
|
|
{ name: 'CNTR10', type: 'number' },
|
|
{ name: 'OTCNTR', type: 'number' },
|
|
{ name: 'OPXS', type: 'number' }
|
|
|
|
],
|
|
remoteSort: true,
|
|
proxy: {
|
|
type: 'ajax',
|
|
timeout: 120000,
|
|
url: '/MvcShipping/MsRptOpBsList/OpXsListData',
|
|
reader: {
|
|
id: '',
|
|
root: 'data',
|
|
totalProperty: 'totalCount'
|
|
}
|
|
}
|
|
});
|
|
|
|
//定义Grid
|
|
this.initgirdcolums = [{
|
|
sortable: true,
|
|
dataIndex: 'BSNO',
|
|
text: '编号',
|
|
hidden: true,
|
|
width: 130
|
|
}, {
|
|
sortable: true,
|
|
dataIndex: 'OPLBNAME',
|
|
text: '业务类型',
|
|
width: 70
|
|
}, {
|
|
dataIndex: 'ISCANCEL',
|
|
header: '退舱', //'退舱',
|
|
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: 'FEESTATUSREF',
|
|
text: '费用锁定',
|
|
width: 70
|
|
}, {
|
|
sortable: true,
|
|
dataIndex: 'BSTYPE',
|
|
text: '运输类型',
|
|
width: 70
|
|
}, {
|
|
sortable: true,
|
|
dataIndex: 'BLTYPE',
|
|
text: '装运方式',
|
|
width: 70
|
|
}, {
|
|
sortable: true,
|
|
dataIndex: 'OPDATE',
|
|
text: '业务日期',
|
|
width: 86
|
|
}, {
|
|
sortable: true,
|
|
dataIndex: 'OPXS',
|
|
text: '操作系数',
|
|
width: 86
|
|
}, {
|
|
sortable: true,
|
|
dataIndex: 'CUSTOMDATE',
|
|
text: '报关日期',
|
|
width: 86
|
|
}, {
|
|
sortable: true,
|
|
dataIndex: 'CUSTOMERNAME',
|
|
text: '委托单位',
|
|
width: 120
|
|
}, {
|
|
sortable: true,
|
|
dataIndex: 'CUSTFULLNAME',
|
|
text: '委托单位全称',
|
|
width: 140
|
|
}, {
|
|
sortable: true,
|
|
dataIndex: 'CUSTNO',
|
|
text: '委托编号',
|
|
width: 136
|
|
}, {
|
|
sortable: true,
|
|
dataIndex: 'CUSTOMNO',
|
|
text: '报关单号',
|
|
width: 136
|
|
}, {
|
|
sortable: true,
|
|
dataIndex: 'ENTERP',
|
|
text: '经营单位',
|
|
width: 100
|
|
}, {
|
|
sortable: true,
|
|
dataIndex: 'MBLNO',
|
|
text: '主提单号',
|
|
width: 120
|
|
}, {
|
|
sortable: true,
|
|
dataIndex: 'HBLNO',
|
|
text: '分提单号',
|
|
width: 120
|
|
}, {
|
|
sortable: true,
|
|
dataIndex: 'ETD',
|
|
text: '开船日期',
|
|
width: 86
|
|
}, {
|
|
sortable: true,
|
|
dataIndex: 'VESSEL',
|
|
text: '船名',
|
|
width: 200
|
|
}, {
|
|
sortable: true,
|
|
dataIndex: 'VOYNO',
|
|
text: '航次',
|
|
width: 50
|
|
}, {
|
|
sortable: true,
|
|
dataIndex: 'SALE',
|
|
text: '揽货人',
|
|
width: 80
|
|
}, {
|
|
sortable: true,
|
|
dataIndex: 'OP',
|
|
text: '操作',
|
|
width: 80
|
|
}, {
|
|
sortable: true,
|
|
dataIndex: 'DOC',
|
|
text: '单证',
|
|
width: 80
|
|
}, {
|
|
sortable: true,
|
|
dataIndex: 'CUSTSERVICE',
|
|
text: '客服员',
|
|
width: 80
|
|
}, {
|
|
sortable: true,
|
|
dataIndex: 'PORTLOAD',
|
|
text: '起运港',
|
|
width: 80
|
|
}, {
|
|
sortable: true,
|
|
dataIndex: 'PORTDISCHARGE',
|
|
text: '卸货港',
|
|
width: 150
|
|
}, {
|
|
sortable: true,
|
|
dataIndex: 'DESTINATION',
|
|
text: '目的地',
|
|
width: 150
|
|
}, {
|
|
sortable: true,
|
|
dataIndex: 'ACCDATE',
|
|
text: '会计期间',
|
|
width: 80
|
|
}, {
|
|
sortable: true,
|
|
dataIndex: 'CARRIER',
|
|
text: '船公司',
|
|
width: 80
|
|
}, {
|
|
sortable: true,
|
|
dataIndex: 'LANE',
|
|
text: '航线',
|
|
width: 80
|
|
}, {
|
|
sortable: true,
|
|
dataIndex: 'BSSOURCE',
|
|
text: '业务来源',
|
|
width: 120
|
|
}, {
|
|
sortable: true,
|
|
dataIndex: 'YARD',
|
|
text: '场站',
|
|
width: 80
|
|
}, {
|
|
sortable: true,
|
|
dataIndex: 'REMARK',
|
|
text: '备注',
|
|
width: 120
|
|
}, {
|
|
sortable: true,
|
|
dataIndex: 'TEU',
|
|
text: 'TEU',
|
|
width: 80
|
|
}, {
|
|
sortable: true,
|
|
dataIndex: 'PKGS',
|
|
text: '件数',
|
|
width: 80
|
|
}, {
|
|
sortable: true,
|
|
dataIndex: 'KGS',
|
|
text: 'KGS',
|
|
width: 80
|
|
}, {
|
|
sortable: true,
|
|
dataIndex: 'CBM',
|
|
text: '尺码',
|
|
width: 80
|
|
}, {
|
|
sortable: true,
|
|
dataIndex: 'NETWEIGHT',
|
|
text: '计费重量(或净重)',
|
|
width: 80
|
|
}, {
|
|
sortable: true,
|
|
dataIndex: 'GOODSNAME',
|
|
text: '品名',
|
|
width: 80
|
|
}, {
|
|
sortable: true,
|
|
dataIndex: 'CNTRTOTAL',
|
|
text: '集装箱',
|
|
width: 80
|
|
}, {
|
|
sortable: true,
|
|
dataIndex: 'CREATETIME',
|
|
text: '创建时间',
|
|
width: 80
|
|
}
|
|
,
|
|
{
|
|
sortable: true,
|
|
id: '',
|
|
dataIndex: 'CNTR1',
|
|
text: '箱型1',
|
|
width: 60
|
|
},
|
|
{
|
|
sortable: true,
|
|
id: '',
|
|
dataIndex: 'CNTR2',
|
|
text: '箱型2',
|
|
width: 60
|
|
},
|
|
{
|
|
sortable: true,
|
|
id: '',
|
|
dataIndex: 'CNTR3',
|
|
text: '箱型3',
|
|
width: 60
|
|
},
|
|
{
|
|
sortable: true,
|
|
id: '',
|
|
dataIndex: 'CNTR4',
|
|
text: '箱型4',
|
|
width: 60
|
|
},
|
|
{
|
|
sortable: true,
|
|
id: '',
|
|
dataIndex: 'CNTR5',
|
|
text: '箱型5',
|
|
width: 60
|
|
},
|
|
{
|
|
sortable: true,
|
|
id: '',
|
|
dataIndex: 'CNTR6',
|
|
text: '箱型6',
|
|
width: 60
|
|
},
|
|
{
|
|
sortable: true,
|
|
id: '',
|
|
dataIndex: 'CNTR7',
|
|
text: '箱型7',
|
|
width: 60
|
|
},
|
|
{
|
|
sortable: true,
|
|
id: '',
|
|
dataIndex: 'CNTR8',
|
|
text: '箱型8',
|
|
width: 60
|
|
},
|
|
{
|
|
sortable: true,
|
|
id: '',
|
|
dataIndex: 'CNTR9',
|
|
text: '箱型9',
|
|
width: 60
|
|
},
|
|
{
|
|
sortable: true,
|
|
id: '',
|
|
dataIndex: 'CNTR10',
|
|
text: '箱型10',
|
|
width: 60
|
|
},
|
|
{
|
|
sortable: true,
|
|
id: '',
|
|
dataIndex: 'OTCNTR',
|
|
text: '其他箱型',
|
|
width: 60
|
|
}];
|
|
|
|
this.Pagenum = Ext.create('Ext.form.field.Number', {
|
|
name: 'bottles',
|
|
fieldLabel: '每页记录数',
|
|
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.girdcolums = DsTruck.GetGridPanel(USERID, this.formname + 'bs', this.initgirdcolums, 1);
|
|
|
|
this.gridList = new Ext.grid.GridPanel({
|
|
store: this.storeList,
|
|
enableHdMenu: false,
|
|
region: 'center',
|
|
loadMask: { msg: "数据加载中,请稍等..." },
|
|
trackMouseOver: true,
|
|
disableSelection: false,
|
|
viewConfig: {
|
|
enableTextSelection: true, //允许复制数据
|
|
autoFill: true
|
|
},
|
|
columns: this.girdcolums,
|
|
// paging bar on the bottom
|
|
bbar: [Ext.create('Ext.PagingToolbar', {
|
|
store: this.storeList,
|
|
displayInfo: true,
|
|
displayMsg: '当前显示 {0} - {1}条记录 /共 {2}条记录',
|
|
emptyMsg: "没有数据"
|
|
}), this.Pagenum]
|
|
});
|
|
|
|
// this.girdcolums = DsTruck.GetGridPanel(USERID, this.formname + 'bs', this.girdcolums, 1);
|
|
// this.gridList.reconfigure(this.storeList, this.girdcolums);
|
|
|
|
|
|
this.gridList.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 = "";
|
|
if (record.data.OPLBNAME == "报关业务") {
|
|
openUrl = "../MvcShipping/MsOpApply/ApplyFeeView?handle=check&bsno=" + record.data.BSNO;
|
|
} else {
|
|
|
|
openUrl = "../MvcShipping/MsOpBill/MsOpFeeView?handle=check&bsno=" + record.data.BSNO;
|
|
|
|
}
|
|
window.open(openUrl, openType, openSet);
|
|
|
|
}, this);
|
|
|
|
this.gridList.addListener('sortchange', function (ct, column, direction, eOpts) {
|
|
this.bslistsortfield = column.dataIndex;
|
|
this.bslistsortdire = direction;
|
|
}, this);
|
|
|
|
|
|
this.storeSaleList = Ext.create('Ext.data.Store', {
|
|
pageSize: this.PageSize,
|
|
fields: [
|
|
|
|
{ name: 'SALE', type: 'string' },
|
|
{ name: 'BSSOURCE', type: 'string' },
|
|
{ name: 'BLCOUNT', type: 'number' },
|
|
{ name: 'NETWEIGHT', type: 'number' },
|
|
{ name: 'KGS', type: 'number' },
|
|
{ name: 'TEU', type: 'number' },
|
|
{ name: 'CNTR1', type: 'number' },
|
|
{ name: 'CNTR2', type: 'number' },
|
|
{ name: 'CNTR3', type: 'number' },
|
|
{ name: 'CNTR4', type: 'number' },
|
|
{ name: 'CNTR5', type: 'number' },
|
|
{ name: 'CNTR6', type: 'number' },
|
|
{ name: 'CNTR7', type: 'number' },
|
|
{ name: 'CNTR8', type: 'number' },
|
|
{ name: 'CNTR9', type: 'number' },
|
|
{ name: 'CNTR10', type: 'number' },
|
|
{ name: 'OTCNTR', type: 'number' }
|
|
|
|
],
|
|
remoteSort: true,
|
|
proxy: {
|
|
type: 'ajax',
|
|
timeout: 120000,
|
|
url: '/MvcShipping/MsRptOpBsList/SaleListData',
|
|
reader: {
|
|
id: '',
|
|
root: 'data',
|
|
totalProperty: 'totalCount'
|
|
}
|
|
},
|
|
groupField: 'SALE'
|
|
});
|
|
|
|
//定义Grid
|
|
this.initgirdcolumssale = [{
|
|
sortable: true,
|
|
dataIndex: 'SALE',
|
|
text: '揽货人',
|
|
width: 80
|
|
}, {
|
|
sortable: true,
|
|
dataIndex: 'BSSOURCE',
|
|
text: '业务来源',
|
|
width: 70
|
|
}, {
|
|
sortable: true,
|
|
dataIndex: 'BLCOUNT',
|
|
text: '票数',
|
|
summaryType: 'sum',
|
|
// summaryRenderer: Ext.util.Format.numberRenderer('00.00'),
|
|
width: 80
|
|
},
|
|
{
|
|
sortable: true,
|
|
id: '',
|
|
dataIndex: 'CNTR1',
|
|
text: '箱型1',
|
|
width: 60
|
|
},
|
|
{
|
|
sortable: true,
|
|
id: '',
|
|
dataIndex: 'CNTR2',
|
|
text: '箱型2',
|
|
width: 60
|
|
},
|
|
{
|
|
sortable: true,
|
|
id: '',
|
|
dataIndex: 'CNTR3',
|
|
text: '箱型3',
|
|
width: 60
|
|
},
|
|
{
|
|
sortable: true,
|
|
id: '',
|
|
dataIndex: 'CNTR4',
|
|
text: '箱型4',
|
|
width: 60
|
|
},
|
|
{
|
|
sortable: true,
|
|
id: '',
|
|
dataIndex: 'CNTR5',
|
|
text: '箱型5',
|
|
width: 60
|
|
},
|
|
{
|
|
sortable: true,
|
|
id: '',
|
|
dataIndex: 'CNTR6',
|
|
text: '箱型6',
|
|
width: 60
|
|
},
|
|
{
|
|
sortable: true,
|
|
id: '',
|
|
dataIndex: 'CNTR7',
|
|
text: '箱型7',
|
|
width: 60
|
|
},
|
|
{
|
|
sortable: true,
|
|
id: '',
|
|
dataIndex: 'CNTR8',
|
|
text: '箱型8',
|
|
width: 60
|
|
},
|
|
{
|
|
sortable: true,
|
|
id: '',
|
|
dataIndex: 'CNTR9',
|
|
text: '箱型9',
|
|
width: 60
|
|
},
|
|
{
|
|
sortable: true,
|
|
id: '',
|
|
dataIndex: 'CNTR10',
|
|
text: '箱型10',
|
|
width: 60
|
|
},
|
|
{
|
|
sortable: true,
|
|
id: '',
|
|
dataIndex: 'OTCNTR',
|
|
text: '其他箱型',
|
|
width: 60
|
|
}, {
|
|
sortable: true,
|
|
dataIndex: 'TEU',
|
|
text: 'TEU',
|
|
summaryType: 'sum',
|
|
// summaryRenderer: Ext.util.Format.numberRenderer('00.00'),
|
|
width: 80
|
|
}, {
|
|
sortable: true,
|
|
dataIndex: 'KGS',
|
|
text: 'KGS',
|
|
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',
|
|
summaryType: 'sum',
|
|
summaryRenderer: function (value, cellmeta, record, rowIndex, columnIndex, store) {
|
|
value = usMoney(value, 2, '', true);
|
|
return value;
|
|
},
|
|
width: 80
|
|
}
|
|
|
|
];
|
|
|
|
this.girdcolumssale = this.initgirdcolumssale;
|
|
var showSummary = true;
|
|
this.gridListSale = new Ext.grid.GridPanel({
|
|
store: this.storeSaleList,
|
|
enableHdMenu: false,
|
|
region: 'center',
|
|
loadMask: { msg: "数据加载中,请稍等..." },
|
|
trackMouseOver: true,
|
|
disableSelection: false,
|
|
viewConfig: {
|
|
enableTextSelection: true, //允许复制数据
|
|
autoFill: true
|
|
},
|
|
features: [{
|
|
id: 'group',
|
|
ftype: 'groupingsummary',
|
|
groupHeaderTpl: '{name}',
|
|
hideGroupedHeader: true,
|
|
enableGroupingMenu: true
|
|
}],
|
|
columns: this.girdcolumssale,
|
|
// paging bar on the bottom
|
|
bbar: Ext.create('Ext.PagingToolbar', {
|
|
store: this.storeSaleList,
|
|
displayInfo: true,
|
|
displayMsg: '当前显示 {0} - {1}条记录 /共 {2}条记录',
|
|
emptyMsg: "没有数据"
|
|
})
|
|
});
|
|
|
|
this.girdcolumssale = DsTruck.GetGridPanel(USERID, this.formname + 'sale', this.girdcolumssale, 1);
|
|
// this.gridListSale.reconfigure(this.storeSaleList, this.girdcolumssale);
|
|
|
|
|
|
this.gridListSale.addListener('sortchange', function (ct, column, direction, eOpts) {
|
|
this.salelistsortfield = column.dataIndex;
|
|
this.salelistsortdire = direction;
|
|
}, this);
|
|
|
|
|
|
this.storeCustList = Ext.create('Ext.data.Store', {
|
|
pageSize: this.PageSize,
|
|
fields: [
|
|
{ name: 'CUSTOMERNAME', type: 'string' },
|
|
{ name: 'CUSTFULLNAME', type: 'string' },
|
|
{ name: 'BSTYPE', type: 'string' },
|
|
{ name: 'BLCOUNT', type: 'number' },
|
|
{ name: 'NETWEIGHT', type: 'number' },
|
|
{ name: 'KGS', type: 'number' },
|
|
{ name: 'TEU', type: 'number' },
|
|
{ name: 'CNTR1', type: 'number' },
|
|
{ name: 'CNTR2', type: 'number' },
|
|
{ name: 'CNTR3', type: 'number' },
|
|
{ name: 'CNTR4', type: 'number' },
|
|
{ name: 'CNTR5', type: 'number' },
|
|
{ name: 'CNTR6', type: 'number' },
|
|
{ name: 'CNTR7', type: 'number' },
|
|
{ name: 'CNTR8', type: 'number' },
|
|
{ name: 'CNTR9', type: 'number' },
|
|
{ name: 'CNTR10', type: 'number' },
|
|
{ name: 'OTCNTR', 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: 'RMBPROFIT', type: 'number' },
|
|
{ name: 'USDPROFIT', type: 'number' },
|
|
{ name: 'OTPROFIT', type: 'number' },
|
|
{ name: 'TTLPROFIT', type: 'number' },
|
|
{ name: 'NOTAXRMBDR', type: 'number' },
|
|
{ name: 'NOTAXRMBCR', type: 'number' },
|
|
{ name: 'NOTAXUSDDR', type: 'number' },
|
|
{ name: 'NOTAXUSDCR', type: 'number' },
|
|
{ name: 'NOTAXOTDR', type: 'number' },
|
|
{ name: 'NOTAXOTCR', type: 'number' },
|
|
{ name: 'NOTAXTTLDR', type: 'number' },
|
|
{ name: 'NOTAXTTLCR', type: 'number' },
|
|
{ name: 'NOTAXRMBPROFIT', type: 'number' },
|
|
{ name: 'NOTAXUSDPROFIT', type: 'number' },
|
|
{ name: 'NOTAXOTPROFIT', type: 'number' },
|
|
{ name: 'NOTAXTTLPROFIT', type: 'number' },
|
|
{ name: 'RMBNODR', type: 'number' },
|
|
{ name: 'USDNODR', type: 'number' },
|
|
{ name: 'OTNODR', type: 'number' },
|
|
{ name: 'TTLNODR', type: 'number' },
|
|
{ name: 'RMBNOCR', type: 'number' },
|
|
{ name: 'USDNOCR', type: 'number' },
|
|
{ name: 'OTNOCR', type: 'number' },
|
|
{ name: 'TTLNOCR', type: 'number' },
|
|
{ name: 'STLRMBDR', type: 'number' },
|
|
{ name: 'STLUSDDR', type: 'number' },
|
|
{ name: 'STLOTDR', type: 'number' },
|
|
{ name: 'STLTTLDR', type: 'number' },
|
|
{ name: 'STLRMBCR', type: 'number' },
|
|
{ name: 'STLUSDCR', type: 'number' },
|
|
{ name: 'STLOTCR', type: 'number' },
|
|
{ name: 'STLTTLCR', type: 'number' },
|
|
{ name: 'TTLPROFIT', type: 'number' },
|
|
{ name: 'PROFITRATE', type: 'number' }
|
|
|
|
],
|
|
remoteSort: true,
|
|
proxy: {
|
|
type: 'ajax',
|
|
timeout: 120000,
|
|
url: '/MvcShipping/MsRptOpBsList/CustListData',
|
|
reader: {
|
|
id: '',
|
|
root: 'data',
|
|
totalProperty: 'totalCount'
|
|
}
|
|
}
|
|
});
|
|
|
|
//定义Grid
|
|
|
|
this.initgirdcolumscust = [{
|
|
sortable: true,
|
|
dataIndex: 'CUSTOMERNAME',
|
|
text: '委托单位',
|
|
width: 80
|
|
}, {
|
|
sortable: true,
|
|
dataIndex: 'CUSTFULLNAME',
|
|
text: '委托单位全称',
|
|
width: 120
|
|
}, {
|
|
sortable: true,
|
|
dataIndex: 'BSTYPE',
|
|
text: '运输类型',
|
|
width: 80
|
|
}, {
|
|
sortable: true,
|
|
dataIndex: 'BLCOUNT',
|
|
text: '票数',
|
|
width: 80
|
|
},
|
|
{
|
|
sortable: true,
|
|
id: '',
|
|
dataIndex: 'CNTR1',
|
|
text: '箱型1',
|
|
width: 60
|
|
},
|
|
{
|
|
sortable: true,
|
|
id: '',
|
|
dataIndex: 'CNTR2',
|
|
text: '箱型2',
|
|
width: 60
|
|
},
|
|
{
|
|
sortable: true,
|
|
id: '',
|
|
dataIndex: 'CNTR3',
|
|
text: '箱型3',
|
|
width: 60
|
|
},
|
|
{
|
|
sortable: true,
|
|
id: '',
|
|
dataIndex: 'CNTR4',
|
|
text: '箱型4',
|
|
width: 60
|
|
},
|
|
{
|
|
sortable: true,
|
|
id: '',
|
|
dataIndex: 'CNTR5',
|
|
text: '箱型5',
|
|
width: 60
|
|
},
|
|
{
|
|
sortable: true,
|
|
id: '',
|
|
dataIndex: 'CNTR6',
|
|
text: '箱型6',
|
|
width: 60
|
|
},
|
|
{
|
|
sortable: true,
|
|
id: '',
|
|
dataIndex: 'CNTR7',
|
|
text: '箱型7',
|
|
width: 60
|
|
},
|
|
{
|
|
sortable: true,
|
|
id: '',
|
|
dataIndex: 'CNTR8',
|
|
text: '箱型8',
|
|
width: 60
|
|
},
|
|
{
|
|
sortable: true,
|
|
id: '',
|
|
dataIndex: 'CNTR9',
|
|
text: '箱型9',
|
|
width: 60
|
|
},
|
|
{
|
|
sortable: true,
|
|
id: '',
|
|
dataIndex: 'CNTR10',
|
|
text: '箱型10',
|
|
width: 60
|
|
},
|
|
{
|
|
sortable: true,
|
|
id: '',
|
|
dataIndex: 'OTCNTR',
|
|
text: '其他箱型',
|
|
width: 60
|
|
}, {
|
|
sortable: true,
|
|
dataIndex: 'TEU',
|
|
text: 'TEU',
|
|
width: 80
|
|
}, {
|
|
sortable: true,
|
|
dataIndex: 'KGS',
|
|
text: 'KGS',
|
|
width: 80
|
|
}
|
|
];
|
|
// this.girdcolumscust = this.initgirdcolumscust;
|
|
this.girdcolumscust = DsTruck.GetGridPanel(USERID, this.formname + 'cust', this.initgirdcolumscust, 1);
|
|
|
|
this.gridListCust = new Ext.grid.GridPanel({
|
|
store: this.storeCustList,
|
|
enableHdMenu: false,
|
|
region: 'center',
|
|
loadMask: { msg: "数据加载中,请稍等..." },
|
|
trackMouseOver: true,
|
|
viewConfig: {
|
|
enableTextSelection: true, //允许复制数据
|
|
autoFill: true
|
|
},
|
|
disableSelection: false,
|
|
columns: this.girdcolumscust,
|
|
// paging bar on the bottom
|
|
bbar: Ext.create('Ext.PagingToolbar', {
|
|
store: this.storeCustList,
|
|
displayInfo: true,
|
|
displayMsg: '当前显示 {0} - {1}条记录 /共 {2}条记录',
|
|
emptyMsg: "没有数据"
|
|
})
|
|
});
|
|
// this.gridListCust.reconfigure(this.storeCustList, this.girdcolumscust);
|
|
|
|
this.gridListCust.addListener('sortchange', function (ct, column, direction, eOpts) {
|
|
this.custlistsortfield = column.dataIndex;
|
|
this.custlistsortdire = direction;
|
|
}, this);
|
|
|
|
//#region 船公司
|
|
|
|
this.storeCarrierList = Ext.create('Ext.data.Store', {
|
|
pageSize: this.PageSize,
|
|
fields: [
|
|
{ name: 'CARRIER', type: 'string' },
|
|
{ name: 'BSTYPE', type: 'string' },
|
|
{ name: 'BLCOUNT', type: 'number' },
|
|
{ name: 'NETWEIGHT', type: 'number' },
|
|
{ name: 'KGS', type: 'number' },
|
|
{ name: 'TEU', type: 'number' },
|
|
{ name: 'CNTR1', type: 'number' },
|
|
{ name: 'CNTR2', type: 'number' },
|
|
{ name: 'CNTR3', type: 'number' },
|
|
{ name: 'CNTR4', type: 'number' },
|
|
{ name: 'CNTR5', type: 'number' },
|
|
{ name: 'CNTR6', type: 'number' },
|
|
{ name: 'CNTR7', type: 'number' },
|
|
{ name: 'CNTR8', type: 'number' },
|
|
{ name: 'CNTR9', type: 'number' },
|
|
{ name: 'CNTR10', type: 'number' },
|
|
{ name: 'OTCNTR', type: 'number' }
|
|
|
|
],
|
|
remoteSort: true,
|
|
proxy: {
|
|
type: 'ajax',
|
|
timeout: 120000,
|
|
url: '/MvcShipping/MsRptOpBsList/CarrierListData',
|
|
reader: {
|
|
id: '',
|
|
root: 'data',
|
|
totalProperty: 'totalCount'
|
|
}
|
|
}
|
|
});
|
|
|
|
//定义Grid
|
|
|
|
this.initgirdcolumscarrier = [{
|
|
sortable: true,
|
|
dataIndex: 'CARRIER',
|
|
text: '船公司',
|
|
width: 80
|
|
}, {
|
|
sortable: true,
|
|
dataIndex: 'BSTYPE',
|
|
text: '运输类型',
|
|
width: 80
|
|
}, {
|
|
sortable: true,
|
|
dataIndex: 'BLCOUNT',
|
|
text: '票数',
|
|
width: 80
|
|
},
|
|
{
|
|
sortable: true,
|
|
id: '',
|
|
dataIndex: 'CNTR1',
|
|
text: '箱型1',
|
|
width: 60
|
|
},
|
|
{
|
|
sortable: true,
|
|
id: '',
|
|
dataIndex: 'CNTR2',
|
|
text: '箱型2',
|
|
width: 60
|
|
},
|
|
{
|
|
sortable: true,
|
|
id: '',
|
|
dataIndex: 'CNTR3',
|
|
text: '箱型3',
|
|
width: 60
|
|
},
|
|
{
|
|
sortable: true,
|
|
id: '',
|
|
dataIndex: 'CNTR4',
|
|
text: '箱型4',
|
|
width: 60
|
|
},
|
|
{
|
|
sortable: true,
|
|
id: '',
|
|
dataIndex: 'CNTR5',
|
|
text: '箱型5',
|
|
width: 60
|
|
},
|
|
{
|
|
sortable: true,
|
|
id: '',
|
|
dataIndex: 'CNTR6',
|
|
text: '箱型6',
|
|
width: 60
|
|
},
|
|
{
|
|
sortable: true,
|
|
id: '',
|
|
dataIndex: 'CNTR7',
|
|
text: '箱型7',
|
|
width: 60
|
|
},
|
|
{
|
|
sortable: true,
|
|
id: '',
|
|
dataIndex: 'CNTR8',
|
|
text: '箱型8',
|
|
width: 60
|
|
},
|
|
{
|
|
sortable: true,
|
|
id: '',
|
|
dataIndex: 'CNTR9',
|
|
text: '箱型9',
|
|
width: 60
|
|
},
|
|
{
|
|
sortable: true,
|
|
id: '',
|
|
dataIndex: 'CNTR10',
|
|
text: '箱型10',
|
|
width: 60
|
|
},
|
|
{
|
|
sortable: true,
|
|
id: '',
|
|
dataIndex: 'OTCNTR',
|
|
text: '其他箱型',
|
|
width: 60
|
|
}, {
|
|
sortable: true,
|
|
dataIndex: 'TEU',
|
|
text: 'TEU',
|
|
width: 80
|
|
}, {
|
|
sortable: true,
|
|
dataIndex: 'KGS',
|
|
text: 'KGS',
|
|
width: 80
|
|
}];
|
|
// this.girdcolumscust = this.initgirdcolumscust;
|
|
this.girdcolumscarrier = DsTruck.GetGridPanel(USERID, this.formname + 'carrier', this.initgirdcolumscarrier, 1);
|
|
|
|
this.gridListCarrier = new Ext.grid.GridPanel({
|
|
store: this.storeCarrierList,
|
|
enableHdMenu: false,
|
|
region: 'center',
|
|
loadMask: { msg: "数据加载中,请稍等..." },
|
|
trackMouseOver: true,
|
|
disableSelection: false,
|
|
viewConfig: {
|
|
enableTextSelection: true, //允许复制数据
|
|
autoFill: true
|
|
},
|
|
columns: this.girdcolumscust,
|
|
// paging bar on the bottom
|
|
bbar: Ext.create('Ext.PagingToolbar', {
|
|
store: this.storeCarrierList,
|
|
displayInfo: true,
|
|
displayMsg: '当前显示 {0} - {1}条记录 /共 {2}条记录',
|
|
emptyMsg: "没有数据"
|
|
})
|
|
});
|
|
// this.gridListCust.reconfigure(this.storeCustList, this.girdcolumscust);
|
|
|
|
this.gridListCarrier.addListener('sortchange', function (ct, column, direction, eOpts) {
|
|
this.carrierlistsortfield = column.dataIndex;
|
|
this.carrierlistsortdire = direction;
|
|
}, this);
|
|
|
|
//#endregion
|
|
|
|
|
|
|
|
|
|
this.storeDeptList = Ext.create('Ext.data.Store', {
|
|
pageSize: this.PageSize,
|
|
fields: [
|
|
|
|
{ name: 'SALEDEPT', type: 'string' },
|
|
{ name: 'BLCOUNT', type: 'number' },
|
|
{ name: 'NETWEIGHT', type: 'number' },
|
|
{ name: 'KGS', type: 'number' },
|
|
{ name: 'TEU', type: 'number' },
|
|
{ name: 'CNTR1', type: 'number' },
|
|
{ name: 'CNTR2', type: 'number' },
|
|
{ name: 'CNTR3', type: 'number' },
|
|
{ name: 'CNTR4', type: 'number' },
|
|
{ name: 'CNTR5', type: 'number' },
|
|
{ name: 'CNTR6', type: 'number' },
|
|
{ name: 'CNTR7', type: 'number' },
|
|
{ name: 'CNTR8', type: 'number' },
|
|
{ name: 'CNTR9', type: 'number' },
|
|
{ name: 'CNTR10', type: 'number' },
|
|
{ name: 'OTCNTR', type: 'number' }
|
|
|
|
],
|
|
remoteSort: true,
|
|
proxy: {
|
|
type: 'ajax',
|
|
timeout: 120000,
|
|
url: '/MvcShipping/MsRptOpBsList/DeptListData',
|
|
reader: {
|
|
id: '',
|
|
root: 'data',
|
|
totalProperty: 'totalCount'
|
|
}
|
|
}
|
|
});
|
|
|
|
//定义Grid
|
|
this.initgirdcolumsdept = [{
|
|
sortable: true,
|
|
dataIndex: 'SALEDEPT',
|
|
text: '部门',
|
|
width: 80
|
|
}, {
|
|
sortable: true,
|
|
dataIndex: 'BLCOUNT',
|
|
text: '票数',
|
|
summaryType: 'sum',
|
|
// summaryRenderer: Ext.util.Format.numberRenderer('00.00'),
|
|
width: 80
|
|
},
|
|
{
|
|
sortable: true,
|
|
id: '',
|
|
dataIndex: 'CNTR1',
|
|
text: '箱型1',
|
|
width: 60
|
|
},
|
|
{
|
|
sortable: true,
|
|
id: '',
|
|
dataIndex: 'CNTR2',
|
|
text: '箱型2',
|
|
width: 60
|
|
},
|
|
{
|
|
sortable: true,
|
|
id: '',
|
|
dataIndex: 'CNTR3',
|
|
text: '箱型3',
|
|
width: 60
|
|
},
|
|
{
|
|
sortable: true,
|
|
id: '',
|
|
dataIndex: 'CNTR4',
|
|
text: '箱型4',
|
|
width: 60
|
|
},
|
|
{
|
|
sortable: true,
|
|
id: '',
|
|
dataIndex: 'CNTR5',
|
|
text: '箱型5',
|
|
width: 60
|
|
},
|
|
{
|
|
sortable: true,
|
|
id: '',
|
|
dataIndex: 'CNTR6',
|
|
text: '箱型6',
|
|
width: 60
|
|
},
|
|
{
|
|
sortable: true,
|
|
id: '',
|
|
dataIndex: 'CNTR7',
|
|
text: '箱型7',
|
|
width: 60
|
|
},
|
|
{
|
|
sortable: true,
|
|
id: '',
|
|
dataIndex: 'CNTR8',
|
|
text: '箱型8',
|
|
width: 60
|
|
},
|
|
{
|
|
sortable: true,
|
|
id: '',
|
|
dataIndex: 'CNTR9',
|
|
text: '箱型9',
|
|
width: 60
|
|
},
|
|
{
|
|
sortable: true,
|
|
id: '',
|
|
dataIndex: 'CNTR10',
|
|
text: '箱型10',
|
|
width: 60
|
|
},
|
|
{
|
|
sortable: true,
|
|
id: '',
|
|
dataIndex: 'OTCNTR',
|
|
text: '其他箱型',
|
|
width: 60
|
|
}, {
|
|
sortable: true,
|
|
dataIndex: 'TEU',
|
|
text: 'TEU',
|
|
summaryType: 'sum',
|
|
// summaryRenderer: Ext.util.Format.numberRenderer('00.00'),
|
|
width: 80
|
|
}, {
|
|
sortable: true,
|
|
dataIndex: 'KGS',
|
|
text: 'KGS',
|
|
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',
|
|
summaryType: 'sum',
|
|
summaryRenderer: function (value, cellmeta, record, rowIndex, columnIndex, store) {
|
|
value = usMoney(value, 2, '', true);
|
|
return value;
|
|
},
|
|
width: 80
|
|
}
|
|
];
|
|
|
|
this.girdcolumsdept = this.initgirdcolumsdept;
|
|
var showSummary = true;
|
|
this.gridListDept = new Ext.grid.GridPanel({
|
|
store: this.storeDeptList,
|
|
enableHdMenu: false,
|
|
region: 'center',
|
|
loadMask: { msg: "数据加载中,请稍等..." },
|
|
trackMouseOver: true,
|
|
disableSelection: false,
|
|
viewConfig: {
|
|
enableTextSelection: true, //允许复制数据
|
|
autoFill: true
|
|
},
|
|
features: [{
|
|
id: 'group',
|
|
ftype: 'groupingsummary',
|
|
groupHeaderTpl: '{name}',
|
|
hideGroupedHeader: true,
|
|
enableGroupingMenu: true
|
|
}],
|
|
columns: this.girdcolumssale,
|
|
// paging bar on the bottom
|
|
bbar: Ext.create('Ext.PagingToolbar', {
|
|
store: this.storeDeptList,
|
|
displayInfo: true,
|
|
displayMsg: '当前显示 {0} - {1}条记录 /共 {2}条记录',
|
|
emptyMsg: "没有数据"
|
|
})
|
|
});
|
|
|
|
this.girdcolumsdept = DsTruck.GetGridPanel(USERID, this.formname + 'dept', this.girdcolumsdept, 1);
|
|
// this.gridListDept.reconfigure(this.storeDeptList, this.girdcolumsdept);
|
|
|
|
|
|
this.gridListDept.addListener('sortchange', function (ct, column, direction, eOpts) {
|
|
this.deptlistsortfield = column.dataIndex;
|
|
this.deptlistsortdire = direction;
|
|
}, this);
|
|
|
|
|
|
|
|
|
|
this.storeOpList = Ext.create('Ext.data.Store', {
|
|
pageSize: this.PageSize,
|
|
fields: [
|
|
{ name: 'OP', type: 'string' },
|
|
{ name: 'BSTYPE', type: 'string' },
|
|
{ name: 'BLCOUNT', type: 'number' },
|
|
{ name: 'NETWEIGHT', type: 'number' },
|
|
{ name: 'KGS', type: 'number' },
|
|
{ name: 'TEU', type: 'number' },
|
|
{ name: 'CNTR1', type: 'number' },
|
|
{ name: 'CNTR2', type: 'number' },
|
|
{ name: 'CNTR3', type: 'number' },
|
|
{ name: 'CNTR4', type: 'number' },
|
|
{ name: 'CNTR5', type: 'number' },
|
|
{ name: 'CNTR6', type: 'number' },
|
|
{ name: 'CNTR7', type: 'number' },
|
|
{ name: 'CNTR8', type: 'number' },
|
|
{ name: 'CNTR9', type: 'number' },
|
|
{ name: 'CNTR10', type: 'number' },
|
|
{ name: 'OTCNTR', type: 'number' }
|
|
|
|
],
|
|
remoteSort: true,
|
|
proxy: {
|
|
type: 'ajax',
|
|
timeout: 120000,
|
|
url: '/MvcShipping/MsRptOpBsList/OpListData',
|
|
reader: {
|
|
id: '',
|
|
root: 'data',
|
|
totalProperty: 'totalCount'
|
|
}
|
|
},
|
|
groupField: 'OP'
|
|
});
|
|
|
|
//定义Grid
|
|
|
|
this.initgirdcolumsop = [{
|
|
sortable: true,
|
|
dataIndex: 'OP',
|
|
text: '操作员',
|
|
width: 80
|
|
}, {
|
|
sortable: true,
|
|
dataIndex: 'BSTYPE',
|
|
text: '运输类型',
|
|
width: 70
|
|
}, {
|
|
sortable: true,
|
|
dataIndex: 'BLCOUNT',
|
|
text: '票数',
|
|
summaryType: 'sum',
|
|
width: 80
|
|
}, {
|
|
sortable: true,
|
|
dataIndex: 'TEU',
|
|
text: 'TEU',
|
|
summaryType: 'sum',
|
|
width: 80
|
|
},
|
|
{
|
|
sortable: true,
|
|
id: '',
|
|
dataIndex: 'CNTR1',
|
|
text: '箱型1',
|
|
width: 60
|
|
},
|
|
{
|
|
sortable: true,
|
|
id: '',
|
|
dataIndex: 'CNTR2',
|
|
text: '箱型2',
|
|
width: 60
|
|
},
|
|
{
|
|
sortable: true,
|
|
id: '',
|
|
dataIndex: 'CNTR3',
|
|
text: '箱型3',
|
|
width: 60
|
|
},
|
|
{
|
|
sortable: true,
|
|
id: '',
|
|
dataIndex: 'CNTR4',
|
|
text: '箱型4',
|
|
width: 60
|
|
},
|
|
{
|
|
sortable: true,
|
|
id: '',
|
|
dataIndex: 'CNTR5',
|
|
text: '箱型5',
|
|
width: 60
|
|
},
|
|
{
|
|
sortable: true,
|
|
id: '',
|
|
dataIndex: 'CNTR6',
|
|
text: '箱型6',
|
|
width: 60
|
|
},
|
|
{
|
|
sortable: true,
|
|
id: '',
|
|
dataIndex: 'CNTR7',
|
|
text: '箱型7',
|
|
width: 60
|
|
},
|
|
{
|
|
sortable: true,
|
|
id: '',
|
|
dataIndex: 'CNTR8',
|
|
text: '箱型8',
|
|
width: 60
|
|
},
|
|
{
|
|
sortable: true,
|
|
id: '',
|
|
dataIndex: 'CNTR9',
|
|
text: '箱型9',
|
|
width: 60
|
|
},
|
|
{
|
|
sortable: true,
|
|
id: '',
|
|
dataIndex: 'CNTR10',
|
|
text: '箱型10',
|
|
width: 60
|
|
},
|
|
{
|
|
sortable: true,
|
|
id: '',
|
|
dataIndex: 'OTCNTR',
|
|
text: '其他箱型',
|
|
width: 60
|
|
}, {
|
|
sortable: true,
|
|
dataIndex: 'KGS',
|
|
text: 'KGS',
|
|
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',
|
|
summaryType: 'sum',
|
|
summaryRenderer: function (value, cellmeta, record, rowIndex, columnIndex, store) {
|
|
value = usMoney(value, 2, '', true);
|
|
return value;
|
|
},
|
|
width: 80
|
|
}];
|
|
|
|
|
|
this.girdcolumsop = DsTruck.GetGridPanel(USERID, this.formname + 'op', this.initgirdcolumsop, 1);
|
|
|
|
this.gridListOp = new Ext.grid.GridPanel({
|
|
store: this.storeOpList,
|
|
enableHdMenu: false,
|
|
region: 'center',
|
|
loadMask: { msg: "数据加载中,请稍等..." },
|
|
trackMouseOver: true,
|
|
disableSelection: false,
|
|
viewConfig: {
|
|
enableTextSelection: true, //允许复制数据
|
|
autoFill: true
|
|
},
|
|
features: [{
|
|
id: 'group',
|
|
ftype: 'groupingsummary',
|
|
groupHeaderTpl: '{name}',
|
|
hideGroupedHeader: true,
|
|
enableGroupingMenu: true
|
|
}],
|
|
columns: this.girdcolumsop,
|
|
// paging bar on the bottom
|
|
bbar: Ext.create('Ext.PagingToolbar', {
|
|
store: this.storeOpList,
|
|
displayInfo: true,
|
|
displayMsg: '当前显示 {0} - {1}条记录 /共 {2}条记录',
|
|
emptyMsg: "没有数据"
|
|
})
|
|
});
|
|
|
|
this.gridListOp.addListener('sortchange', function (ct, column, direction, eOpts) {
|
|
this.oplistsortfield = column.dataIndex;
|
|
this.oplistsortdire = direction;
|
|
}, this);
|
|
|
|
|
|
this.storeBsSourceList = Ext.create('Ext.data.Store', {
|
|
pageSize: this.PageSize,
|
|
fields: [
|
|
{ name: 'BSSOURCE', type: 'string' },
|
|
{ name: 'BLCOUNT', type: 'number' },
|
|
{ name: 'NETWEIGHT', type: 'number' },
|
|
{ name: 'KGS', type: 'number' },
|
|
{ name: 'TEU', type: 'number' },
|
|
{ name: 'CNTR1', type: 'number' },
|
|
{ name: 'CNTR2', type: 'number' },
|
|
{ name: 'CNTR3', type: 'number' },
|
|
{ name: 'CNTR4', type: 'number' },
|
|
{ name: 'CNTR5', type: 'number' },
|
|
{ name: 'CNTR6', type: 'number' },
|
|
{ name: 'CNTR7', type: 'number' },
|
|
{ name: 'CNTR8', type: 'number' },
|
|
{ name: 'CNTR9', type: 'number' },
|
|
{ name: 'CNTR10', type: 'number' },
|
|
{ name: 'OTCNTR', type: 'number' }
|
|
|
|
],
|
|
remoteSort: true,
|
|
proxy: {
|
|
type: 'ajax',
|
|
timeout: 120000,
|
|
url: '/MvcShipping/MsRptOpBsList/BsSourceListData',
|
|
reader: {
|
|
id: '',
|
|
root: 'data',
|
|
totalProperty: 'totalCount'
|
|
}
|
|
}
|
|
// ,
|
|
// groupField: 'BSSOURCE'
|
|
});
|
|
|
|
//定义Grid
|
|
this.initgirdcolumsbssource = [{
|
|
sortable: true,
|
|
dataIndex: 'BSSOURCE',
|
|
text: '业务来源',
|
|
width: 80
|
|
}, {
|
|
sortable: true,
|
|
dataIndex: 'BLCOUNT',
|
|
text: '票数',
|
|
summaryType: 'sum',
|
|
width: 80
|
|
},
|
|
{
|
|
sortable: true,
|
|
id: '',
|
|
dataIndex: 'CNTR1',
|
|
text: '箱型1',
|
|
width: 60
|
|
},
|
|
{
|
|
sortable: true,
|
|
id: '',
|
|
dataIndex: 'CNTR2',
|
|
text: '箱型2',
|
|
width: 60
|
|
},
|
|
{
|
|
sortable: true,
|
|
id: '',
|
|
dataIndex: 'CNTR3',
|
|
text: '箱型3',
|
|
width: 60
|
|
},
|
|
{
|
|
sortable: true,
|
|
id: '',
|
|
dataIndex: 'CNTR4',
|
|
text: '箱型4',
|
|
width: 60
|
|
},
|
|
{
|
|
sortable: true,
|
|
id: '',
|
|
dataIndex: 'CNTR5',
|
|
text: '箱型5',
|
|
width: 60
|
|
},
|
|
{
|
|
sortable: true,
|
|
id: '',
|
|
dataIndex: 'CNTR6',
|
|
text: '箱型6',
|
|
width: 60
|
|
},
|
|
{
|
|
sortable: true,
|
|
id: '',
|
|
dataIndex: 'CNTR7',
|
|
text: '箱型7',
|
|
width: 60
|
|
},
|
|
{
|
|
sortable: true,
|
|
id: '',
|
|
dataIndex: 'CNTR8',
|
|
text: '箱型8',
|
|
width: 60
|
|
},
|
|
{
|
|
sortable: true,
|
|
id: '',
|
|
dataIndex: 'CNTR9',
|
|
text: '箱型9',
|
|
width: 60
|
|
},
|
|
{
|
|
sortable: true,
|
|
id: '',
|
|
dataIndex: 'CNTR10',
|
|
text: '箱型10',
|
|
width: 60
|
|
},
|
|
{
|
|
sortable: true,
|
|
id: '',
|
|
dataIndex: 'OTCNTR',
|
|
header: '其他箱型',
|
|
width: 60
|
|
}, {
|
|
sortable: true,
|
|
dataIndex: 'TEU',
|
|
text: 'TEU',
|
|
summaryType: 'sum',
|
|
width: 80
|
|
}, {
|
|
sortable: true,
|
|
dataIndex: 'KGS',
|
|
text: 'KGS',
|
|
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',
|
|
summaryType: 'sum',
|
|
summaryRenderer: function (value, cellmeta, record, rowIndex, columnIndex, store) {
|
|
value = usMoney(value, 2, '', true);
|
|
return value;
|
|
},
|
|
width: 80
|
|
}];
|
|
|
|
|
|
// this.girdcolumsbssource=this.initgirdcolumsbssource;
|
|
this.girdcolumsbssource = DsTruck.GetGridPanel(USERID, this.formname + 'bssource', this.initgirdcolumsbssource, 1);
|
|
|
|
this.gridListBsSource = new Ext.grid.GridPanel({
|
|
store: this.storeBsSourceList,
|
|
enableHdMenu: false,
|
|
region: 'center',
|
|
loadMask: { msg: "数据加载中,请稍等..." },
|
|
trackMouseOver: true,
|
|
disableSelection: false,
|
|
viewConfig: {
|
|
enableTextSelection: true, //允许复制数据
|
|
autoFill: true
|
|
},
|
|
// features: [{
|
|
// id: 'group',
|
|
// ftype: 'groupingsummary',
|
|
// groupHeaderTpl: '{name}',
|
|
// hideGroupedHeader: true,
|
|
// enableGroupingMenu: true
|
|
// }],
|
|
columns: this.girdcolumsbssource,
|
|
// paging bar on the bottom
|
|
bbar: Ext.create('Ext.PagingToolbar', {
|
|
store: this.storeBsSourceList,
|
|
displayInfo: true,
|
|
displayMsg: '当前显示 {0} - {1}条记录 /共 {2}条记录',
|
|
emptyMsg: "没有数据"
|
|
})
|
|
});
|
|
|
|
// this.gridListBsSource.reconfigure(this.storeBsSourceList, this.girdcolumsbssource);
|
|
|
|
|
|
this.gridListBsSource.addListener('sortchange', function (ct, column, direction, eOpts) {
|
|
this.bssourcelistsortfield = column.dataIndex;
|
|
this.bssourcelistsortdire = direction;
|
|
}, this);
|
|
|
|
this.storeBsSourceDetailList = Ext.create('Ext.data.Store', {
|
|
pageSize: this.PageSize,
|
|
fields: [
|
|
{ name: 'BSSOURCE', type: 'string' },
|
|
{ name: 'BSSOURCEDETAIL', type: 'string' },
|
|
{ name: 'BLCOUNT', type: 'number' },
|
|
{ name: 'NETWEIGHT', type: 'number' },
|
|
{ name: 'KGS', type: 'number' },
|
|
{ name: 'TEU', type: 'number' },
|
|
{ name: 'CNTR1', type: 'number' },
|
|
{ name: 'CNTR2', type: 'number' },
|
|
{ name: 'CNTR3', type: 'number' },
|
|
{ name: 'CNTR4', type: 'number' },
|
|
{ name: 'CNTR5', type: 'number' },
|
|
{ name: 'CNTR6', type: 'number' },
|
|
{ name: 'CNTR7', type: 'number' },
|
|
{ name: 'CNTR8', type: 'number' },
|
|
{ name: 'CNTR9', type: 'number' },
|
|
{ name: 'CNTR10', type: 'number' },
|
|
{ name: 'OTCNTR', type: 'number' }
|
|
|
|
],
|
|
remoteSort: true,
|
|
proxy: {
|
|
type: 'ajax',
|
|
timeout: 120000,
|
|
url: '/MvcShipping/MsRptOpBsList/BsSourceDetailListData',
|
|
reader: {
|
|
id: '',
|
|
root: 'data',
|
|
totalProperty: 'totalCount'
|
|
}
|
|
}
|
|
// ,
|
|
// groupField: 'BSSOURCEDETAIL'
|
|
});
|
|
|
|
//定义Grid
|
|
|
|
this.initgirdcolumsbssourcedetail = [{
|
|
sortable: true,
|
|
dataIndex: 'BSSOURCE',
|
|
text: '业务来源',
|
|
width: 80
|
|
}, {
|
|
sortable: true,
|
|
dataIndex: 'BSSOURCEDETAIL',
|
|
text: '业务来源明细',
|
|
width: 80
|
|
}, {
|
|
sortable: true,
|
|
dataIndex: 'BLCOUNT',
|
|
text: '票数',
|
|
summaryType: 'sum',
|
|
width: 80
|
|
},
|
|
{
|
|
sortable: true,
|
|
id: '',
|
|
dataIndex: 'CNTR1',
|
|
text: '箱型1',
|
|
width: 60
|
|
},
|
|
{
|
|
sortable: true,
|
|
id: '',
|
|
dataIndex: 'CNTR2',
|
|
text: '箱型2',
|
|
width: 60
|
|
},
|
|
{
|
|
sortable: true,
|
|
id: '',
|
|
dataIndex: 'CNTR3',
|
|
text: '箱型3',
|
|
width: 60
|
|
},
|
|
{
|
|
sortable: true,
|
|
id: '',
|
|
dataIndex: 'CNTR4',
|
|
text: '箱型4',
|
|
width: 60
|
|
},
|
|
{
|
|
sortable: true,
|
|
id: '',
|
|
dataIndex: 'CNTR5',
|
|
text: '箱型5',
|
|
width: 60
|
|
},
|
|
{
|
|
sortable: true,
|
|
id: '',
|
|
dataIndex: 'CNTR6',
|
|
text: '箱型6',
|
|
width: 60
|
|
},
|
|
{
|
|
sortable: true,
|
|
id: '',
|
|
dataIndex: 'CNTR7',
|
|
text: '箱型7',
|
|
width: 60
|
|
},
|
|
{
|
|
sortable: true,
|
|
id: '',
|
|
dataIndex: 'CNTR8',
|
|
text: '箱型8',
|
|
width: 60
|
|
},
|
|
{
|
|
sortable: true,
|
|
id: '',
|
|
dataIndex: 'CNTR9',
|
|
text: '箱型9',
|
|
width: 60
|
|
},
|
|
{
|
|
sortable: true,
|
|
id: '',
|
|
dataIndex: 'CNTR10',
|
|
text: '箱型10',
|
|
width: 60
|
|
},
|
|
{
|
|
sortable: true,
|
|
id: '',
|
|
dataIndex: 'OTCNTR',
|
|
text: '其他箱型',
|
|
width: 60
|
|
}, {
|
|
sortable: true,
|
|
dataIndex: 'TEU',
|
|
text: 'TEU',
|
|
summaryType: 'sum',
|
|
width: 80
|
|
}, {
|
|
sortable: true,
|
|
dataIndex: 'KGS',
|
|
text: 'KGS',
|
|
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',
|
|
summaryType: 'sum',
|
|
summaryRenderer: function (value, cellmeta, record, rowIndex, columnIndex, store) {
|
|
value = usMoney(value, 2, '', true);
|
|
return value;
|
|
},
|
|
width: 80
|
|
}];
|
|
|
|
this.girdcolumsbssourcedetail = this.initgirdcolumsbssourcedetail;
|
|
|
|
this.gridListBsSourceDetail = new Ext.grid.GridPanel({
|
|
store: this.storeBsSourceDetailList,
|
|
enableHdMenu: false,
|
|
region: 'center',
|
|
loadMask: { msg: "数据加载中,请稍等..." },
|
|
trackMouseOver: true,
|
|
disableSelection: false,
|
|
viewConfig: {
|
|
enableTextSelection: true, //允许复制数据
|
|
autoFill: true
|
|
},
|
|
// features: [{
|
|
// id: 'group',
|
|
// ftype: 'groupingsummary',
|
|
// groupHeaderTpl: '{name}',
|
|
// hideGroupedHeader: true,
|
|
// enableGroupingMenu: true
|
|
// }],
|
|
columns: this.girdcolumsbssourcedetail,
|
|
// paging bar on the bottom
|
|
bbar: Ext.create('Ext.PagingToolbar', {
|
|
store: this.storeBsSourceDetailList,
|
|
displayInfo: true,
|
|
displayMsg: '当前显示 {0} - {1}条记录 /共 {2}条记录',
|
|
emptyMsg: "没有数据"
|
|
})
|
|
});
|
|
this.girdcolumsbssourcedetail = DsTruck.GetGridPanel(USERID, this.formname + 'bssourcedetail', this.girdcolumsbssourcedetail, 1);
|
|
// this.gridListBsSourceDetail.reconfigure(this.storeBsSourceDetailList, this.girdcolumsbssourcedetail);
|
|
|
|
|
|
this.gridListBsSourceDetail.addListener('sortchange', function (ct, column, direction, eOpts) {
|
|
this.bssourcedetaillistsortfield = column.dataIndex;
|
|
this.bssourcedetaillistsortdire = direction;
|
|
}, this);
|
|
|
|
//#region 航线
|
|
|
|
this.storeLaneList = Ext.create('Ext.data.Store', {
|
|
pageSize: this.PageSize,
|
|
fields: [
|
|
{ name: 'LANE', type: 'string' },
|
|
{ name: 'BLCOUNT', type: 'number' },
|
|
{ name: 'NETWEIGHT', type: 'number' },
|
|
{ name: 'KGS', type: 'number' },
|
|
{ name: 'TEU', type: 'number' },
|
|
{ name: 'CNTR1', type: 'number' },
|
|
{ name: 'CNTR2', type: 'number' },
|
|
{ name: 'CNTR3', type: 'number' },
|
|
{ name: 'CNTR4', type: 'number' },
|
|
{ name: 'CNTR5', type: 'number' },
|
|
{ name: 'CNTR6', type: 'number' },
|
|
{ name: 'CNTR7', type: 'number' },
|
|
{ name: 'CNTR8', type: 'number' },
|
|
{ name: 'CNTR9', type: 'number' },
|
|
{ name: 'CNTR10', type: 'number' },
|
|
{ name: 'OTCNTR', type: 'number' }
|
|
|
|
],
|
|
remoteSort: true,
|
|
proxy: {
|
|
type: 'ajax',
|
|
timeout: 120000,
|
|
url: '/MvcShipping/MsRptOpBsList/LaneListData',
|
|
reader: {
|
|
id: '',
|
|
root: 'data',
|
|
totalProperty: 'totalCount'
|
|
}
|
|
}
|
|
// ,
|
|
// groupField: 'BSSOURCEDETAIL'
|
|
});
|
|
|
|
//定义Grid
|
|
|
|
this.initgirdcolumslane = [{
|
|
sortable: true,
|
|
dataIndex: 'LANE',
|
|
text: '航线',
|
|
width: 80
|
|
}, {
|
|
sortable: true,
|
|
dataIndex: 'BLCOUNT',
|
|
text: '票数',
|
|
summaryType: 'sum',
|
|
width: 80
|
|
},
|
|
{
|
|
sortable: true,
|
|
id: '',
|
|
dataIndex: 'CNTR1',
|
|
text: '箱型1',
|
|
width: 60
|
|
},
|
|
{
|
|
sortable: true,
|
|
id: '',
|
|
dataIndex: 'CNTR2',
|
|
text: '箱型2',
|
|
width: 60
|
|
},
|
|
{
|
|
sortable: true,
|
|
id: '',
|
|
dataIndex: 'CNTR3',
|
|
text: '箱型3',
|
|
width: 60
|
|
},
|
|
{
|
|
sortable: true,
|
|
id: '',
|
|
dataIndex: 'CNTR4',
|
|
text: '箱型4',
|
|
width: 60
|
|
},
|
|
{
|
|
sortable: true,
|
|
id: '',
|
|
dataIndex: 'CNTR5',
|
|
text: '箱型5',
|
|
width: 60
|
|
},
|
|
{
|
|
sortable: true,
|
|
id: '',
|
|
dataIndex: 'CNTR6',
|
|
text: '箱型6',
|
|
width: 60
|
|
},
|
|
{
|
|
sortable: true,
|
|
id: '',
|
|
dataIndex: 'CNTR7',
|
|
text: '箱型7',
|
|
width: 60
|
|
},
|
|
{
|
|
sortable: true,
|
|
id: '',
|
|
dataIndex: 'CNTR8',
|
|
text: '箱型8',
|
|
width: 60
|
|
},
|
|
{
|
|
sortable: true,
|
|
id: '',
|
|
dataIndex: 'CNTR9',
|
|
text: '箱型9',
|
|
width: 60
|
|
},
|
|
{
|
|
sortable: true,
|
|
id: '',
|
|
dataIndex: 'CNTR10',
|
|
text: '箱型10',
|
|
width: 60
|
|
},
|
|
{
|
|
sortable: true,
|
|
id: '',
|
|
dataIndex: 'OTCNTR',
|
|
text: '其他箱型',
|
|
width: 60
|
|
}, {
|
|
sortable: true,
|
|
dataIndex: 'TEU',
|
|
text: 'TEU',
|
|
summaryType: 'sum',
|
|
width: 80
|
|
}, {
|
|
sortable: true,
|
|
dataIndex: 'KGS',
|
|
text: 'KGS',
|
|
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',
|
|
summaryType: 'sum',
|
|
summaryRenderer: function (value, cellmeta, record, rowIndex, columnIndex, store) {
|
|
value = usMoney(value, 2, '', true);
|
|
return value;
|
|
},
|
|
width: 80
|
|
}];
|
|
|
|
this.girdcolumslane = this.initgirdcolumslane;
|
|
|
|
this.gridListLane = new Ext.grid.GridPanel({
|
|
store: this.storeLaneList,
|
|
enableHdMenu: false,
|
|
region: 'center',
|
|
loadMask: { msg: "数据加载中,请稍等..." },
|
|
trackMouseOver: true,
|
|
disableSelection: false,
|
|
viewConfig: {
|
|
enableTextSelection: true, //允许复制数据
|
|
autoFill: true
|
|
},
|
|
// features: [{
|
|
// id: 'group',
|
|
// ftype: 'groupingsummary',
|
|
// groupHeaderTpl: '{name}',
|
|
// hideGroupedHeader: true,
|
|
// enableGroupingMenu: true
|
|
// }],
|
|
columns: this.girdcolumslane,
|
|
// paging bar on the bottom
|
|
bbar: Ext.create('Ext.PagingToolbar', {
|
|
store: this.storeLaneList,
|
|
displayInfo: true,
|
|
displayMsg: '当前显示 {0} - {1}条记录 /共 {2}条记录',
|
|
emptyMsg: "没有数据"
|
|
})
|
|
});
|
|
this.girdcolumslane = DsTruck.GetGridPanel(USERID, this.formname + 'lane', this.girdcolumslane, 1);
|
|
// this.gridListBsSourceDetail.reconfigure(this.storeBsSourceDetailList, this.girdcolumsbssourcedetail);
|
|
|
|
|
|
this.gridListLane.addListener('sortchange', function (ct, column, direction, eOpts) {
|
|
this.lanelistsortfield = column.dataIndex;
|
|
this.lanelistsortdire = direction;
|
|
}, this);
|
|
|
|
//#endregion
|
|
|
|
//#region 目的港
|
|
|
|
this.storeDestinationList = Ext.create('Ext.data.Store', {
|
|
pageSize: this.PageSize,
|
|
fields: [
|
|
{ name: 'DESTINATION', type: 'string' },
|
|
{ name: 'BLCOUNT', type: 'number' },
|
|
{ name: 'NETWEIGHT', type: 'number' },
|
|
{ name: 'KGS', type: 'number' },
|
|
{ name: 'TEU', type: 'number' },
|
|
{ name: 'CNTR1', type: 'number' },
|
|
{ name: 'CNTR2', type: 'number' },
|
|
{ name: 'CNTR3', type: 'number' },
|
|
{ name: 'CNTR4', type: 'number' },
|
|
{ name: 'CNTR5', type: 'number' },
|
|
{ name: 'CNTR6', type: 'number' },
|
|
{ name: 'CNTR7', type: 'number' },
|
|
{ name: 'CNTR8', type: 'number' },
|
|
{ name: 'CNTR9', type: 'number' },
|
|
{ name: 'CNTR10', type: 'number' },
|
|
{ name: 'OTCNTR', type: 'number' }
|
|
|
|
],
|
|
remoteSort: true,
|
|
proxy: {
|
|
type: 'ajax',
|
|
timeout: 120000,
|
|
url: '/MvcShipping/MsRptOpBsList/DestinationListData',
|
|
reader: {
|
|
id: '',
|
|
root: 'data',
|
|
totalProperty: 'totalCount'
|
|
}
|
|
}
|
|
// ,
|
|
// groupField: 'BSSOURCEDETAIL'
|
|
});
|
|
|
|
//定义Grid
|
|
|
|
this.initgirdcolumsdestination = [{
|
|
sortable: true,
|
|
dataIndex: 'DESTINATION',
|
|
text: '目的港',
|
|
width: 80
|
|
}, {
|
|
sortable: true,
|
|
dataIndex: 'BLCOUNT',
|
|
text: '票数',
|
|
summaryType: 'sum',
|
|
width: 80
|
|
},
|
|
{
|
|
sortable: true,
|
|
id: '',
|
|
dataIndex: 'CNTR1',
|
|
text: '箱型1',
|
|
width: 60
|
|
},
|
|
{
|
|
sortable: true,
|
|
id: '',
|
|
dataIndex: 'CNTR2',
|
|
text: '箱型2',
|
|
width: 60
|
|
},
|
|
{
|
|
sortable: true,
|
|
id: '',
|
|
dataIndex: 'CNTR3',
|
|
text: '箱型3',
|
|
width: 60
|
|
},
|
|
{
|
|
sortable: true,
|
|
id: '',
|
|
dataIndex: 'CNTR4',
|
|
text: '箱型4',
|
|
width: 60
|
|
},
|
|
{
|
|
sortable: true,
|
|
id: '',
|
|
dataIndex: 'CNTR5',
|
|
text: '箱型5',
|
|
width: 60
|
|
},
|
|
{
|
|
sortable: true,
|
|
id: '',
|
|
dataIndex: 'CNTR6',
|
|
text: '箱型6',
|
|
width: 60
|
|
},
|
|
{
|
|
sortable: true,
|
|
id: '',
|
|
dataIndex: 'CNTR7',
|
|
text: '箱型7',
|
|
width: 60
|
|
},
|
|
{
|
|
sortable: true,
|
|
id: '',
|
|
dataIndex: 'CNTR8',
|
|
text: '箱型8',
|
|
width: 60
|
|
},
|
|
{
|
|
sortable: true,
|
|
id: '',
|
|
dataIndex: 'CNTR9',
|
|
text: '箱型9',
|
|
width: 60
|
|
},
|
|
{
|
|
sortable: true,
|
|
id: '',
|
|
dataIndex: 'CNTR10',
|
|
text: '箱型10',
|
|
width: 60
|
|
},
|
|
{
|
|
sortable: true,
|
|
id: '',
|
|
dataIndex: 'OTCNTR',
|
|
text: '其他箱型',
|
|
width: 60
|
|
}, {
|
|
sortable: true,
|
|
dataIndex: 'TEU',
|
|
text: 'TEU',
|
|
summaryType: 'sum',
|
|
width: 80
|
|
}, {
|
|
sortable: true,
|
|
dataIndex: 'KGS',
|
|
text: 'KGS',
|
|
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',
|
|
summaryType: 'sum',
|
|
summaryRenderer: function (value, cellmeta, record, rowIndex, columnIndex, store) {
|
|
value = usMoney(value, 2, '', true);
|
|
return value;
|
|
},
|
|
width: 80
|
|
}];
|
|
|
|
this.girdcolumsdestination = this.initgirdcolumsdestination;
|
|
|
|
this.gridListDestination = new Ext.grid.GridPanel({
|
|
store: this.storeDestinationList,
|
|
enableHdMenu: false,
|
|
region: 'center',
|
|
loadMask: { msg: "数据加载中,请稍等..." },
|
|
trackMouseOver: true,
|
|
disableSelection: false,
|
|
viewConfig: {
|
|
enableTextSelection: true, //允许复制数据
|
|
autoFill: true
|
|
},
|
|
// features: [{
|
|
// id: 'group',
|
|
// ftype: 'groupingsummary',
|
|
// groupHeaderTpl: '{name}',
|
|
// hideGroupedHeader: true,
|
|
// enableGroupingMenu: true
|
|
// }],
|
|
columns: this.girdcolumsdestination,
|
|
// paging bar on the bottom
|
|
bbar: Ext.create('Ext.PagingToolbar', {
|
|
store: this.storeLaneList,
|
|
displayInfo: true,
|
|
displayMsg: '当前显示 {0} - {1}条记录 /共 {2}条记录',
|
|
emptyMsg: "没有数据"
|
|
})
|
|
});
|
|
this.girdcolumsdestination = DsTruck.GetGridPanel(USERID, this.formname + 'destination', this.girdcolumsdestination, 1);
|
|
// this.gridListBsSourceDetail.reconfigure(this.storeBsSourceDetailList, this.girdcolumsbssourcedetail);
|
|
|
|
|
|
this.gridListDestination.addListener('sortchange', function (ct, column, direction, eOpts) {
|
|
this.destinationlistsortfield = column.dataIndex;
|
|
this.destinationlistsortdire = direction;
|
|
}, this);
|
|
|
|
//#endregion
|
|
|
|
this.storeSumList = Ext.create('Ext.data.Store', {
|
|
pageSize: this.PageSize,
|
|
fields: [
|
|
{ name: 'NETWEIGHT', type: 'number' },
|
|
{ name: 'BLCOUNT', type: 'number' },
|
|
{ name: 'OPXS', type: 'number' },
|
|
{ name: 'KGS', type: 'number' },
|
|
{ name: 'TEU', type: 'number' },
|
|
{ name: 'CNTR1', type: 'number' },
|
|
{ name: 'CNTR2', type: 'number' },
|
|
{ name: 'CNTR3', type: 'number' },
|
|
{ name: 'CNTR4', type: 'number' },
|
|
{ name: 'CNTR5', type: 'number' },
|
|
{ name: 'CNTR6', type: 'number' },
|
|
{ name: 'CNTR7', type: 'number' },
|
|
{ name: 'CNTR8', type: 'number' },
|
|
{ name: 'CNTR9', type: 'number' },
|
|
{ name: 'CNTR10', type: 'number' },
|
|
{ name: 'OTCNTR', type: 'number' }
|
|
|
|
],
|
|
remoteSort: true,
|
|
proxy: {
|
|
type: 'ajax',
|
|
timeout: 120000,
|
|
url: '/MvcShipping/MsRptOpBsList/OpXsSumListData',
|
|
reader: {
|
|
id: '',
|
|
root: 'data',
|
|
totalProperty: 'totalCount'
|
|
}
|
|
}
|
|
});
|
|
|
|
this.initgridlistsumcolumn = [{
|
|
sortable: true,
|
|
dataIndex: 'BLCOUNT',
|
|
text: '票数',
|
|
width: 80
|
|
},
|
|
{
|
|
sortable: true,
|
|
id: '',
|
|
dataIndex: 'OPXS',
|
|
text: '操作系数',
|
|
width: 60
|
|
},
|
|
{
|
|
sortable: true,
|
|
id: '',
|
|
dataIndex: 'NETWEIGHT',
|
|
text: '计费重量',
|
|
width: 60
|
|
},
|
|
{
|
|
sortable: true,
|
|
id: '',
|
|
dataIndex: 'TEU',
|
|
text: 'TEU',
|
|
width: 60
|
|
},
|
|
{
|
|
sortable: true,
|
|
id: '',
|
|
dataIndex: 'CNTR1',
|
|
text: '箱型1',
|
|
width: 60
|
|
},
|
|
{
|
|
sortable: true,
|
|
id: '',
|
|
dataIndex: 'CNTR2',
|
|
text: '箱型2',
|
|
width: 60
|
|
},
|
|
{
|
|
sortable: true,
|
|
id: '',
|
|
dataIndex: 'CNTR3',
|
|
text: '箱型3',
|
|
width: 60
|
|
},
|
|
{
|
|
sortable: true,
|
|
id: '',
|
|
dataIndex: 'CNTR4',
|
|
text: '箱型4',
|
|
width: 60
|
|
},
|
|
{
|
|
sortable: true,
|
|
id: '',
|
|
dataIndex: 'CNTR5',
|
|
text: '箱型5',
|
|
width: 60
|
|
},
|
|
{
|
|
sortable: true,
|
|
id: '',
|
|
dataIndex: 'CNTR6',
|
|
text: '箱型6',
|
|
width: 60
|
|
},
|
|
{
|
|
sortable: true,
|
|
id: '',
|
|
dataIndex: 'CNTR7',
|
|
text: '箱型7',
|
|
width: 60
|
|
},
|
|
{
|
|
sortable: true,
|
|
id: '',
|
|
dataIndex: 'CNTR8',
|
|
text: '箱型8',
|
|
width: 60
|
|
},
|
|
{
|
|
sortable: true,
|
|
id: '',
|
|
dataIndex: 'CNTR9',
|
|
text: '箱型9',
|
|
width: 60
|
|
},
|
|
{
|
|
sortable: true,
|
|
id: '',
|
|
dataIndex: 'CNTR10',
|
|
text: '箱型10',
|
|
width: 60
|
|
},
|
|
{
|
|
sortable: true,
|
|
id: '',
|
|
dataIndex: 'OTCNTR',
|
|
text: '其他箱型',
|
|
width: 60
|
|
}];
|
|
|
|
|
|
this.gridlistsumcolumn = DsTruck.GetGridPanel(USERID, this.formname + 'sum', this.initgridlistsumcolumn, 1);
|
|
|
|
//定义Grid
|
|
this.gridListSum = new Ext.grid.GridPanel({
|
|
store: this.storeSumList,
|
|
enableHdMenu: false,
|
|
region: 'center',
|
|
loadMask: { msg: "数据加载中,请稍等..." },
|
|
trackMouseOver: true,
|
|
disableSelection: false,
|
|
columns: this.gridlistsumcolumn
|
|
});
|
|
|
|
//#region formSearch
|
|
|
|
//#region formSearch枚举参照相关
|
|
_this = this;
|
|
this.StoreOpLb = Ext.create('DsExt.ux.RefEnumStore', {});
|
|
this.StoreOpLb.load({ params: { enumTypeId: 96005} });
|
|
|
|
this.comboxOpLb = Ext.create('DsExt.ux.RefTableCombox', {
|
|
fieldLabel: '业务类型',
|
|
store: this.StoreOpLb,
|
|
forceSelection: true,
|
|
name: 'PS_OPLB',
|
|
valueField: 'EnumValueName',
|
|
displayField: 'EnumValueName',
|
|
enableKeyEvents: true,
|
|
listeners: {
|
|
keyup: function (field, e) {
|
|
if (e.getKey() == e.ENTER) {
|
|
_this.onRefreshClick();
|
|
}
|
|
}
|
|
}
|
|
});
|
|
|
|
this.storeBsType = Ext.create('DsExt.ux.RefEnumStore', {});
|
|
this.storeBsType.load({ params: { enumTypeId: 96004} });
|
|
|
|
this.comboxBsType = Ext.create('DsExt.ux.RefTableCombox', {
|
|
fieldLabel: '运输类型',
|
|
store: this.storeBsType,
|
|
name: 'PS_BSTYPE',
|
|
valueField: 'EnumValueName',
|
|
displayField: 'EnumValueName',
|
|
enableKeyEvents: true,
|
|
listeners: {
|
|
keyup: function (field, e) {
|
|
if (e.getKey() == e.ENTER) {
|
|
_this.onRefreshClick();
|
|
}
|
|
}
|
|
}
|
|
});
|
|
|
|
this.storeSalesCode = Ext.create('DsExt.ux.RefTableStore', {
|
|
model: 'DsShipping.ux.UserRefModel',
|
|
proxy: { url: '/CommMng/BasicDataRef/GetUserRefList' }
|
|
});
|
|
|
|
this.storeSalesCode.load();
|
|
this.comboxSalesCode = Ext.create('DsExt.ux.RefTableCombox', {
|
|
fieldLabel: '揽货人',
|
|
store: this.storeSalesCode,
|
|
forceSelection: true,
|
|
name: 'PS_SALE',
|
|
valueField: 'UserName',
|
|
displayField: 'CodeAndName',
|
|
enableKeyEvents: true,
|
|
listeners: {
|
|
keyup: function (field, e) {
|
|
if (e.getKey() == e.ENTER) {
|
|
_this.onRefreshClick();
|
|
}
|
|
}
|
|
}
|
|
});
|
|
|
|
this.comboxOp = Ext.create('DsExt.ux.RefTableCombox', {
|
|
fieldLabel: '操 作',
|
|
store: this.storeSalesCode,
|
|
forceSelection: true,
|
|
name: 'PS_OP',
|
|
valueField: 'UserName',
|
|
displayField: 'CodeAndName',
|
|
enableKeyEvents: true,
|
|
listeners: {
|
|
keyup: function (field, e) {
|
|
if (e.getKey() == e.ENTER) {
|
|
_this.onRefreshClick();
|
|
}
|
|
}
|
|
}
|
|
});
|
|
this.comboxCUSTSERVICE = Ext.create('DsExt.ux.RefTableCombox', {
|
|
fieldLabel: '客服',
|
|
store: this.storeSalesCode,
|
|
forceSelection: true,
|
|
name: 'PS_CUSTSERVICE',
|
|
valueField: 'UserName',
|
|
displayField: 'CodeAndName',
|
|
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/GetCustomRefListController' }
|
|
});
|
|
|
|
this.comboxCustCode = Ext.create('DsExt.ux.RefTableCombox', {
|
|
fieldLabel: '委托单位',
|
|
store: this.storeCustCode,
|
|
name: 'PS_CUSTOMERNAME',
|
|
queryMode: 'remote',
|
|
minChars: 0,
|
|
queryParam: 'CODENAME',
|
|
valueField: 'CustName',
|
|
displayField: 'CodeAndName',
|
|
enableKeyEvents: true,
|
|
listeners: {
|
|
keyup: function (field, e) {
|
|
if (e.getKey() == e.ENTER) {
|
|
_this.onRefreshClick();
|
|
}
|
|
}
|
|
}
|
|
|
|
});
|
|
|
|
this.storeEnterpCode = Ext.create('DsExt.ux.RefTableStore', {
|
|
fields: [
|
|
{ name: 'CUSTOMER', type: 'string' },
|
|
{ name: 'ENTERPID', type: 'string' }
|
|
],
|
|
proxy: { url: '/MvcShipping/MsOpApply/GetENTERPLIST' }
|
|
});
|
|
this.storeEnterpCode.load();
|
|
|
|
this.comboxEnterp = Ext.create('DsExt.ux.RefTableCombox', {
|
|
fieldLabel: '经营单位',
|
|
store: this.storeEnterpCode,
|
|
name: 'PS_ENTERP',
|
|
valueField: 'CUSTOMER',
|
|
displayField: 'CUSTOMER',
|
|
enableKeyEvents: true,
|
|
listeners: {
|
|
keyup: function (field, e) {
|
|
if (e.getKey() == e.ENTER) {
|
|
_this.onRefreshClick();
|
|
}
|
|
}
|
|
}
|
|
|
|
});
|
|
|
|
//业务来源
|
|
this.storeSource = Ext.create('DsExt.ux.RefTableStore', {
|
|
model: 'DsShipping.ux.SourceModel',
|
|
proxy: { url: '/CommMng/BasicDataRef/GetSource' }
|
|
});
|
|
this.storeSource.load();
|
|
this.storeSourceDetail = Ext.create('DsExt.ux.RefTableStore', {
|
|
model: 'DsShipping.ux.SourceDetailModel',
|
|
proxy: { url: '/CommMng/BasicDataRef/GetSourceDetail2' }
|
|
});
|
|
this.comboxBSSOURCE = Ext.create('DsExt.ux.RefTableCombox', {
|
|
fieldLabel: '业务来源',
|
|
store: this.storeSource,
|
|
forceSelection: true,
|
|
name: 'BSSOURCE',
|
|
valueField: 'SourceName',
|
|
displayField: 'SourceName',
|
|
listeners: {
|
|
scope: this,
|
|
'select': function (combo, records, eOpts) {
|
|
if (records.length > 0) {
|
|
var recs = DsStoreQueryBy(this.storeSource, 'SourceID', records[0].data.SourceID);
|
|
if (recs.getCount() > 0) {
|
|
var data = recs.getAt(0).data;
|
|
var s = "SOURCEID='" + data.SourceID + "'";
|
|
this.storeSourceDetail.load({ params: { condition: s} });
|
|
} else {
|
|
var BSSOURCEDETAIL = this.formSearch.getForm().findField('BSSOURCEDETAIL');
|
|
BSSOURCEDETAIL.setValue('');
|
|
}
|
|
}
|
|
}
|
|
}
|
|
});
|
|
this.storeSourceDetail.load();
|
|
this.comboxBSSOURCEDETAIL = Ext.create('DsExt.ux.RefTableCombox', {
|
|
fieldLabel: '来源明细',
|
|
store: this.storeSourceDetail,
|
|
forceSelection: true,
|
|
name: 'BSSOURCEDETAIL',
|
|
valueField: 'SourceDetail',
|
|
displayField: 'SourceDetail',
|
|
enableKeyEvents: true,
|
|
listeners: {
|
|
keyup: function (field, e) {
|
|
if (e.getKey() == e.ENTER) {
|
|
_this.onRefreshClick();
|
|
}
|
|
}
|
|
}
|
|
});
|
|
|
|
|
|
|
|
Ext.define('SubComp', {
|
|
extend: 'Ext.data.Model',
|
|
fields: [
|
|
{ name: 'GID', type: 'string' },
|
|
{ name: 'NAME', type: 'string' },
|
|
{ name: 'ENNAME', type: 'string' }
|
|
]
|
|
});
|
|
this.StoreSubComp = Ext.create('DsExt.ux.RefTableStore', {
|
|
model: 'SubComp',
|
|
proxy: { url: '/MvcShipping/MsBaseInfo/GetCompanyEN' }
|
|
});
|
|
|
|
this.StoreSubComp.load({ params: { condition: ""} });
|
|
|
|
this.comboxSubComp = Ext.create('DsExt.ux.RefTableCombox', {
|
|
fieldLabel: '所属公司',
|
|
store: this.StoreSubComp,
|
|
name: 'SUBCOMP',
|
|
// flex: 0.5,
|
|
// labelWidth: 55,
|
|
valueField: 'GID',
|
|
displayField: 'NAME',
|
|
enableKeyEvents: true,
|
|
listeners: {
|
|
keyup: function (field, e) {
|
|
if (e.getKey() == e.ENTER) {
|
|
_this.onRefreshClick();
|
|
}
|
|
}
|
|
}
|
|
|
|
});
|
|
|
|
this.StoreFeeLock = Ext.create('Ext.data.Store', {
|
|
fields: ['OpLb']
|
|
});
|
|
this.StoreFeeLock.add({ "OpLb": "全部" });
|
|
this.StoreFeeLock.add({ "OpLb": "已锁定" });
|
|
this.StoreFeeLock.add({ "OpLb": "未锁定" });
|
|
|
|
this.comboxFeeLock = Ext.create('DsExt.ux.RefTableCombox', {
|
|
fieldLabel: '费用锁定',
|
|
store: this.StoreFeeLock,
|
|
forceSelection: true,
|
|
name: 'PS_FEELOCK',
|
|
// flex: 0.5,
|
|
// labelWidth: 55,
|
|
valueField: 'OpLb',
|
|
displayField: 'OpLb',
|
|
enableKeyEvents: true,
|
|
listeners: {
|
|
keyup: function (field, e) {
|
|
if (e.getKey() == e.ENTER) {
|
|
_this.onRefreshClick();
|
|
}
|
|
}
|
|
}
|
|
});
|
|
|
|
|
|
|
|
|
|
|
|
|
|
this.storeVoyVeg = Ext.create('DsExt.ux.RefTableStore', {
|
|
model: 'DsShipping.ux.VesselModel',
|
|
proxy: { url: '/CommMng/BasicDataRef/GetVesselList' }
|
|
});
|
|
this.storeVoyVeg.load({ params: { condition: ""} });
|
|
|
|
this.comboxVoyVeg = Ext.create('DsExt.ux.RefTableCombox', {
|
|
fieldLabel: '船 名',
|
|
store: this.storeVoyVeg,
|
|
valueField: 'VESSEL',
|
|
flex: 1.5,
|
|
name: 'PS_VESSEL',
|
|
displayField: 'VESSEL',
|
|
enableKeyEvents: true,
|
|
listeners: {
|
|
keyup: function (field, e) {
|
|
if (e.getKey() == e.ENTER) {
|
|
_this.onRefreshClick();
|
|
}
|
|
}
|
|
}
|
|
});
|
|
|
|
//#endregion
|
|
|
|
|
|
this.formSearch = 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.comboxOpLb, {
|
|
fieldLabel: '编号',
|
|
name: 'PS_MBLNO',
|
|
enableKeyEvents: true,
|
|
listeners: {
|
|
specialkey: function (field, e) {
|
|
if (e.getKey() == e.ENTER) {
|
|
_this.onRefreshClick();
|
|
}
|
|
}
|
|
}
|
|
}, this.comboxVoyVeg, {
|
|
fieldLabel: '航次',
|
|
name: 'PS_VOYNO',
|
|
labelWidth: 40,
|
|
flex: 0.5,
|
|
enableKeyEvents: true,
|
|
listeners: {
|
|
specialkey: function (field, e) {
|
|
if (e.getKey() == e.ENTER) {
|
|
_this.onRefreshClick();
|
|
}
|
|
}
|
|
}
|
|
}, this.comboxOp, this.comboxSubComp
|
|
]
|
|
}, {
|
|
xtype: 'container',
|
|
layout: 'hbox',
|
|
defaultType: 'textfield',
|
|
items: [ {
|
|
fieldLabel: '业务日期',
|
|
format: 'Y-m-d',
|
|
xtype: 'datefield',
|
|
name: 'PS_EXPDATEBGN',
|
|
enableKeyEvents: true,
|
|
listeners: {
|
|
specialkey: function (field, e) {
|
|
if (e.getKey() == e.ENTER) {
|
|
_this.onRefreshClick();
|
|
}
|
|
}
|
|
}
|
|
}, {
|
|
fieldLabel: '到',
|
|
format: 'Y-m-d',
|
|
xtype: 'datefield',
|
|
name: 'PS_EXPDATEEND',
|
|
enableKeyEvents: true,
|
|
listeners: {
|
|
specialkey: function (field, e) {
|
|
if (e.getKey() == e.ENTER) {
|
|
_this.onRefreshClick();
|
|
}
|
|
}
|
|
}
|
|
}, this.comboxBsType, this.comboxSalesCode, this.comboxCustCode, this.comboxBSSOURCE
|
|
]
|
|
}, {
|
|
xtype: 'container',
|
|
layout: 'hbox',
|
|
defaultType: 'textfield',
|
|
items: [{
|
|
fieldLabel: '从会计期间',
|
|
xtype: 'monthfield',
|
|
name: 'PS_ACCDATEBGN',
|
|
enableKeyEvents: true,
|
|
listeners: {
|
|
specialkey: function (field, e) {
|
|
if (e.getKey() == e.ENTER) {
|
|
_this.onRefreshClick();
|
|
}
|
|
}
|
|
}
|
|
}, {
|
|
fieldLabel: '到',
|
|
xtype: 'monthfield',
|
|
name: 'PS_ACCDATEEND',
|
|
enableKeyEvents: true,
|
|
listeners: {
|
|
specialkey: function (field, e) {
|
|
if (e.getKey() == e.ENTER) {
|
|
_this.onRefreshClick();
|
|
}
|
|
}
|
|
}
|
|
}, this.comboxBSSOURCEDETAIL, this.comboxCUSTSERVICE, this.comboxFeeLock, this.comboxEnterp
|
|
]
|
|
}
|
|
]//end items(fieldset 1)
|
|
}//end fieldset 1
|
|
]//end root items
|
|
|
|
});
|
|
|
|
|
|
|
|
//#endregion formSearch
|
|
|
|
//查询工具条
|
|
|
|
this.CheckSaveQuery = new Ext.form.Checkbox({
|
|
fieldLabel: '记忆查询条件',
|
|
checked: true,
|
|
width: 120
|
|
});
|
|
|
|
|
|
_this = this;
|
|
this.SearchBtn = new Ext.Button({
|
|
text: '隐藏查询',
|
|
handler: function () {
|
|
if (_this.SearchBtn.text == '隐藏查询') {
|
|
_this.panelSearch.hide();
|
|
_this.SearchBtn.setText("显示查询");
|
|
|
|
} else {
|
|
|
|
_this.panelSearch.show();
|
|
_this.SearchBtn.setText("隐藏查询");
|
|
|
|
|
|
}
|
|
}
|
|
});
|
|
|
|
this.panelBtn = new Ext.Panel({
|
|
region: "north",
|
|
tbar: [
|
|
{
|
|
text: "执行查询",
|
|
iconCls: "btnrefresh",
|
|
handler: function (button, event) {
|
|
this.onRefreshClick(button, event);
|
|
var isvisible = true;
|
|
var issavevalue = false;
|
|
|
|
if (_this.SearchBtn.text == '隐藏查询')
|
|
isvisible = true
|
|
else
|
|
isvisible = false;
|
|
if (this.CheckSaveQuery.checked)
|
|
issavevalue = true
|
|
|
|
saveQuerySetting(this.formname, this.formSearch, isvisible, issavevalue);
|
|
|
|
},
|
|
scope: this
|
|
}, {
|
|
text: "导出Excel",
|
|
id: "btnExportExcel",
|
|
iconCls: 'btnexportexcel',
|
|
handler: function (button, event) {
|
|
this.onExportClick(button, event);
|
|
},
|
|
scope: this
|
|
}, '-',
|
|
{
|
|
text: "打印",
|
|
iconCls: 'btnprint',
|
|
handler: function (button, event) {
|
|
this.Print();
|
|
},
|
|
scope: this
|
|
}, '-', this.SearchBtn, {
|
|
xtype: 'button',
|
|
width: 90,
|
|
text: "清空条件",
|
|
iconCls: "btnreset",
|
|
handler: function (button, event) {
|
|
this.onClearSql(button, event);
|
|
},
|
|
scope: this
|
|
}, '-', {
|
|
xtype: 'button',
|
|
text: "高级查询",
|
|
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;
|
|
},
|
|
scope: this
|
|
}, '-', this.CheckSaveQuery, '-', {
|
|
text: "保存列表样式",
|
|
id: "btntest",
|
|
menu: [
|
|
{ text: "保存列表",
|
|
handler: function (button, event) {
|
|
_this.onSaveGridClick(button, event);
|
|
|
|
}
|
|
}, { text: "列表初始化",
|
|
handler: function (button, event) {
|
|
_this.oninitGridClick(button, event);
|
|
}
|
|
}],
|
|
scope: this
|
|
}
|
|
]
|
|
});
|
|
|
|
this.panelTop = new Ext.Panel({
|
|
layout: "border",
|
|
region: "north",
|
|
height: 29,
|
|
items: [this.panelBtn]
|
|
});
|
|
|
|
this.panelSearch = new Ext.Panel({
|
|
layout: "border",
|
|
region: "north",
|
|
height: 96,
|
|
items: [this.formSearch]
|
|
});
|
|
|
|
this.panelBodyChFee = new Ext.Panel({
|
|
title: '业务明细',
|
|
layout: "border",
|
|
region: 'center',
|
|
margin: '0 0',
|
|
frame: true,
|
|
items: [this.gridList]
|
|
});
|
|
|
|
this.panelSaleSum = new Ext.Panel({
|
|
title: '揽货人',
|
|
layout: "border",
|
|
region: 'center',
|
|
margin: '0 0',
|
|
frame: true,
|
|
items: [this.gridListSale]
|
|
});
|
|
|
|
this.panelCustSum = new Ext.Panel({
|
|
title: '委托单位',
|
|
layout: "border",
|
|
region: 'center',
|
|
margin: '0 0',
|
|
frame: true,
|
|
items: [this.gridListCust]
|
|
});
|
|
|
|
this.panelCarrierSum = new Ext.Panel({
|
|
title: '船公司',
|
|
layout: "border",
|
|
region: 'center',
|
|
margin: '0 0',
|
|
frame: true,
|
|
items: [this.gridListCarrier]
|
|
});
|
|
|
|
|
|
this.panelDeptSum = new Ext.Panel({
|
|
title: '部门',
|
|
layout: "border",
|
|
region: 'center',
|
|
margin: '0 0',
|
|
frame: true,
|
|
items: [this.gridListDept]
|
|
});
|
|
|
|
this.panelOpSum = new Ext.Panel({
|
|
title: '操作员',
|
|
layout: "border",
|
|
region: 'center',
|
|
margin: '0 0',
|
|
frame: true,
|
|
items: [this.gridListOp]
|
|
});
|
|
this.panelBsSourceSum = new Ext.Panel({
|
|
title: '业务来源',
|
|
layout: "border",
|
|
region: 'center',
|
|
margin: '0 0',
|
|
frame: true,
|
|
items: [this.gridListBsSource]
|
|
});
|
|
this.panelBsSourceDetailSum = new Ext.Panel({
|
|
title: '来源明细',
|
|
layout: "border",
|
|
region: 'center',
|
|
margin: '0 0',
|
|
frame: true,
|
|
items: [this.gridListBsSourceDetail]
|
|
});
|
|
this.panelLaneSum = new Ext.Panel({
|
|
title: '航线',
|
|
layout: "border",
|
|
region: 'center',
|
|
margin: '0 0',
|
|
frame: true,
|
|
items: [this.gridListLane]
|
|
});
|
|
this.panelDestinationSum = new Ext.Panel({
|
|
title: '目的港',
|
|
layout: "border",
|
|
region: 'center',
|
|
margin: '0 0',
|
|
frame: true,
|
|
items: [this.gridListDestination]
|
|
});
|
|
|
|
this.panelSum = new Ext.Panel({
|
|
title: '合 计',
|
|
layout: "border",
|
|
height: 120,
|
|
region: 'south',
|
|
margin: '0 0',
|
|
frame: true,
|
|
items: [this.gridListSum]
|
|
});
|
|
|
|
|
|
this.tabpanel = new Ext.TabPanel
|
|
({
|
|
activeTab: 0,
|
|
autoWidth: true,
|
|
border: false,
|
|
frame: false,
|
|
region: 'center',
|
|
id: "TabPanelID",
|
|
enableTabScroll: true,
|
|
items:
|
|
[
|
|
this.panelBodyChFee
|
|
// ,
|
|
//this.panelCustSum,
|
|
//this.panelSaleSum,
|
|
//this.panelCarrierSum,
|
|
//this.panelOpSum,
|
|
//this.panelDeptSum,
|
|
//this.panelBsSourceSum,
|
|
//this.panelBsSourceDetailSum,
|
|
//this.panelLaneSum,
|
|
//this.panelDestinationSum
|
|
]
|
|
});
|
|
|
|
Ext.apply(this, {
|
|
items: [this.panelTop, this.panelSearch, this.tabpanel, this.panelSum]
|
|
});
|
|
|
|
_this = this;
|
|
this.storectndisp.load({ params: { condition: "" },
|
|
callback: function (r, options, success) {
|
|
if (success) {
|
|
if (r.length != 0) {
|
|
|
|
_this.InitGrid(_this.girdcolums, _this.gridList, _this.storeList);
|
|
//_this.InitGrid(_this.girdcolumssale, _this.gridListSale, _this.storeSaleList);
|
|
//_this.InitGrid(_this.girdcolumscust, _this.gridListCust, _this.storeCustList);
|
|
//_this.InitGrid(_this.girdcolumsdept, _this.gridListDept, _this.storeDeptList);
|
|
//_this.InitGrid(_this.girdcolumsop, _this.gridListOp, _this.storeOpList);
|
|
//_this.InitGrid(_this.girdcolumsbssource, _this.gridListBsSource, _this.storeBsSourceList);
|
|
//_this.InitGrid(_this.girdcolumsbssourcedetail, _this.gridListBsSourceDetail, _this.storeBsSourceDetailList);
|
|
//_this.InitGrid(_this.girdcolumslane, _this.gridListLane, _this.storeLaneList);
|
|
//_this.InitGrid(_this.gridlistsumcolumn, _this.gridListSum, _this.storeSumList);
|
|
//_this.InitGrid(_this.girdcolumscarrier, _this.gridListCarrier, _this.storeCarrierList);
|
|
//_this.InitGrid(_this.girdcolumsdestination, _this.gridListDestination, _this.storeDestinationList);
|
|
|
|
}
|
|
|
|
|
|
}
|
|
},
|
|
scope: this
|
|
});
|
|
|
|
_this = this;
|
|
|
|
this.storeList.on('beforeload', function (store) {
|
|
|
|
Ext.apply(store.proxy.extraParams, { condition: _this.sqlcontext });
|
|
}, this);
|
|
//this.storeSaleList.on('beforeload', function (store) {
|
|
// // if (!this.checkSearchCondition())
|
|
// // return;
|
|
|
|
// // var sql = this.getCondition();
|
|
// Ext.apply(store.proxy.extraParams, { condition: _this.sqlcontext });
|
|
//}, this);
|
|
//this.storeCustList.on('beforeload', function (store) {
|
|
// // if (!this.checkSearchCondition())
|
|
// // return;
|
|
|
|
// // var sql = this.getCondition();
|
|
// Ext.apply(store.proxy.extraParams, { condition: _this.sqlcontext});
|
|
//}, this);
|
|
//this.storeCarrierList.on('beforeload', function (store) {
|
|
// // if (!this.checkSearchCondition())
|
|
// // return;
|
|
|
|
// // var sql = this.getCondition();
|
|
// Ext.apply(store.proxy.extraParams, { condition: _this.sqlcontext});
|
|
//}, this);
|
|
//this.storeDeptList.on('beforeload', function (store) {
|
|
// // if (!this.checkSearchCondition())
|
|
// // return;
|
|
|
|
// // var sql = this.getCondition();
|
|
// Ext.apply(store.proxy.extraParams, { condition: _this.sqlcontext});
|
|
//}, this);
|
|
|
|
//this.storeOpList.on('beforeload', function (store) {
|
|
// // if (!this.checkSearchCondition())
|
|
// // return;
|
|
|
|
// // var sql = this.getCondition();
|
|
// Ext.apply(store.proxy.extraParams, { condition: _this.sqlcontext});
|
|
//}, this);
|
|
//this.storeBsSourceList.on('beforeload', function (store) {
|
|
// // if (!this.checkSearchCondition())
|
|
// // return;
|
|
|
|
// // var sql = this.getCondition();
|
|
// Ext.apply(store.proxy.extraParams, { condition: _this.sqlcontext });
|
|
//}, this);
|
|
//this.storeBsSourceDetailList.on('beforeload', function (store) {
|
|
// // if (!this.checkSearchCondition())
|
|
// // return;
|
|
|
|
// // var sql = this.getCondition();
|
|
// Ext.apply(store.proxy.extraParams, { condition: _this.sqlcontext });
|
|
//}, this);
|
|
|
|
//this.storeLaneList.on('beforeload', function (store) {
|
|
// // if (!this.checkSearchCondition())
|
|
// // return;
|
|
|
|
// // var sql = this.getCondition();
|
|
// Ext.apply(store.proxy.extraParams, { condition: _this.sqlcontext });
|
|
//}, this);
|
|
|
|
//this.storeDestinationList.on('beforeload', function (store) {
|
|
// // if (!this.checkSearchCondition())
|
|
// // return;
|
|
|
|
// // var sql = this.getCondition();
|
|
// Ext.apply(store.proxy.extraParams, { condition: _this.sqlcontext });
|
|
//}, this);
|
|
|
|
this.storeSumList.on('beforeload', function (store) {
|
|
// if (!this.checkSearchCondition())
|
|
// return;
|
|
|
|
// var sql = this.getCondition();
|
|
Ext.apply(store.proxy.extraParams, { condition: _this.sqlcontext });
|
|
}, this);
|
|
|
|
LoadQueryData(this.formname, this.formSearch, this.CheckSaveQuery);
|
|
|
|
}, //end initUIComponents
|
|
|
|
InitGrid: function (grid, thgridList, thstoreList) {
|
|
|
|
|
|
|
|
var agirdcolums = grid;
|
|
|
|
|
|
|
|
for (i = 0; i < this.storectndisp.getCount(); i += 1) {
|
|
var itemindex = i + 1;
|
|
var memberyf = this.storectndisp.getAt(i);
|
|
for (var j = 0; j < agirdcolums.length; j++) {
|
|
if (agirdcolums[j].dataIndex == 'CNTR1') {
|
|
if (memberyf.data.CNT1 != '' && memberyf.data.CNT1 != null) {
|
|
agirdcolums[j].text = memberyf.data.CNT1;
|
|
agirdcolums[j].hidden = false;
|
|
} else {
|
|
agirdcolums[j].hidden = true;
|
|
}
|
|
}
|
|
if (agirdcolums[j].dataIndex == 'CNTR2') {
|
|
if (memberyf.data.CNT2 != '' && memberyf.data.CNT2 != null) {
|
|
agirdcolums[j].text = memberyf.data.CNT2;
|
|
agirdcolums[j].hidden = false;
|
|
} else {
|
|
agirdcolums[j].hidden = true;
|
|
}
|
|
}
|
|
if (agirdcolums[j].dataIndex == 'CNTR3') {
|
|
if (memberyf.data.CNT3 != '' && memberyf.data.CNT3 != null) {
|
|
agirdcolums[j].text = memberyf.data.CNT3;
|
|
agirdcolums[j].hidden = false;
|
|
} else {
|
|
agirdcolums[j].hidden = true;
|
|
}
|
|
}
|
|
if (agirdcolums[j].dataIndex == 'CNTR4') {
|
|
if (memberyf.data.CNT4 != '' && memberyf.data.CNT4 != null) {
|
|
agirdcolums[j].text = memberyf.data.CNT4;
|
|
agirdcolums[j].hidden = false;
|
|
} else {
|
|
agirdcolums[j].hidden = true;
|
|
}
|
|
}
|
|
if (agirdcolums[j].dataIndex == 'CNTR5') {
|
|
if (memberyf.data.CNT5 != '' && memberyf.data.CNT5 != null) {
|
|
agirdcolums[j].header = memberyf.data.CNT5;
|
|
agirdcolums[j].hidden = false;
|
|
} else {
|
|
agirdcolums[j].hidden = true;
|
|
}
|
|
}
|
|
if (agirdcolums[j].dataIndex == 'CNTR6') {
|
|
if (memberyf.data.CNT6 != '' && memberyf.data.CNT6 != null) {
|
|
agirdcolums[j].text = memberyf.data.CNT6;
|
|
agirdcolums[j].hidden = false;
|
|
} else {
|
|
agirdcolums[j].hidden = true;
|
|
}
|
|
}
|
|
if (agirdcolums[j].dataIndex == 'CNTR7') {
|
|
if (memberyf.data.CNT7 != '' && memberyf.data.CNT7 != null) {
|
|
agirdcolums[j].text = memberyf.data.CNT7;
|
|
agirdcolums[j].hidden = false;
|
|
} else {
|
|
agirdcolums[j].hidden = true;
|
|
}
|
|
}
|
|
if (agirdcolums[j].dataIndex == 'CNTR8') {
|
|
if (memberyf.data.CNT8 != '' && memberyf.data.CNT8 != null) {
|
|
agirdcolums[j].text = memberyf.data.CNT8;
|
|
agirdcolums[j].hidden = false;
|
|
} else {
|
|
agirdcolums[j].hidden = true;
|
|
}
|
|
}
|
|
if (agirdcolums[j].dataIndex == 'CNTR9') {
|
|
if (memberyf.data.CNT9 != '' && memberyf.data.CNT9 != null) {
|
|
agirdcolums[j].text = memberyf.data.CNT9;
|
|
agirdcolums[j].hidden = false;
|
|
} else {
|
|
agirdcolums[j].hidden = true;
|
|
}
|
|
}
|
|
if (agirdcolums[j].dataIndex == 'CNTR10') {
|
|
if (memberyf.data.CNT10 != '' && memberyf.data.CNT10 != null) {
|
|
agirdcolums[j].text = memberyf.data.CNT10;
|
|
agirdcolums[j].hidden = false;
|
|
} else {
|
|
agirdcolums[j].hidden = true;
|
|
}
|
|
}
|
|
}
|
|
};
|
|
thgridList.reconfigure(thstoreList, agirdcolums);
|
|
|
|
},
|
|
|
|
onRefreshClick: function (button, event) {
|
|
if (!this.checkSearchCondition())
|
|
return;
|
|
|
|
var sql = this.getCondition();
|
|
|
|
this.sqlcontext = sql;
|
|
this.PageSize = this.Pagenum.getValue();
|
|
|
|
this.storeList.pageSize = this.PageSize;
|
|
//this.storeCustList.pageSize = this.PageSize;
|
|
//this.storeCarrierList.pageSize = this.PageSize;
|
|
//this.storeSaleList.pageSize = this.PageSize;
|
|
//this.storeDeptList.pageSize = this.PageSize;
|
|
//this.storeOpList.pageSize = this.PageSize;
|
|
//this.storeBsSourceList.pageSize = this.PageSize;
|
|
//this.storeBsSourceDetailList.pageSize = this.PageSize;
|
|
//this.storeLaneList.pageSize = this.PageSize;
|
|
|
|
|
|
|
|
this.storeList.load({
|
|
params: { start: 0, limit: this.PageSize, condition: sql},
|
|
waitMsg: "正在查询数据...",
|
|
scope: this
|
|
});
|
|
//this.storeCustList.load({
|
|
// params: { start: 0, limit: this.PageSize, condition: sql},
|
|
// waitMsg: "正在查询数据...",
|
|
// scope: this
|
|
//});
|
|
//this.storeCarrierList.load({
|
|
// params: { start: 0, limit: this.PageSize, condition: sql},
|
|
// waitMsg: "正在查询数据...",
|
|
// scope: this
|
|
//});
|
|
//this.storeSaleList.load({
|
|
// params: { start: 0, limit: this.PageSize, condition: sql},
|
|
// waitMsg: "正在查询数据...",
|
|
// scope: this
|
|
//});
|
|
//this.storeDeptList.load({
|
|
// params: { start: 0, limit: this.PageSize, condition: sql},
|
|
// waitMsg: "正在查询数据...",
|
|
// scope: this
|
|
//});
|
|
//this.storeOpList.load({
|
|
// params: { start: 0, limit: this.PageSize, condition: sql},
|
|
// waitMsg: "正在查询数据...",
|
|
// scope: this
|
|
//});
|
|
//this.storeBsSourceList.load({
|
|
// params: { start: 0, limit: this.PageSize, condition: sql},
|
|
// waitMsg: "正在查询数据...",
|
|
// scope: this
|
|
//});
|
|
//this.storeBsSourceDetailList.load({
|
|
// params: { start: 0, limit: this.PageSize, condition: sql},
|
|
// waitMsg: "正在查询数据...",
|
|
// scope: this
|
|
//});
|
|
//this.storeLaneList.load({
|
|
// params: { start: 0, limit: this.PageSize, condition: sql},
|
|
// waitMsg: "正在查询数据...",
|
|
// scope: this
|
|
//});
|
|
//this.storeDestinationList.load({
|
|
// params: { start: 0, limit: this.PageSize, condition: sql },
|
|
// waitMsg: "正在查询数据...",
|
|
// scope: this
|
|
//});
|
|
this.storeSumList.load({
|
|
params: { start: 0, limit: this.PageSize, condition: sql},
|
|
waitMsg: "正在查询数据...",
|
|
scope: this
|
|
});
|
|
},
|
|
|
|
onDsQuery: function (button, event) {
|
|
|
|
var sql = this.sqlcontext;
|
|
|
|
this.storeList.load({
|
|
params: { start: 0, limit: this.PageSize, condition: sql },
|
|
waitMsg: "正在查询数据...",
|
|
scope: this
|
|
});
|
|
//this.storeCustList.load({
|
|
// params: { start: 0, limit: this.PageSize, condition: sql },
|
|
// waitMsg: "正在查询数据...",
|
|
// scope: this
|
|
//});
|
|
//this.storeCarrierList.load({
|
|
// params: { start: 0, limit: this.PageSize, condition: sql },
|
|
// waitMsg: "正在查询数据...",
|
|
// scope: this
|
|
//});
|
|
//this.storeSaleList.load({
|
|
// params: { start: 0, limit: this.PageSize, condition: sql },
|
|
// waitMsg: "正在查询数据...",
|
|
// scope: this
|
|
//});
|
|
//this.storeDeptList.load({
|
|
// params: { start: 0, limit: this.PageSize, condition: sql },
|
|
// waitMsg: "正在查询数据...",
|
|
// scope: this
|
|
//});
|
|
//this.storeOpList.load({
|
|
// params: { start: 0, limit: this.PageSize, condition: sql },
|
|
// waitMsg: "正在查询数据...",
|
|
// scope: this
|
|
//});
|
|
//this.storeBsSourceList.load({
|
|
// params: { start: 0, limit: this.PageSize, condition: sql },
|
|
// waitMsg: "正在查询数据...",
|
|
// scope: this
|
|
//});
|
|
//this.storeBsSourceDetailList.load({
|
|
// params: { start: 0, limit: this.PageSize, condition: sql },
|
|
// waitMsg: "正在查询数据...",
|
|
// scope: this
|
|
//});
|
|
//this.storeLaneList.load({
|
|
// params: { start: 0, limit: this.PageSize, condition: sql },
|
|
// waitMsg: "正在查询数据...",
|
|
// scope: this
|
|
//});
|
|
//this.storeDestinationList.load({
|
|
// params: { start: 0, limit: this.PageSize, condition: sql },
|
|
// waitMsg: "正在查询数据...",
|
|
// scope: this
|
|
//});
|
|
this.storeSumList.load({
|
|
params: { start: 0, limit: this.PageSize, condition: sql },
|
|
waitMsg: "正在查询数据...",
|
|
scope: this
|
|
});
|
|
},
|
|
|
|
getCondition: function () {
|
|
var form = this.formSearch.getForm();
|
|
var sql = '';
|
|
/*
|
|
var sqldata = form.getValues();
|
|
sql = Ext.JSON.encode(sqldata);
|
|
*/
|
|
|
|
var mblNo = form.findField('PS_MBLNO').getValue();
|
|
sql = sql + getAndConSql(sql, mblNo, " (B.CUSTNO like '%" + mblNo + "%' or B.MBLNO like '%" + mblNo + "%' or B.HBLNO like '%" + mblNo + "%' or B.CUSTOMNO like '%" + mblNo + "%' or B.ORDERNO like '%" + mblNo + "%') ");
|
|
|
|
|
|
//var expDate_Min = form.findField('PS_EXPDATEBGN').getRawValue();
|
|
//sql = sql + getAndConSql(sql, expDate_Min, " B.OPDATE>='" + expDate_Min + "'");
|
|
//var expDate_Max = form.findField('PS_EXPDATEEND').getRawValue();
|
|
//sql = sql + getAndConSql(sql, expDate_Max, " B.OPDATE<='" + expDate_Max + " 23:59:59'");
|
|
|
|
var expDate_Min = form.findField('PS_EXPDATEBGN').getRawValue();
|
|
sql = sql + getAndConSql(sql, expDate_Min, " B.ETD>='" + expDate_Min + "'");
|
|
|
|
var expDate_Max = form.findField('PS_EXPDATEEND').getRawValue();
|
|
sql = sql + getAndConSql(sql, expDate_Max, " B.ETD<='" + expDate_Max + " 23:59:59'");
|
|
|
|
|
|
// var etdDate_Min = form.findField('PS_ETDDATEBGN').getRawValue();
|
|
// sql = sql + getAndConSql(sql, etdDate_Min, " B.ETD>='" + etdDate_Min + "'");
|
|
|
|
// var etdDate_Max = form.findField('PS_ETDDATEEND').getRawValue();
|
|
// sql = sql + getAndConSql(sql, etdDate_Max, " B.ETD<='" + etdDate_Max + " 23:59:59'");
|
|
|
|
var accDate_Min = form.findField('PS_ACCDATEBGN').getRawValue();
|
|
sql = sql + getAndConSql(sql, accDate_Min, " B.ACCDATE>='" + accDate_Min + "'");
|
|
|
|
var accDate_Max = form.findField('PS_ACCDATEEND').getRawValue();
|
|
sql = sql + getAndConSql(sql, accDate_Max, " B.ACCDATE<='" + accDate_Max + "'");
|
|
|
|
var ENTERP = form.findField('PS_ENTERP').getValue();
|
|
sql = sql + getAndConSql(sql, ENTERP, "B.ENTERP='" + ENTERP + "'");
|
|
|
|
var CUSTOMERNAME = form.findField('PS_CUSTOMERNAME').getValue();
|
|
sql = sql + getAndConSql(sql, CUSTOMERNAME, "B.CUSTOMERNAME='" + CUSTOMERNAME + "'");
|
|
|
|
var SALE = form.findField('PS_SALE').getValue();
|
|
sql = sql + getAndConSql(sql, SALE, "B.SALE='" + SALE + "'");
|
|
|
|
var OP = form.findField('PS_OP').getValue();
|
|
sql = sql + getAndConSql(sql, OP, "B.OP='" + OP + "'");
|
|
|
|
var BSTYPE = form.findField('PS_BSTYPE').getValue();
|
|
sql = sql + getAndConSql(sql, BSTYPE, "B.BSTYPE='" + BSTYPE + "'");
|
|
|
|
var OPLB = form.findField('PS_OPLB').getValue();
|
|
sql = sql + getAndConSql(sql, OPLB, "B.OPLBNAME='" + OPLB + "'");
|
|
|
|
var SUBCOMP = form.findField('SUBCOMP').getValue();
|
|
sql = sql + getAndConSql(sql, SUBCOMP, "B.CORPID='" + SUBCOMP + "'");
|
|
|
|
|
|
var PS_CUSTSERVICE = form.findField('PS_CUSTSERVICE').getValue();
|
|
sql = sql + getAndConSql(sql, PS_CUSTSERVICE, "B.CUSTSERVICE='" + PS_CUSTSERVICE + "'");
|
|
|
|
|
|
var VESSEL = form.findField('PS_VESSEL').getValue();
|
|
sql = sql + getAndConSql(sql, VESSEL, "B.VESSEL like '%" + VESSEL + "%'");
|
|
|
|
var VOYNO = form.findField('PS_VOYNO').getValue();
|
|
sql = sql + getAndConSql(sql, VOYNO, "B.VOYNO like '%" + VOYNO + "%'");
|
|
|
|
// var GOODSNAME = form.findField('PS_GOODSNAME').getValue();
|
|
// sql = sql + getAndConSql(sql, GOODSNAME, "B.GOODSNAME like '%" + GOODSNAME + "%'");
|
|
|
|
var BSSOURCE = form.findField('BSSOURCE').getValue();
|
|
sql = sql + getAndConSql(sql, BSSOURCE, "B.BSSOURCE='" + BSSOURCE + "'");
|
|
var BSSOURCEDETAIL = form.findField('BSSOURCEDETAIL').getValue();
|
|
sql = sql + getAndConSql(sql, BSSOURCEDETAIL, "B.BSSOURCEDETAIL='" + BSSOURCEDETAIL + "'");
|
|
|
|
var PS_FEELOCK = form.findField('PS_FEELOCK').getValue();
|
|
if (PS_FEELOCK == '已锁定')
|
|
sql = sql + getAndConSql(sql, PS_FEELOCK, "B.FEESTATUS=1");
|
|
else if (PS_FEELOCK == '未锁定')
|
|
sql = sql + getAndConSql(sql, PS_FEELOCK, "B.FEESTATUS=0");
|
|
// var ISHYF = form.findField('ISHYF').getValue();
|
|
// if (ISHYF == '0') {
|
|
// sql = sql + getAndConSql(sql, ISHYF, " NOT EXISTS (select 1 from ch_fee WHERE B.BSNO=ch_fee.BSNO AND ch_fee.FEENAME='海运费') ");
|
|
// }
|
|
|
|
return sql;
|
|
},
|
|
|
|
|
|
|
|
checkSearchCondition: function () {
|
|
var form = this.formSearch.getForm();
|
|
if (!form.isValid()) {
|
|
Ext.Msg.alert('提示', '查询条件赋值错误,请检查。');
|
|
return false;
|
|
}
|
|
|
|
return true;
|
|
},
|
|
|
|
onClearSql: function () {
|
|
var form = this.formSearch.getForm();
|
|
form.reset();
|
|
},
|
|
OprationSwap: function () {
|
|
var ret = new Array();
|
|
ret[0] = this.OprationStatus;
|
|
ret[1] = this.storeList;
|
|
ret[2] = this.SelectedRecord;
|
|
ret[3] = this.SelectedRecord.data.BSNO;
|
|
ret[4] = "MsRptOpProfitIndex";
|
|
|
|
return ret;
|
|
},
|
|
|
|
|
|
onSaveGridClick: function (button, event) {
|
|
//if (this.tabpanel.getActiveTab() == this.panelBodyChFee) {
|
|
this.girdcolums = DsTruck.SaveGridPanel(USERID, this.formname + 'bs', this.gridList.columns, this.girdcolums, 1, true);
|
|
//} else if (this.tabpanel.getActiveTab() == this.panelSaleSum) {
|
|
// this.girdcolumssale = DsTruck.SaveGridPanel(USERID, this.formname + 'sale', this.gridListSale.columns, this.girdcolumssale, 1, true);
|
|
//} else if (this.tabpanel.getActiveTab() == this.panelCustSum) {
|
|
// this.girdcolumscust = DsTruck.SaveGridPanel(USERID, this.formname + 'cust', this.gridListCust.columns, this.girdcolumscust, 1, true);
|
|
//} else if (this.tabpanel.getActiveTab() == this.panelDeptSum) {
|
|
// this.girdcolumsdept = DsTruck.SaveGridPanel(USERID, this.formname + 'dept', this.gridListDept.columns, this.girdcolumsdept, 1, true);
|
|
//} else if (this.tabpanel.getActiveTab() == this.panelOpSum) {
|
|
// this.girdcolumsop = DsTruck.SaveGridPanel(USERID, this.formname + 'op', this.gridListOp.columns, this.girdcolumsop, 1, true);
|
|
//} else if (this.tabpanel.getActiveTab() == this.panelBsSourceSum) {
|
|
// this.girdcolumsbssource = DsTruck.SaveGridPanel(USERID, this.formname + 'bssource', this.gridListBsSource.columns, this.girdcolumsbssource, 1, true);
|
|
//} else if (this.tabpanel.getActiveTab() == this.panelBsSourceDetailSum) {
|
|
// this.girdcolumsbssourcedetail = DsTruck.SaveGridPanel(USERID, this.formname + 'bssourcedetail', this.gridListBsSourceDetail.columns, this.girdcolumsbssourcedetail, 1, true);
|
|
//} else if (this.tabpanel.getActiveTab() == this.panelLaneSum) {
|
|
// this.girdcolumslane = DsTruck.SaveGridPanel(USERID, this.formname + 'lane', this.gridListLane.columns, this.girdcolumslane, 1, true);
|
|
//} else if (this.tabpanel.getActiveTab() == this.panelDestinationSum) {
|
|
// this.girdcolumsdestination = DsTruck.SaveGridPanel(USERID, this.formname + 'destination', this.gridListDestination.columns, this.girdcolumsdestination, 1, true);
|
|
//} else if (this.tabpanel.getActiveTab() == this.panelCarrierSum) {
|
|
// this.girdcolumscarrier = DsTruck.SaveGridPanel(USERID, this.formname + 'carrier', this.gridListCarrier.columns, this.girdcolumscarrier, 1, true);
|
|
//}
|
|
this.gridlistsumcolumn = DsTruck.SaveGridPanel(USERID, this.formname + 'sum', this.gridListSum.columns, this.gridlistsumcolumn, 1, true);
|
|
|
|
},
|
|
oninitGridClick: function (button, event) {
|
|
//if (this.tabpanel.getActiveTab() == this.panelBodyChFee) {
|
|
var agirdcolums = this.initgirdcolums;
|
|
this.gridList.reconfigure(this.storeList, agirdcolums);
|
|
this.girdcolums = DsTruck.SaveGridPanel(USERID, this.formname + 'bs', this.gridList.columns, this.initgirdcolums, 1, true);
|
|
this.gridListSum.reconfigure(this.storeSumList, this.initgridlistsumcolumn);
|
|
this.gridlistsumcolumn = DsTruck.SaveGridPanel(USERID, this.formname + 'bssourcedetail', this.gridListSum.columns, this.initgridlistsumcolumn, 1, true);
|
|
//} else if (this.tabpanel.getActiveTab() == this.panelSaleSum) {
|
|
// this.gridListSale.reconfigure(this.storeSaleList, this.initgirdcolumssale);
|
|
// this.girdcolumssale = DsTruck.SaveGridPanel(USERID, this.formname + 'sale', this.gridListSale.columns, this.initgirdcolumssale, 1, true);
|
|
//} else if (this.tabpanel.getActiveTab() == this.panelCustSum) {
|
|
// this.gridListCust.reconfigure(this.storeCustList, this.initgirdcolumscust);
|
|
// this.girdcolumscust = DsTruck.SaveGridPanel(USERID, this.formname + 'cust', this.gridListCust.columns, this.initgirdcolumscust, 1, true);
|
|
//} else if (this.tabpanel.getActiveTab() == this.panelDeptSum) {
|
|
// this.gridListDept.reconfigure(this.storeDeptList, this.initgirdcolumsdept);
|
|
// this.girdcolumsdept = DsTruck.SaveGridPanel(USERID, this.formname + 'dept', this.gridListDept.columns, this.initgirdcolumsdept, 1, true);
|
|
//} else if (this.tabpanel.getActiveTab() == this.panelOpSum) {
|
|
// this.gridListOp.reconfigure(this.storeOpList, this.initgirdcolumsop);
|
|
// this.girdcolumsop = DsTruck.SaveGridPanel(USERID, this.formname + 'op', this.gridListOp.columns, this.initgirdcolumsop, 1, true);
|
|
//} else if (this.tabpanel.getActiveTab() == this.panelBsSourceSum) {
|
|
// this.gridListBsSource.reconfigure(this.storeBsSourceList, this.initgirdcolumsbssource);
|
|
// this.girdcolumsbssource = DsTruck.SaveGridPanel(USERID, this.formname + 'bssource', this.gridListBsSource.columns, this.initgirdcolumsbssource, 1, true);
|
|
//} else if (this.tabpanel.getActiveTab() == this.panelBsSourceDetailSum) {
|
|
// this.gridListBsSourceDetail.reconfigure(this.storeBsSourceDetailList, this.initgirdcolumsbssourcedetail);
|
|
// this.girdcolumsbssourcedetail = DsTruck.SaveGridPanel(USERID, this.formname + 'bssourcedetail', this.gridListBsSourceDetail.columns, this.initgirdcolumsbssourcedetail, 1, true);
|
|
//}else if (this.tabpanel.getActiveTab() == this.panelLaneSum) {
|
|
// this.gridListLane.reconfigure(this.storeLaneList, this.initgirdcolumslane);
|
|
// this.girdcolumslane = DsTruck.SaveGridPanel(USERID, this.formname + 'lane', this.gridListLane.columns, this.initgirdcolumslane, 1, true);
|
|
//} else if (this.tabpanel.getActiveTab() == this.panelDestinationSum) {
|
|
// this.gridListDestination.reconfigure(this.storeDestinationList, this.initgirdcolumsdestination);
|
|
// this.girdcolumsdestination = DsTruck.SaveGridPanel(USERID, this.formname + 'destination', this.gridListDestination.columns, this.initgirdcolumsdestination, 1, true);
|
|
//} else if (this.tabpanel.getActiveTab() == this.panelCarrierSum) {
|
|
// this.gridListCarrier.reconfigure(this.storeCarrierList, this.initgirdcolumscarrier);
|
|
// this.girdcolumscarrier = DsTruck.SaveGridPanel(USERID, this.formname + 'carrier', this.gridListCarrier.columns, this.initgirdcolumscarrier, 1, true);
|
|
//}
|
|
|
|
},
|
|
|
|
onExportClick: function (button, event) {
|
|
//if (this.tabpanel.getActiveTab() == this.panelBodyChFee) {
|
|
grid2Excel(this.gridList, "业务列表");
|
|
//} else if (this.tabpanel.getActiveTab() == this.panelSaleSum) {
|
|
// grid2Excel(this.gridListSale, "业务员列表");
|
|
|
|
//} else if (this.tabpanel.getActiveTab() == this.panelDeptSum) {
|
|
// grid2Excel(this.gridListDept, "部门列表");
|
|
|
|
//} else if (this.tabpanel.getActiveTab() == this.panelCustSum) {
|
|
// grid2Excel(this.gridListCust, "客户列表");
|
|
|
|
//} else if (this.tabpanel.getActiveTab() == this.panelOpSum) {
|
|
// grid2Excel(this.gridListOp, "操作列表");
|
|
|
|
//} else if (this.tabpanel.getActiveTab() == this.panelBsSourceSum) {
|
|
// grid2Excel(this.gridListBsSource, "业务来源列表");
|
|
|
|
//} else if (this.tabpanel.getActiveTab() == this.panelBsSourceDetailSum) {
|
|
// grid2Excel(this.gridListBsSourceDetail, "来源明细列表");
|
|
|
|
|
|
//} else if (this.tabpanel.getActiveTab() == this.panelLaneSum) {
|
|
// grid2Excel(this.gridListLane, "航线列表");
|
|
|
|
|
|
//} else if (this.tabpanel.getActiveTab() == this.panelDestinationSum) {
|
|
// grid2Excel(this.gridListDestination, "目的港列表");
|
|
|
|
|
|
//} else if (this.tabpanel.getActiveTab() == this.panelCarrierSum) {
|
|
// grid2Excel(this.gridListCarrier, "船公司");
|
|
|
|
//}
|
|
}
|
|
,
|
|
|
|
|
|
|
|
Print: function () {
|
|
|
|
_this = this;
|
|
if (this.tabpanel.getActiveTab() == this.panelBodyChFee) {
|
|
|
|
if (this.storeList.getCount() == 0) {
|
|
return;
|
|
}
|
|
|
|
var sortstr = ' B.CUSTOMERNAME,B.OPLB,B.CREATETIME DESC';
|
|
|
|
if (this.bslistsortfield != '' && this.bslistsortdire != '') {
|
|
|
|
sortstr = this.bslistsortfield + ' ' + this.bslistsortdire;
|
|
}
|
|
|
|
|
|
Ext.Msg.wait('正在组织数据, 请稍侯..');
|
|
Ext.Ajax.request({
|
|
waitMsg: '正在组织数据...',
|
|
url: '/MvcShipping/MsRptOpBsList/OpXsListData',
|
|
scope: this,
|
|
params: {
|
|
start: 0, limit: this.PageSize,
|
|
condition: _this.sqlcontext,
|
|
printstr: 'true',
|
|
sortstr: sortstr
|
|
},
|
|
callback: function (options, success, response) {
|
|
if (success) {
|
|
Ext.MessageBox.hide();
|
|
var jsonresult = Ext.JSON.decode(response.responseText);
|
|
if (jsonresult.Success) {
|
|
var returnstr = jsonresult.Data;
|
|
var condition = jsonresult.Message;
|
|
if (condition != '') condition = ' where ' + condition;
|
|
var printType = 'MSRPTBSLIST';
|
|
var sql1 = returnstr;
|
|
var sql2 = "";
|
|
var sql3 = "select CUSTOMERNAME,COUNT(BSNO) BLCOUNT,SUM(TEU) TEU from V_OP_BILL where BSNO IN (SELECT distinct B.BSNO FROM V_OP_BILL B LEFT JOIN v_op_gain_sum_INV G ON (G.BSNO=B.BSNO) " + condition + ") group by CUSTOMERNAME";
|
|
var sql4 = "select CARRIER,COUNT(BSNO) BLCOUNT,SUM(TEU) TEU from V_OP_BILL where BSNO IN (SELECT distinct B.BSNO FROM V_OP_BILL B LEFT JOIN v_op_gain_sum_INV G ON (G.BSNO=B.BSNO) " + condition + ") group by CARRIER";
|
|
var sql5 = "select OP,COUNT(BSNO) BLCOUNT,SUM(TEU) TEU from V_OP_BILL where BSNO IN (SELECT distinct B.BSNO FROM V_OP_BILL B LEFT JOIN v_op_gain_sum_INV G ON (G.BSNO=B.BSNO) " + condition + ") group by OP";
|
|
var sql6 = "select COUNT(BSNO) BLCOUNT,SUM(TEU) TEU from V_OP_BILL where BSNO IN (SELECT distinct B.BSNO FROM V_OP_BILL B LEFT JOIN v_op_gain_sum_INV G ON (G.BSNO=B.BSNO) " + condition + ") ";
|
|
|
|
PrintComm(printType, sql1, sql2, sql3, sql4, sql5, sql6);
|
|
|
|
} else {
|
|
Ext.Msg.show({ title: '错误', msg: jsonresult.Message, icon: Ext.Msg.ERROR, buttons: Ext.Msg.OK });
|
|
}
|
|
} else {
|
|
Ext.Msg.show({ title: '请重试',
|
|
msg: '服务器响应出错',
|
|
icon: Ext.Msg.ERROR, buttons: Ext.Msg.OK
|
|
});
|
|
}
|
|
}
|
|
});
|
|
} else if (this.tabpanel.activeTab == this.panelSaleSum) {
|
|
|
|
|
|
|
|
if (this.storeSaleList.getCount() == 0) {
|
|
return;
|
|
}
|
|
var sortstr = '';
|
|
|
|
if (this.salelistsortfield != '' && this.salelistsortdire != '') {
|
|
|
|
sortstr = this.salelistsortfield + ' ' + this.salelistsortdire;
|
|
}
|
|
|
|
Ext.Msg.wait('正在组织数据, 请稍侯..');
|
|
Ext.Ajax.request({
|
|
waitMsg: '正在组织数据...',
|
|
url: '/MvcShipping/MsRptOpBsList/SaleListData',
|
|
scope: this,
|
|
params: {
|
|
start: 0, limit: this.PageSize,
|
|
condition: _this.sqlcontext,
|
|
printstr: 'true',
|
|
sortstr: sortstr
|
|
},
|
|
callback: function (options, success, response) {
|
|
if (success) {
|
|
Ext.MessageBox.hide();
|
|
var jsonresult = Ext.JSON.decode(response.responseText);
|
|
if (jsonresult.Success) {
|
|
var returnstr = jsonresult.Data;
|
|
var printType = 'MSRPTBSLISTSALE';
|
|
var sql1 = returnstr;
|
|
var sql2 = "";
|
|
var sql3 = "";
|
|
var sql4 = "";
|
|
var sql5 = "";
|
|
var sql6 = "";
|
|
|
|
PrintComm(printType, sql1, sql2, sql3, sql4, sql5, sql6);
|
|
|
|
} else {
|
|
Ext.Msg.show({ title: '错误', msg: jsonresult.Message, icon: Ext.Msg.ERROR, buttons: Ext.Msg.OK });
|
|
}
|
|
} else {
|
|
Ext.Msg.show({ title: '请重试',
|
|
msg: '服务器响应出错',
|
|
icon: Ext.Msg.ERROR, buttons: Ext.Msg.OK
|
|
});
|
|
}
|
|
}
|
|
});
|
|
|
|
|
|
} else if (this.tabpanel.activeTab == this.panelCustSum) {
|
|
|
|
|
|
|
|
if (this.storeCustList.getCount() == 0) {
|
|
return;
|
|
}
|
|
var sortstr = ' B.CUSTOMERNAME';
|
|
|
|
if (this.custlistsortfield != '' && this.custlistsortdire != '') {
|
|
|
|
sortstr = this.custlistsortfield + ' ' + this.custlistsortdire;
|
|
}
|
|
|
|
Ext.Msg.wait('正在组织数据, 请稍侯..');
|
|
Ext.Ajax.request({
|
|
waitMsg: '正在组织数据...',
|
|
url: '/MvcShipping/MsRptOpBsList/CustListData',
|
|
scope: this,
|
|
params: {
|
|
start: 0, limit: this.PageSize,
|
|
condition: _this.sqlcontext,
|
|
printstr: 'true',
|
|
sortstr: sortstr
|
|
},
|
|
callback: function (options, success, response) {
|
|
if (success) {
|
|
Ext.MessageBox.hide();
|
|
var jsonresult = Ext.JSON.decode(response.responseText);
|
|
if (jsonresult.Success) {
|
|
var returnstr = jsonresult.Data;
|
|
var printType = 'MSRPTBSLISTCUST';
|
|
var sql1 = returnstr;
|
|
var sql2 = "";
|
|
var sql3 = "";
|
|
var sql4 = "";
|
|
var sql5 = "";
|
|
var sql6 = "";
|
|
|
|
PrintComm(printType, sql1, sql2, sql3, sql4, sql5, sql6);
|
|
|
|
} else {
|
|
Ext.Msg.show({ title: '错误', msg: jsonresult.Message, icon: Ext.Msg.ERROR, buttons: Ext.Msg.OK });
|
|
}
|
|
} else {
|
|
Ext.Msg.show({ title: '请重试',
|
|
msg: '服务器响应出错',
|
|
icon: Ext.Msg.ERROR, buttons: Ext.Msg.OK
|
|
});
|
|
}
|
|
}
|
|
});
|
|
} else if (this.tabpanel.activeTab == this.panelDeptSum) {
|
|
|
|
|
|
|
|
if (this.storeDeptList.getCount() == 0) {
|
|
return;
|
|
}
|
|
var sortstr = ' B.SALEDEPT';
|
|
|
|
if (this.deptlistsortfield != '' && this.deptlistsortdire != '') {
|
|
|
|
sortstr = this.deptlistsortfield + ' ' + this.deptlistsortdire;
|
|
}
|
|
|
|
Ext.Msg.wait('正在组织数据, 请稍侯..');
|
|
Ext.Ajax.request({
|
|
waitMsg: '正在组织数据...',
|
|
url: '/MvcShipping/MsRptOpBsList/DeptListData',
|
|
scope: this,
|
|
params: {
|
|
start: 0, limit: this.PageSize,
|
|
condition: _this.sqlcontext,
|
|
printstr: 'true',
|
|
sortstr: sortstr
|
|
},
|
|
callback: function (options, success, response) {
|
|
if (success) {
|
|
Ext.MessageBox.hide();
|
|
var jsonresult = Ext.JSON.decode(response.responseText);
|
|
if (jsonresult.Success) {
|
|
var returnstr = jsonresult.Data;
|
|
var printType = 'MSRPTBSLISTDEPT';
|
|
var sql1 = returnstr;
|
|
var sql2 = "";
|
|
var sql3 = "";
|
|
var sql4 = "";
|
|
var sql5 = "";
|
|
var sql6 = "";
|
|
|
|
PrintComm(printType, sql1, sql2, sql3, sql4, sql5, sql6);
|
|
|
|
} else {
|
|
Ext.Msg.show({ title: '错误', msg: jsonresult.Message, icon: Ext.Msg.ERROR, buttons: Ext.Msg.OK });
|
|
}
|
|
} else {
|
|
Ext.Msg.show({ title: '请重试',
|
|
msg: '服务器响应出错',
|
|
icon: Ext.Msg.ERROR, buttons: Ext.Msg.OK
|
|
});
|
|
}
|
|
}
|
|
});
|
|
|
|
|
|
} else if (this.tabpanel.activeTab == this.panelOpSum) {
|
|
|
|
if (this.storeOpList.getCount() == 0) {
|
|
return;
|
|
}
|
|
var sortstr = ' B.OP, B.BSTYPE';
|
|
|
|
if (this.oplistsortfield != '' && this.oplistsortdire != '') {
|
|
|
|
sortstr = this.oplistsortfield + ' ' + this.oplistsortdire;
|
|
}
|
|
|
|
Ext.Msg.wait('正在组织数据, 请稍侯..');
|
|
Ext.Ajax.request({
|
|
waitMsg: '正在组织数据...',
|
|
url: '/MvcShipping/MsRptOpBsList/OpListData',
|
|
scope: this,
|
|
params: {
|
|
start: 0, limit: this.PageSize,
|
|
condition: _this.sqlcontext,
|
|
printstr: 'true',
|
|
sortstr: sortstr
|
|
},
|
|
callback: function (options, success, response) {
|
|
if (success) {
|
|
Ext.MessageBox.hide();
|
|
var jsonresult = Ext.JSON.decode(response.responseText);
|
|
if (jsonresult.Success) {
|
|
var returnstr = jsonresult.Data;
|
|
var printType = 'MSRPTBSLISTOP';
|
|
var sql1 = returnstr;
|
|
var sql2 = "";
|
|
var sql3 = "";
|
|
var sql4 = "";
|
|
var sql5 = "";
|
|
var sql6 = "";
|
|
|
|
PrintComm(printType, sql1, sql2, sql3, sql4, sql5, sql6);
|
|
|
|
} else {
|
|
Ext.Msg.show({ title: '错误', msg: jsonresult.Message, icon: Ext.Msg.ERROR, buttons: Ext.Msg.OK });
|
|
}
|
|
} else {
|
|
Ext.Msg.show({ title: '请重试',
|
|
msg: '服务器响应出错',
|
|
icon: Ext.Msg.ERROR, buttons: Ext.Msg.OK
|
|
});
|
|
}
|
|
}
|
|
});
|
|
} else if (this.tabpanel.activeTab == this.panelBsSourceSum) {
|
|
|
|
if (this.storeBsSourceList.getCount() == 0) {
|
|
return;
|
|
}
|
|
var sortstr = ' B.BSSOURCE, B.BSTYPE';
|
|
|
|
if (this.bssourcelistsortfield != '' && this.bssourcelistsortdire != '') {
|
|
|
|
sortstr = this.bssourcelistsortfield + ' ' + this.bssourcelistsortdire;
|
|
}
|
|
Ext.Msg.wait('正在组织数据, 请稍侯..');
|
|
Ext.Ajax.request({
|
|
waitMsg: '正在组织数据...',
|
|
url: '/MvcShipping/MsRptOpBsList/BsSourceListData',
|
|
scope: this,
|
|
params: {
|
|
start: 0, limit: this.PageSize,
|
|
condition: _this.sqlcontext,
|
|
printstr: 'true',
|
|
sortstr: sortstr
|
|
},
|
|
callback: function (options, success, response) {
|
|
if (success) {
|
|
Ext.MessageBox.hide();
|
|
var jsonresult = Ext.JSON.decode(response.responseText);
|
|
if (jsonresult.Success) {
|
|
var returnstr = jsonresult.Data;
|
|
var printType = 'MSRPTBSLISTBSOURCE';
|
|
var sql1 = returnstr;
|
|
var sql2 = "";
|
|
var sql3 = "";
|
|
var sql4 = "";
|
|
var sql5 = "";
|
|
var sql6 = "";
|
|
|
|
PrintComm(printType, sql1, sql2, sql3, sql4, sql5, sql6);
|
|
|
|
} else {
|
|
Ext.Msg.show({ title: '错误', msg: jsonresult.Message, icon: Ext.Msg.ERROR, buttons: Ext.Msg.OK });
|
|
}
|
|
} else {
|
|
Ext.Msg.show({ title: '请重试',
|
|
msg: '服务器响应出错',
|
|
icon: Ext.Msg.ERROR, buttons: Ext.Msg.OK
|
|
});
|
|
}
|
|
}
|
|
});
|
|
} else if (this.tabpanel.activeTab == this.panelBsSourceDetailSum) {
|
|
|
|
if (this.storeBsSourceDetailList.getCount() == 0) {
|
|
return;
|
|
}
|
|
var sortstr = ' B.BSSOURCE,B.BSSOURCEDETAIL, B.BSTYPE';
|
|
|
|
if (this.bssourcelistdetailsortfield != '' && this.bssourcelistdetailsortdire != '') {
|
|
|
|
sortstr = this.bssourcelistdetailsortfield + ' ' + this.bssourcelistdetailsortdire;
|
|
}
|
|
|
|
Ext.Msg.wait('正在组织数据, 请稍侯..');
|
|
Ext.Ajax.request({
|
|
waitMsg: '正在组织数据...',
|
|
url: '/MvcShipping/MsRptOpBsList/BsSourceDetailListData',
|
|
scope: this,
|
|
params: {
|
|
start: 0, limit: this.PageSize,
|
|
condition: _this.sqlcontext,
|
|
printstr: 'true',
|
|
sortstr: sortstr
|
|
},
|
|
callback: function (options, success, response) {
|
|
if (success) {
|
|
Ext.MessageBox.hide();
|
|
var jsonresult = Ext.JSON.decode(response.responseText);
|
|
if (jsonresult.Success) {
|
|
var returnstr = jsonresult.Data;
|
|
var printType = 'MSRPTBSLISTBSSOURCEDETAIL';
|
|
var sql1 = returnstr;
|
|
var sql2 = "";
|
|
var sql3 = "";
|
|
var sql4 = "";
|
|
var sql5 = "";
|
|
var sql6 = "";
|
|
|
|
PrintComm(printType, sql1, sql2, sql3, sql4, sql5, sql6);
|
|
|
|
} else {
|
|
Ext.Msg.show({ title: '错误', msg: jsonresult.Message, icon: Ext.Msg.ERROR, buttons: Ext.Msg.OK });
|
|
}
|
|
} else {
|
|
Ext.Msg.show({ title: '请重试',
|
|
msg: '服务器响应出错',
|
|
icon: Ext.Msg.ERROR, buttons: Ext.Msg.OK
|
|
});
|
|
}
|
|
}
|
|
});
|
|
} else if (this.tabpanel.activeTab == this.panelLaneSum) {
|
|
|
|
if (this.storeLaneList.getCount() == 0) {
|
|
return;
|
|
}
|
|
var sortstr = ' B.LANE';
|
|
|
|
if (this.lanelistsortfield != '' && this.lanelistsortdire != '') {
|
|
|
|
sortstr = this.lanesortfield + ' ' + this.lanesortdire;
|
|
}
|
|
|
|
Ext.Msg.wait('正在组织数据, 请稍侯..');
|
|
Ext.Ajax.request({
|
|
waitMsg: '正在组织数据...',
|
|
url: '/MvcShipping/MsRptOpBsList/LaneListData',
|
|
scope: this,
|
|
params: {
|
|
start: 0, limit: this.PageSize,
|
|
condition: _this.sqlcontext,
|
|
printstr: 'true',
|
|
sortstr: sortstr
|
|
},
|
|
callback: function (options, success, response) {
|
|
if (success) {
|
|
Ext.MessageBox.hide();
|
|
var jsonresult = Ext.JSON.decode(response.responseText);
|
|
if (jsonresult.Success) {
|
|
var returnstr = jsonresult.Data;
|
|
var printType = 'MSRPTBSLISTLANE';
|
|
var sql1 = returnstr;
|
|
var sql2 = "";
|
|
var sql3 = "";
|
|
var sql4 = "";
|
|
var sql5 = "";
|
|
var sql6 = "";
|
|
|
|
PrintComm(printType, sql1, sql2, sql3, sql4, sql5, sql6);
|
|
|
|
} else {
|
|
Ext.Msg.show({ title: '错误', msg: jsonresult.Message, icon: Ext.Msg.ERROR, buttons: Ext.Msg.OK });
|
|
}
|
|
} else {
|
|
Ext.Msg.show({ title: '请重试',
|
|
msg: '服务器响应出错',
|
|
icon: Ext.Msg.ERROR, buttons: Ext.Msg.OK
|
|
});
|
|
}
|
|
}
|
|
});
|
|
} else if (this.tabpanel.activeTab == this.panelDestinationSum) {
|
|
|
|
if (this.storeDestinationList.getCount() == 0) {
|
|
return;
|
|
}
|
|
var sortstr = ' B.DESTINATIONID';
|
|
|
|
if (this.destinationlistsortfield != '' && this.destinationlistsortdire != '') {
|
|
|
|
sortstr = this.destinationsortfield + ' ' + this.destinationsortdire;
|
|
}
|
|
|
|
Ext.Msg.wait('正在组织数据, 请稍侯..');
|
|
Ext.Ajax.request({
|
|
waitMsg: '正在组织数据...',
|
|
url: '/MvcShipping/MsRptOpBsList/DestinationListData',
|
|
scope: this,
|
|
params: {
|
|
start: 0, limit: this.PageSize,
|
|
condition: _this.sqlcontext,
|
|
printstr: 'true',
|
|
sortstr: sortstr
|
|
},
|
|
callback: function (options, success, response) {
|
|
if (success) {
|
|
Ext.MessageBox.hide();
|
|
var jsonresult = Ext.JSON.decode(response.responseText);
|
|
if (jsonresult.Success) {
|
|
var returnstr = jsonresult.Data;
|
|
var printType = 'MSRPTBSLISTLANE';
|
|
var sql1 = returnstr;
|
|
var sql2 = "";
|
|
var sql3 = "";
|
|
var sql4 = "";
|
|
var sql5 = "";
|
|
var sql6 = "";
|
|
|
|
PrintComm(printType, sql1, sql2, sql3, sql4, sql5, sql6);
|
|
|
|
} else {
|
|
Ext.Msg.show({ title: '错误', msg: jsonresult.Message, icon: Ext.Msg.ERROR, buttons: Ext.Msg.OK });
|
|
}
|
|
} else {
|
|
Ext.Msg.show({ title: '请重试',
|
|
msg: '服务器响应出错',
|
|
icon: Ext.Msg.ERROR, buttons: Ext.Msg.OK
|
|
});
|
|
}
|
|
}
|
|
});
|
|
} else if (this.tabpanel.activeTab == this.panelCarrierSum) {
|
|
|
|
|
|
|
|
if (this.storeCarrierList.getCount() == 0) {
|
|
return;
|
|
}
|
|
var sortstr = ' B.CARRIER';
|
|
|
|
if (this.carrierlistsortfield != '' && this.carrierlistsortdire != '') {
|
|
|
|
sortstr = this.carrierlistsortfield + ' ' + this.carrierlistsortdire;
|
|
}
|
|
|
|
Ext.Msg.wait('正在组织数据, 请稍侯..');
|
|
Ext.Ajax.request({
|
|
waitMsg: '正在组织数据...',
|
|
url: '/MvcShipping/MsRptOpBsList/CarrierListData',
|
|
scope: this,
|
|
params: {
|
|
start: 0, limit: this.PageSize,
|
|
condition: _this.sqlcontext,
|
|
printstr: 'true',
|
|
sortstr: sortstr
|
|
},
|
|
callback: function (options, success, response) {
|
|
if (success) {
|
|
Ext.MessageBox.hide();
|
|
var jsonresult = Ext.JSON.decode(response.responseText);
|
|
if (jsonresult.Success) {
|
|
var returnstr = jsonresult.Data;
|
|
var printType = 'MSRPTBSLISTCARRIER';
|
|
var sql1 = returnstr;
|
|
var sql2 = "";
|
|
var sql3 = "";
|
|
var sql4 = "";
|
|
var sql5 = "";
|
|
var sql6 = "";
|
|
|
|
PrintComm(printType, sql1, sql2, sql3, sql4, sql5, sql6);
|
|
|
|
} else {
|
|
Ext.Msg.show({ title: '错误', msg: jsonresult.Message, icon: Ext.Msg.ERROR, buttons: Ext.Msg.OK });
|
|
}
|
|
} else {
|
|
Ext.Msg.show({ title: '请重试',
|
|
msg: '服务器响应出错',
|
|
icon: Ext.Msg.ERROR, buttons: Ext.Msg.OK
|
|
});
|
|
}
|
|
}
|
|
});
|
|
}
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
});
|
|
|
|
|