|
|
Ext.namespace('Shipping');
|
|
|
|
|
|
Shipping.MsOpSeaiIndex = function (config) {
|
|
|
Ext.applyIf(this, config);
|
|
|
this.initUIComponents();
|
|
|
window.Shipping.MsOpSeaiIndex.superclass.constructor.call(this);
|
|
|
};
|
|
|
|
|
|
Ext.extend(Shipping.MsOpSeaiIndex, Ext.Panel, {
|
|
|
PageSize: 50,
|
|
|
OprationStatus: null, //仅当弹出界面时使用
|
|
|
SelectedRecord: null,
|
|
|
isShowAdvancedQuery: 0, //是否显示高级查询面板
|
|
|
sqlcontext: '',
|
|
|
selectbsno: '',
|
|
|
sortfield: '',
|
|
|
sortdire: '',
|
|
|
bsno: '',
|
|
|
id: "MainSeaiPanel",
|
|
|
initUIComponents: function () {
|
|
|
this.formname = "formMsOpSeaiIndex"; //页面名称
|
|
|
this.PluginCover = new Shipping.OpSeaCover({ region: "center" }, 0);
|
|
|
this.bsno = '';
|
|
|
this.USEDSINTERFACE = 0;
|
|
|
|
|
|
//#region 定义数据集
|
|
|
this.storePLList = Ext.create('Ext.data.Store', {
|
|
|
model: 'MsOpSeaiModel'
|
|
|
});
|
|
|
|
|
|
this.storectndisp = Ext.create('DsExt.ux.RefTableStore', {
|
|
|
model: 'DsShipping.ux.CtnDispModel',
|
|
|
proxy: { url: '/CommMng/BasicDataRef/GetCtnDisp' }
|
|
|
});
|
|
|
|
|
|
this.storecodeservice = Ext.create('DsExt.ux.RefTableStore', {
|
|
|
model: 'MsCodeOpService',
|
|
|
proxy: { url: '/MvcShipping/MsCodeOpService/GetDataCtnList' }
|
|
|
});
|
|
|
|
|
|
|
|
|
this.storeINSPECTSERVICE = Ext.create('DsExt.ux.RefEnumStore', {});
|
|
|
this.storeINSPECTSERVICE.load({ params: { enumTypeId: 97024 } });
|
|
|
|
|
|
this.storeList = Ext.create('Ext.data.Store', {
|
|
|
pageSize: this.PageSize,
|
|
|
model: 'MsOpSeaiModel',
|
|
|
remoteSort: true,
|
|
|
proxy: {
|
|
|
type: 'ajax',
|
|
|
url: '/MvcShipping/MsOpSeai/GetDataList',
|
|
|
reader: {
|
|
|
id: 'BSNO',
|
|
|
root: 'data',
|
|
|
totalProperty: 'totalCount'
|
|
|
}
|
|
|
}
|
|
|
});
|
|
|
//#endregion
|
|
|
|
|
|
//#region List列表显示信息
|
|
|
Ext.grid.RowNumberer = Ext.extend(Ext.grid.RowNumberer, {
|
|
|
width: 30
|
|
|
});
|
|
|
|
|
|
this.initgirdcolums = [{
|
|
|
sortable: true,
|
|
|
dataIndex: 'BSNO',
|
|
|
header: Zi.LAN.BSNO2, //'业务编号',
|
|
|
width: 0
|
|
|
},
|
|
|
{
|
|
|
sortable: true,
|
|
|
dataIndex: 'BSSTATUSREF',
|
|
|
align: 'center',
|
|
|
header: Zi.LAN.BSSTATUSREF, //'业务锁定',
|
|
|
width: 60,
|
|
|
renderer: function (value, cellmeta) {
|
|
|
if (value == '锁定') {
|
|
|
return "<img src='../../../../TruckMng/Content/Images/Lock.png' />";
|
|
|
}
|
|
|
}
|
|
|
},
|
|
|
{
|
|
|
sortable: true,
|
|
|
dataIndex: 'FEESTATUSREF',
|
|
|
align: 'center',
|
|
|
header: Zi.LAN.FEESTATUSREF, //'费用锁定',
|
|
|
width: 60,
|
|
|
renderer: function (value, cellmeta) {
|
|
|
if (value == '锁定') {
|
|
|
return "<img src='../../../../TruckMng/Content/Images/Lock.png' />";
|
|
|
}
|
|
|
}
|
|
|
},
|
|
|
{
|
|
|
sortable: true,
|
|
|
id: '',
|
|
|
dataIndex: 'DRFEESTATUS',
|
|
|
header: Zi.LAN.DRFEESTATUS, //'应收费用',
|
|
|
align: 'center',
|
|
|
width: 60,
|
|
|
renderer: function (value, meta) {
|
|
|
|
|
|
if (value == '审核通过') {
|
|
|
meta.tdCls = 'feestatus_pass';
|
|
|
} else if (value == '录入状态') {
|
|
|
|
|
|
} else if (value == '提交审核') {
|
|
|
meta.tdCls = 'feestatus_refer';
|
|
|
} else if (value == '部分结算') {
|
|
|
meta.tdCls = 'feestatus_refer';
|
|
|
} else if (value == '结算完毕') {
|
|
|
meta.tdCls = 'feestatus_settle';
|
|
|
} else if (value == '未录入') {
|
|
|
} else if (value == '部分结算') {
|
|
|
meta.tdCls = 'feestatus_settle';
|
|
|
} else if (value == '部分审核') {
|
|
|
meta.tdCls = 'feestatus_pass';
|
|
|
} else if (value == '部分提交') {
|
|
|
meta.tdCls = 'feestatus_refer';
|
|
|
} else if (value == '驳回提交') {
|
|
|
meta.tdCls = 'feestatus_nopass';
|
|
|
}
|
|
|
return value;
|
|
|
}
|
|
|
},
|
|
|
{
|
|
|
sortable: true,
|
|
|
id: '',
|
|
|
dataIndex: 'CRFEESTATUS',
|
|
|
header: Zi.LAN.CRFEESTATUS, //'应付费用',
|
|
|
align: 'center',
|
|
|
width: 60,
|
|
|
renderer: function (value, meta) {
|
|
|
|
|
|
if (value == '审核通过') {
|
|
|
meta.tdCls = 'feestatus_pass';
|
|
|
} else if (value == '录入状态') {
|
|
|
|
|
|
} else if (value == '提交审核') {
|
|
|
meta.tdCls = 'feestatus_refer';
|
|
|
} else if (value == '部分结算') {
|
|
|
meta.tdCls = 'feestatus_refer';
|
|
|
} else if (value == '结算完毕') {
|
|
|
meta.tdCls = 'feestatus_settle';
|
|
|
} else if (value == '未录入') {
|
|
|
} else if (value == '部分结算') {
|
|
|
meta.tdCls = 'feestatus_settle';
|
|
|
} else if (value == '部分审核') {
|
|
|
meta.tdCls = 'feestatus_pass';
|
|
|
} else if (value == '部分提交') {
|
|
|
meta.tdCls = 'feestatus_refer';
|
|
|
} else if (value == '驳回提交') {
|
|
|
meta.tdCls = 'feestatus_nopass';
|
|
|
}
|
|
|
return value;
|
|
|
}
|
|
|
},{
|
|
|
sortable: true,
|
|
|
id: '',
|
|
|
dataIndex: 'BillFeeStatus',
|
|
|
header: '整票状态', //'整票状态',
|
|
|
width: 60,
|
|
|
renderer: function (value, meta) {
|
|
|
if (value == '0') {
|
|
|
return "未提交";
|
|
|
} else if (value == '1') {
|
|
|
meta.tdCls = 'feestatus_refer';
|
|
|
return "整票提交";
|
|
|
} else if (value == '2') {
|
|
|
meta.tdCls = 'feestatus_pass';
|
|
|
return "审核通过";
|
|
|
} else if (value == '4') {
|
|
|
meta.tdCls = 'feestatus_nopass';
|
|
|
return "整票驳回";
|
|
|
} else {
|
|
|
return "";
|
|
|
}
|
|
|
}
|
|
|
},
|
|
|
{
|
|
|
sortable: true,
|
|
|
id: '',
|
|
|
dataIndex: 'DRINVSTATUS',
|
|
|
header: Zi.LAN.DRINVSTATUS, //'应收开票',
|
|
|
align: 'center',
|
|
|
width: 60,
|
|
|
renderer: function (value, meta, record) {
|
|
|
|
|
|
var openSet = "height=200, width=650, toolbar=no, menubar=no,scrollbars=1, resizable=1,location=no, status=no,Top= " + (screen.height - 250) / 2 + ",Left= " + (screen.width - 600) / 2
|
|
|
var openType = "_blank";
|
|
|
var openUrl = "";
|
|
|
openUrl = "../../MvcShipping/MsRptChInvTotal/BsView?handle=check&bsno=" + record.data.BSNO;
|
|
|
var winstr = "window.open(this.href,'" + openType + "','" + openSet + "')";
|
|
|
if (value == '已开票') {
|
|
|
value = '<a href="' + openUrl + '" onclick="' + winstr + ';return false">已开票</a>'
|
|
|
meta.tdCls = 'feestatus_pass';
|
|
|
} else if (value == '部分开票') {
|
|
|
meta.tdCls = 'feestatus_refer';
|
|
|
value = '<a href="' + openUrl + '" onclick="' + winstr + ';return false">部分开票</a>'
|
|
|
}
|
|
|
return value;
|
|
|
}
|
|
|
},
|
|
|
{
|
|
|
sortable: true,
|
|
|
id: '',
|
|
|
dataIndex: 'DRDUISTATUS',
|
|
|
header: Zi.LAN.DRDUISTATUS, //'应收开票',
|
|
|
align: 'center',
|
|
|
// xtype: 'actioncolumn',
|
|
|
width: 60,
|
|
|
renderer: function (value, meta, record) {
|
|
|
|
|
|
if (value == '已对账') {
|
|
|
// value = '<a href="' + openUrl + '" onclick="' + winstr + ';return false">已开票</a>'
|
|
|
meta.tdCls = 'feestatus_pass';
|
|
|
} else if (value == '部分对账') {
|
|
|
meta.tdCls = 'feestatus_refer';
|
|
|
// value = '<a href="' + openUrl + '" onclick="' + winstr + ';return false">部分开票</a>'
|
|
|
}
|
|
|
return value;
|
|
|
}
|
|
|
},
|
|
|
{
|
|
|
sortable: true,
|
|
|
dataIndex: 'WMSTYPE',
|
|
|
header: Zi.LAN.WMSTYPE, //'仓储类型',
|
|
|
width: 60
|
|
|
},
|
|
|
{
|
|
|
sortable: true,
|
|
|
dataIndex: 'OPSTATUS',
|
|
|
header: Zi.LAN.OPSTATUS2, //'状态管理',
|
|
|
width: 80,
|
|
|
renderer: function (value, metadata, record, rowIndex) {
|
|
|
|
|
|
metadata.style = "background-color:" + record.data.OPSTATUSCOLOR;
|
|
|
return value;
|
|
|
}
|
|
|
},
|
|
|
{
|
|
|
sortable: true,
|
|
|
dataIndex: 'ETD',
|
|
|
header: Zi.LAN.ETD, //'到港日期',
|
|
|
width: 80
|
|
|
},
|
|
|
{
|
|
|
sortable: true,
|
|
|
dataIndex: 'ETA',
|
|
|
header: Zi.LAN.ETA, //'开船日期',
|
|
|
width: 80
|
|
|
},
|
|
|
{
|
|
|
sortable: true,
|
|
|
dataIndex: 'INVNO',
|
|
|
header: Zi.LAN.INVNO, //'开船日期',
|
|
|
width: 80
|
|
|
},
|
|
|
{
|
|
|
sortable: true,
|
|
|
dataIndex: 'MBLNO',
|
|
|
header: Zi.LAN.MBLNO, //'主提单号',
|
|
|
width: 120,
|
|
|
renderer: function (value, meta) {
|
|
|
|
|
|
meta.tdCls = 'mblno';
|
|
|
|
|
|
var btnurl = getGridCopyButton(value);
|
|
|
|
|
|
return btnurl + value;
|
|
|
}
|
|
|
},
|
|
|
{
|
|
|
sortable: true,
|
|
|
dataIndex: 'CUSTOMERNAME',
|
|
|
header: Zi.LAN.CUSTOMERNAME, //'委托单位',
|
|
|
width: 120
|
|
|
},
|
|
|
{
|
|
|
sortable: true,
|
|
|
dataIndex: 'TRADETYPE',
|
|
|
header: Zi.LAN.TRADETYPE, //'贸易方式',
|
|
|
width: 60
|
|
|
},
|
|
|
{
|
|
|
sortable: true,
|
|
|
dataIndex: 'BSDATE',
|
|
|
header: Zi.LAN.BSDATE, //'接单日期',
|
|
|
width: 80
|
|
|
},
|
|
|
{
|
|
|
sortable: true,
|
|
|
dataIndex: 'CONTRACTNO',
|
|
|
header: Zi.LAN.CONTRACTNO, //'合同号',
|
|
|
width: 120
|
|
|
},
|
|
|
{
|
|
|
sortable: true,
|
|
|
dataIndex: 'GOODSNAME',
|
|
|
header: Zi.LAN.GOODSNAME, //'品名',
|
|
|
width: 120
|
|
|
},
|
|
|
{
|
|
|
sortable: true,
|
|
|
dataIndex: 'NUMBERPLATE',
|
|
|
header: Zi.LAN.NUMBERPLATE, //'牌号',
|
|
|
width: 120
|
|
|
},
|
|
|
{
|
|
|
sortable: true,
|
|
|
dataIndex: 'PKGS',
|
|
|
header: Zi.LAN.PKGS, //'件数',
|
|
|
width: 80
|
|
|
},
|
|
|
{
|
|
|
sortable: true,
|
|
|
dataIndex: 'KGS',
|
|
|
header: Zi.LAN.KGS2, //'毛重',
|
|
|
width: 80
|
|
|
},
|
|
|
{
|
|
|
sortable: true,
|
|
|
dataIndex: 'NETWEIGHT',
|
|
|
header: Zi.LAN.NETWEIGHT, //'净重',
|
|
|
width: 80
|
|
|
},
|
|
|
{
|
|
|
sortable: true,
|
|
|
dataIndex: 'CNTRTOTAL',
|
|
|
header: Zi.LAN.CNTRTOTAL2, //'集装箱',
|
|
|
width: 80
|
|
|
},
|
|
|
{
|
|
|
sortable: true,
|
|
|
dataIndex: 'ORDERTYPE',
|
|
|
header: Zi.LAN.ORDERTYPE2, //'委托方式',
|
|
|
width: 80
|
|
|
},
|
|
|
{
|
|
|
sortable: true,
|
|
|
dataIndex: 'FORWARDER',
|
|
|
header: Zi.LAN.FORWARDER, //'委托方式',
|
|
|
width: 80
|
|
|
},
|
|
|
{
|
|
|
sortable: true,
|
|
|
dataIndex: 'CUSTNO',
|
|
|
header: Zi.LAN.CUSTNO, //'委托编号',
|
|
|
width: 120,
|
|
|
renderer: function (value, meta) {
|
|
|
|
|
|
meta.tdCls = 'mblno';
|
|
|
|
|
|
btnurl = getGridCopyButton(value);
|
|
|
|
|
|
return btnurl + value;
|
|
|
}
|
|
|
}, {
|
|
|
sortable: true,
|
|
|
id: '',
|
|
|
dataIndex: 'ORDERNO',
|
|
|
header: Zi.LAN.ORDERNO, //'业务编号',
|
|
|
width: 120
|
|
|
},
|
|
|
{
|
|
|
sortable: true,
|
|
|
dataIndex: 'HBLNO',
|
|
|
header: Zi.LAN.HBLNO, //'分提单号',
|
|
|
width: 120,
|
|
|
renderer: function (value, meta) {
|
|
|
|
|
|
meta.tdCls = 'mblno';
|
|
|
|
|
|
btnurl = getGridCopyButton(value);
|
|
|
|
|
|
return btnurl + value;
|
|
|
}
|
|
|
},
|
|
|
{
|
|
|
sortable: true,
|
|
|
dataIndex: 'ACCDATE',
|
|
|
header: Zi.LAN.ACCDATE, //'会计期间',
|
|
|
width: 60
|
|
|
},
|
|
|
{
|
|
|
sortable: true,
|
|
|
dataIndex: 'BSSOURCE',
|
|
|
header: Zi.LAN.BSSOURCE, //'业务来源',
|
|
|
width: 80
|
|
|
},
|
|
|
{
|
|
|
sortable: true,
|
|
|
dataIndex: 'BSSOURCEDETAIL',
|
|
|
header: Zi.LAN.BSSOURCEDETAIL, //'来源明细',
|
|
|
width: 80
|
|
|
},
|
|
|
{
|
|
|
sortable: true,
|
|
|
dataIndex: 'INPUTBY',
|
|
|
header: Zi.LAN.INPUTBY, //'录入人',
|
|
|
width: 80
|
|
|
},
|
|
|
{
|
|
|
sortable: true,
|
|
|
dataIndex: 'CREATETIME',
|
|
|
header: Zi.LAN.CREATETIME, //'创建时间',
|
|
|
width: 120
|
|
|
},
|
|
|
{
|
|
|
sortable: true,
|
|
|
dataIndex: 'OP',
|
|
|
header: Zi.LAN.OP, //'操作员',
|
|
|
width: 80
|
|
|
},
|
|
|
{
|
|
|
sortable: true,
|
|
|
dataIndex: 'SALE',
|
|
|
header: Zi.LAN.SALE, //'揽货人',
|
|
|
width: 80
|
|
|
},
|
|
|
{
|
|
|
sortable: true,
|
|
|
dataIndex: 'DOC',
|
|
|
header: Zi.LAN.DOC, //'揽货人',
|
|
|
width: 80
|
|
|
},
|
|
|
{
|
|
|
sortable: true,
|
|
|
dataIndex: 'VESSEL',
|
|
|
header: Zi.LAN.VESSEL, //'船名',
|
|
|
width: 100
|
|
|
},
|
|
|
{
|
|
|
sortable: true,
|
|
|
dataIndex: 'VOYNO',
|
|
|
header: Zi.LAN.VOYNO, //'航次',
|
|
|
width: 60
|
|
|
},
|
|
|
{
|
|
|
sortable: true,
|
|
|
dataIndex: 'PORTLOAD',
|
|
|
header: Zi.LAN.PORTLOAD, //'装货港',
|
|
|
width: 100
|
|
|
},
|
|
|
{
|
|
|
sortable: true,
|
|
|
dataIndex: 'PORTDISCHARGE',
|
|
|
header: Zi.LAN.PORTDISCHARGE, //'卸货港',
|
|
|
width: 100
|
|
|
},
|
|
|
{
|
|
|
sortable: true,
|
|
|
dataIndex: 'OTCNTR',
|
|
|
header: Zi.LAN.OTCNTR, //'其他箱型',
|
|
|
width: 60
|
|
|
},
|
|
|
{
|
|
|
sortable: true,
|
|
|
dataIndex: 'TEU',
|
|
|
header: Zi.LAN.TEU, //'箱TEU',
|
|
|
width: 40
|
|
|
},
|
|
|
{
|
|
|
sortable: true,
|
|
|
dataIndex: 'COUNTRYOFORIGIN',
|
|
|
header: Zi.LAN.COUNTRYOFORIGIN, //'原产地',
|
|
|
width: 80
|
|
|
},
|
|
|
{
|
|
|
sortable: true,
|
|
|
dataIndex: 'UNITS',
|
|
|
header: Zi.LAN.UNITS, //'单位',
|
|
|
width: 40
|
|
|
},
|
|
|
{
|
|
|
sortable: true,
|
|
|
dataIndex: 'BALES',
|
|
|
header: Zi.LAN.BALES2, //'包装(散货/托盘)数',
|
|
|
width: 60
|
|
|
},
|
|
|
{
|
|
|
sortable: true,
|
|
|
dataIndex: 'CUSTOMSER',
|
|
|
header: Zi.LAN.CUSTOMSER, //'报关行',
|
|
|
width: 80
|
|
|
},
|
|
|
{
|
|
|
sortable: true,
|
|
|
dataIndex: 'CUSTOMNO',
|
|
|
header: Zi.LAN.CUSTOMNO, //'报关单号',
|
|
|
width: 80
|
|
|
},
|
|
|
{
|
|
|
sortable: true,
|
|
|
dataIndex: 'CUSTOMDATE',
|
|
|
header: Zi.LAN.CUSTOMDATE, //'通关日期',
|
|
|
width: 80
|
|
|
},
|
|
|
{
|
|
|
sortable: true,
|
|
|
dataIndex: 'INSPECTION',
|
|
|
header: Zi.LAN.INSPECTION, //'报检',
|
|
|
width: 80
|
|
|
},
|
|
|
{
|
|
|
sortable: true,
|
|
|
dataIndex: 'INSPECTIONNO',
|
|
|
header: Zi.LAN.INSPECTIONNO, //'报检单号',
|
|
|
width: 80
|
|
|
},
|
|
|
{
|
|
|
sortable: true,
|
|
|
dataIndex: 'INSPECTIONDATE',
|
|
|
header: Zi.LAN.INSPECTIONDATE, //'报检日期',
|
|
|
width: 80
|
|
|
},
|
|
|
{
|
|
|
sortable: true,
|
|
|
dataIndex: 'KINDPKGS',
|
|
|
header: Zi.LAN.KINDPKGS, //'件数包装',
|
|
|
width: 60
|
|
|
},
|
|
|
{
|
|
|
sortable: true,
|
|
|
dataIndex: 'CBM',
|
|
|
header: Zi.LAN.CBM2, //'立方/尺码',
|
|
|
width: 60
|
|
|
},
|
|
|
{
|
|
|
sortable: true,
|
|
|
dataIndex: 'STORAGENAME',
|
|
|
header: Zi.LAN.STORAGENAME, //'仓库',
|
|
|
width: 100
|
|
|
},
|
|
|
{
|
|
|
sortable: true,
|
|
|
dataIndex: 'CARRIER',
|
|
|
header: Zi.LAN.CARRIER, //'船公司',
|
|
|
width: 100
|
|
|
},
|
|
|
{
|
|
|
sortable: true,
|
|
|
dataIndex: 'ENTERP',
|
|
|
header: Zi.LAN.ENTERP, //'经营单位',
|
|
|
width: 100
|
|
|
},
|
|
|
{
|
|
|
sortable: true,
|
|
|
dataIndex: 'TRUCKER',
|
|
|
header: Zi.LAN.TRUCKER, //'承运车队',
|
|
|
width: 100
|
|
|
},
|
|
|
{
|
|
|
sortable: true,
|
|
|
dataIndex: 'VOUNO',
|
|
|
header: Zi.LAN.VOUNO, //'凭证号',
|
|
|
width: 60
|
|
|
},
|
|
|
{
|
|
|
sortable: true,
|
|
|
dataIndex: 'FBP',
|
|
|
header: Zi.LAN.FBP, //'免箱期',
|
|
|
width: 60
|
|
|
},
|
|
|
{
|
|
|
sortable: true,
|
|
|
dataIndex: 'BMDDATE',
|
|
|
header: Zi.LAN.BMDDATE, //'箱使到期日',
|
|
|
width: 70
|
|
|
},
|
|
|
{
|
|
|
sortable: true,
|
|
|
dataIndex: 'MDTDATE',
|
|
|
header: Zi.LAN.MDTDATE, //'搬倒日期',
|
|
|
width: 80
|
|
|
},
|
|
|
{
|
|
|
sortable: true,
|
|
|
dataIndex: 'TRADINGAGENCY',
|
|
|
header: Zi.LAN.TRADINGAGENCY, //'贸易代理',
|
|
|
width: 80
|
|
|
},
|
|
|
{
|
|
|
sortable: true,
|
|
|
dataIndex: 'GOODSTYPENAME',
|
|
|
header: Zi.LAN.GOODSTYPENAME, //'品名类型',
|
|
|
width: 60
|
|
|
},
|
|
|
{
|
|
|
sortable: true,
|
|
|
dataIndex: 'SHOWNAME',
|
|
|
header: Zi.LAN.SHOWNAME_Client, //'委托单位联系人',
|
|
|
width: 100
|
|
|
},
|
|
|
{
|
|
|
sortable: true,
|
|
|
dataIndex: 'EMAIL',
|
|
|
header: Zi.LAN.EMAIL, //'委托单位EMAIL',
|
|
|
width: 90
|
|
|
},
|
|
|
{
|
|
|
sortable: true,
|
|
|
dataIndex: 'TEL',
|
|
|
header: Zi.LAN.TEL, //'委托单位TEL',
|
|
|
width: 80
|
|
|
},
|
|
|
{
|
|
|
sortable: true,
|
|
|
dataIndex: 'FAX',
|
|
|
header: Zi.LAN.FAX, //'委托单位FAX',
|
|
|
width: 80
|
|
|
},
|
|
|
{
|
|
|
sortable: true,
|
|
|
dataIndex: 'TARRIFSPAIEDTIEM',
|
|
|
header: Zi.LAN.TARRIFSPAIEDTIEM, //'交关税时间',
|
|
|
width: 70
|
|
|
},
|
|
|
{
|
|
|
sortable: true,
|
|
|
dataIndex: 'APPROVENO',
|
|
|
header: Zi.LAN.APPROVENO, //'审批单号',
|
|
|
width: 100
|
|
|
},
|
|
|
{
|
|
|
sortable: true,
|
|
|
dataIndex: 'UPDATETIME',
|
|
|
header: Zi.LAN.UPDATETIME, //'申报日期',
|
|
|
width: 80
|
|
|
},
|
|
|
{
|
|
|
sortable: true,
|
|
|
id: '',
|
|
|
dataIndex: 'SALECORP',
|
|
|
header: Zi.LAN.SALECOMPANY,
|
|
|
width: 60
|
|
|
},
|
|
|
{
|
|
|
sortable: true,
|
|
|
dataIndex: 'IMPORTVALUE',
|
|
|
header: Zi.LAN.IMPORTVALUE, //'货值',
|
|
|
width: 50,
|
|
|
renderer: function (value, cellmeta, record, rowIndex, columnIndex, store) {
|
|
|
try {
|
|
|
var lsValue = usMoney(value, 2, '', false);
|
|
|
if (lsValue != "NaN") {
|
|
|
value = lsValue; if (parseFloat(lsValue) < 0) {
|
|
|
return '<SPAN style="COLOR: red">' + lsValue + '</SPAN>';
|
|
|
}
|
|
|
}
|
|
|
else {
|
|
|
return value;
|
|
|
}
|
|
|
}
|
|
|
catch (e) {
|
|
|
return value;
|
|
|
}
|
|
|
return value;
|
|
|
}
|
|
|
},
|
|
|
{
|
|
|
sortable: true,
|
|
|
dataIndex: 'UNITPRICE',
|
|
|
header: Zi.LAN.UNITPRICE, //'单价',
|
|
|
width: 50,
|
|
|
renderer: function (value, cellmeta, record, rowIndex, columnIndex, store) {
|
|
|
try {
|
|
|
var lsValue = usMoney(value, 2, '', false);
|
|
|
if (lsValue != "NaN") {
|
|
|
value = lsValue; if (parseFloat(lsValue) < 0) {
|
|
|
return '<SPAN style="COLOR: red">' + lsValue + '</SPAN>';
|
|
|
}
|
|
|
}
|
|
|
else {
|
|
|
return value;
|
|
|
}
|
|
|
}
|
|
|
catch (e) {
|
|
|
return value;
|
|
|
}
|
|
|
return value;
|
|
|
}
|
|
|
},
|
|
|
{
|
|
|
sortable: true,
|
|
|
dataIndex: 'BLTYPE',
|
|
|
header: Zi.LAN.BLTYPE, //'装运方式',
|
|
|
width: 60
|
|
|
},
|
|
|
{
|
|
|
sortable: true,
|
|
|
id: '',
|
|
|
dataIndex: 'CNTR1',
|
|
|
header: Zi.LAN.CNTR1, //'箱型1',
|
|
|
width: 60
|
|
|
},
|
|
|
{
|
|
|
sortable: true,
|
|
|
id: '',
|
|
|
dataIndex: 'CNTR2',
|
|
|
header: Zi.LAN.CNTR2, //'箱型2',
|
|
|
width: 60
|
|
|
},
|
|
|
{
|
|
|
sortable: true,
|
|
|
id: '',
|
|
|
dataIndex: 'CNTR3',
|
|
|
header: Zi.LAN.CNTR3, //'箱型3',
|
|
|
width: 60
|
|
|
},
|
|
|
{
|
|
|
sortable: true,
|
|
|
id: '',
|
|
|
dataIndex: 'CNTR4',
|
|
|
header: Zi.LAN.CNTR4, //'箱型4',
|
|
|
width: 60
|
|
|
},
|
|
|
{
|
|
|
sortable: true,
|
|
|
id: '',
|
|
|
dataIndex: 'CNTR5',
|
|
|
header: Zi.LAN.CNTR5, //'箱型5',
|
|
|
width: 60
|
|
|
},
|
|
|
{
|
|
|
sortable: true,
|
|
|
id: '',
|
|
|
dataIndex: 'CNTR6',
|
|
|
header: Zi.LAN.CNTR6, //'箱型6',
|
|
|
width: 60
|
|
|
},
|
|
|
{
|
|
|
sortable: true,
|
|
|
id: '',
|
|
|
dataIndex: 'CNTR7',
|
|
|
header: Zi.LAN.CNTR7, //'箱型7',
|
|
|
width: 60
|
|
|
},
|
|
|
{
|
|
|
sortable: true,
|
|
|
id: '',
|
|
|
dataIndex: 'CNTR8',
|
|
|
header: Zi.LAN.CNTR8, //'箱型8',
|
|
|
width: 60
|
|
|
},
|
|
|
{
|
|
|
sortable: true,
|
|
|
id: '',
|
|
|
dataIndex: 'CNTR9',
|
|
|
header: Zi.LAN.CNTR9, //'箱型9',
|
|
|
width: 60
|
|
|
},
|
|
|
{
|
|
|
sortable: true,
|
|
|
id: '',
|
|
|
dataIndex: 'CNTR10',
|
|
|
header: Zi.LAN.CNTR10, //'箱型10',
|
|
|
width: 60
|
|
|
}, {
|
|
|
sortable: true,
|
|
|
dataIndex: 'ISPRINTPR',
|
|
|
header: Zi.LAN.ISPRINTPR, //'打印核算单',
|
|
|
width: 100,
|
|
|
renderer: function (value, meta, record) {
|
|
|
if (value == '1')
|
|
|
return '√';
|
|
|
else
|
|
|
return '';
|
|
|
}
|
|
|
}, {
|
|
|
sortable: true,
|
|
|
dataIndex: 'ISFUMIGATION',
|
|
|
header: Zi.LAN.ISFUMIGATION, //'服务项目1',
|
|
|
hidden: true,
|
|
|
width: 100,
|
|
|
renderer: function (value, meta, record) {
|
|
|
if (value == true || value == '1')
|
|
|
return '√';
|
|
|
else
|
|
|
return '';
|
|
|
}
|
|
|
}, {
|
|
|
sortable: true,
|
|
|
dataIndex: 'ISSTORAGE',
|
|
|
header: Zi.LAN.ISSTORAGE, //'服务项目2',
|
|
|
hidden: true,
|
|
|
width: 100,
|
|
|
renderer: function (value, meta, record) {
|
|
|
if (value == true || value == '1')
|
|
|
return '√';
|
|
|
else
|
|
|
return '';
|
|
|
}
|
|
|
}, {
|
|
|
sortable: true,
|
|
|
dataIndex: 'ISLAND',
|
|
|
header: Zi.LAN.ISLAND, //'服务项目3',
|
|
|
hidden: true,
|
|
|
width: 100,
|
|
|
renderer: function (value, meta, record) {
|
|
|
if (value == true || value == '1')
|
|
|
return '√';
|
|
|
else
|
|
|
return '';
|
|
|
}
|
|
|
}, {
|
|
|
sortable: true,
|
|
|
dataIndex: 'ISCUSTOMS',
|
|
|
header: Zi.LAN.ISCUSTOMS, //'服务项目4',
|
|
|
hidden: true,
|
|
|
width: 100,
|
|
|
renderer: function (value, meta, record) {
|
|
|
if (value == true || value == '1')
|
|
|
return '√';
|
|
|
else
|
|
|
return '';
|
|
|
}
|
|
|
}, {
|
|
|
sortable: true,
|
|
|
dataIndex: 'ISINSPECTION',
|
|
|
header: Zi.LAN.ISINSPECTION, //'服务项目5',
|
|
|
hidden: true,
|
|
|
width: 100,
|
|
|
renderer: function (value, meta, record) {
|
|
|
if (value == true || value == '1')
|
|
|
return '√';
|
|
|
else
|
|
|
return '';
|
|
|
}
|
|
|
}, {
|
|
|
sortable: true,
|
|
|
dataIndex: 'ISBOOKING',
|
|
|
header: Zi.LAN.ISBOOKING, //'服务项目6',
|
|
|
hidden: true,
|
|
|
width: 100,
|
|
|
renderer: function (value, meta, record) {
|
|
|
if (value == true || value == '1')
|
|
|
return '√';
|
|
|
else
|
|
|
return '';
|
|
|
}
|
|
|
}, {
|
|
|
sortable: true,
|
|
|
dataIndex: 'ISAGENT',
|
|
|
header: Zi.LAN.ISAGENT, //'服务项目7',
|
|
|
hidden: true,
|
|
|
width: 100,
|
|
|
renderer: function (value, meta, record) {
|
|
|
if (value == true || value == '1')
|
|
|
return '√';
|
|
|
else
|
|
|
return '';
|
|
|
}
|
|
|
}, {
|
|
|
sortable: true,
|
|
|
dataIndex: 'ISHBLNO',
|
|
|
header: Zi.LAN.ISHBLNO, //'服务项目8',
|
|
|
hidden: true,
|
|
|
width: 100,
|
|
|
renderer: function (value, meta, record) {
|
|
|
if (value == true || value == '1')
|
|
|
return '√';
|
|
|
else
|
|
|
return '';
|
|
|
}
|
|
|
}, {
|
|
|
sortable: true,
|
|
|
dataIndex: 'SERVICE9',
|
|
|
header: Zi.LAN.SERVICE9, //'服务项目9',
|
|
|
hidden: true,
|
|
|
width: 100,
|
|
|
renderer: function (value, meta, record) {
|
|
|
if (value == true || value == '1')
|
|
|
return '√';
|
|
|
else
|
|
|
return '';
|
|
|
}
|
|
|
}, {
|
|
|
sortable: true,
|
|
|
dataIndex: 'SERVICE10',
|
|
|
header: Zi.LAN.SERVICE10, //'服务项目10',
|
|
|
hidden: true,
|
|
|
width: 100,
|
|
|
renderer: function (value, meta, record) {
|
|
|
if (value == true || value == '1')
|
|
|
return '√';
|
|
|
else
|
|
|
return '';
|
|
|
}
|
|
|
}, {
|
|
|
sortable: true,
|
|
|
dataIndex: 'ISAPPLY',
|
|
|
header: Zi.LAN.ISAPPLY, //'是否生成报关',
|
|
|
width: 80,
|
|
|
renderer: function (value, meta, record) {
|
|
|
if (value != '0')
|
|
|
return '√';
|
|
|
else
|
|
|
return '';
|
|
|
}
|
|
|
}, {
|
|
|
dataIndex: 'BLISSUESTATUS',
|
|
|
header: '提单签发状态', //'货物标识',
|
|
|
width: 120
|
|
|
}, {
|
|
|
dataIndex: 'APPLYNO',
|
|
|
header: Zi.LAN.APPLYNO, //'申请放箱号',
|
|
|
width: 120
|
|
|
}, {
|
|
|
dataIndex: 'DEST_RTCNT_TIME',
|
|
|
header: '目的港还箱日期',
|
|
|
width: 100
|
|
|
}, {
|
|
|
sortable: true,
|
|
|
dataIndex: 'AMEND',
|
|
|
header: Zi.LAN.AMEND, //'更改单',
|
|
|
width: 80,
|
|
|
renderer: function (value, meta, record) {
|
|
|
if (value != '0')
|
|
|
return '√';
|
|
|
else
|
|
|
return '';
|
|
|
}
|
|
|
}, {
|
|
|
dataIndex: 'CTNNUM',
|
|
|
header: Zi.LAN.CTNNUM, //'申请放箱号',
|
|
|
width: 120
|
|
|
}, {
|
|
|
dataIndex: 'WMSCTNNUM',
|
|
|
header: Zi.LAN.WMSCTNNUM, //'申请放箱号',
|
|
|
width: 120
|
|
|
}, {
|
|
|
dataIndex: 'REMARK',
|
|
|
header: Zi.LAN.REMARK, //'货物标识',
|
|
|
width: 120
|
|
|
}, {
|
|
|
dataIndex: 'REMARK2',
|
|
|
header: Zi.LAN.REMARK+'2', //'货物标识',
|
|
|
width: 120
|
|
|
}, {
|
|
|
dataIndex: 'DESCRIPTION',
|
|
|
header: Zi.LAN.DESCRIPTION, //'货物标识',
|
|
|
width: 120
|
|
|
}, {
|
|
|
dataIndex: 'MaTou',
|
|
|
header: Zi.LAN.MaTou , //'码头',
|
|
|
width: 120
|
|
|
}, {
|
|
|
dataIndex: 'SALEDEPT',
|
|
|
header: Zi.LAN.SALEDEPT2, //'码头',
|
|
|
width: 120
|
|
|
},
|
|
|
{
|
|
|
sortable: true,
|
|
|
id: '',
|
|
|
dataIndex: 'SERVICE',
|
|
|
header: Zi.LAN.SERVICE, //'航线',
|
|
|
width: 100
|
|
|
},
|
|
|
{
|
|
|
sortable: true,
|
|
|
id: '',
|
|
|
dataIndex: 'DESTINATION',
|
|
|
header: Zi.LAN.DESTINATION, //'航线',
|
|
|
width: 100
|
|
|
},
|
|
|
{
|
|
|
sortable: true,
|
|
|
id: '',
|
|
|
dataIndex: 'SHIPPER',
|
|
|
header: Zi.LAN.SHIPPERID, //'SHIPPER',
|
|
|
width: 100
|
|
|
},
|
|
|
{
|
|
|
sortable: true,
|
|
|
id: '',
|
|
|
dataIndex: 'CONSIGNEE',
|
|
|
header: Zi.LAN.CONSIGNEEID, //'CONSIGNEE',
|
|
|
width: 100,
|
|
|
filter: {
|
|
|
type: 'string',
|
|
|
dataIndex: 'CONSIGNEE'
|
|
|
}
|
|
|
},
|
|
|
{
|
|
|
sortable: true,
|
|
|
id: '',
|
|
|
dataIndex: 'NOTIFYPARTY',
|
|
|
header: Zi.LAN.NOTIFYPARTYID, //'NOTIFYPARTY',
|
|
|
width: 100
|
|
|
},
|
|
|
{
|
|
|
sortable: true,
|
|
|
id: '',
|
|
|
dataIndex: 'AGENTID',
|
|
|
header: Zi.LAN.AGENTID, //'NOTIFYPARTY',
|
|
|
width: 100
|
|
|
},
|
|
|
{
|
|
|
sortable: true,
|
|
|
id: '',
|
|
|
dataIndex: 'TIHUOTIME',
|
|
|
header: Zi.LAN.TIHUOTIME, //'NOTIFYPARTY',
|
|
|
width: 100
|
|
|
}, {
|
|
|
sortable: false,
|
|
|
dataIndex: 'CHANGEDOCSTATUS',
|
|
|
text: Zi.LAN.CHANGEDOCSTATUS,
|
|
|
width: 56,
|
|
|
renderer: function (value, meta, record) {
|
|
|
if (record.data.CHANGEDOCSTATUS == 1) {
|
|
|
return '<a style="text-decoration:none;"><span style=\"color:green;font-size:30px;text-align:center\"> ●</span></a>'
|
|
|
} else if (record.data.CHANGEDOCSTATUS == 2) {
|
|
|
return '<a style="text-decoration:none;"><span style=\"color:yellow;font-size:30px;text-align:center\"> ●</span></a>'
|
|
|
} else {
|
|
|
return "";
|
|
|
}
|
|
|
}
|
|
|
}, {
|
|
|
sortable: false,
|
|
|
dataIndex: 'CUSTOMSSTATUS',
|
|
|
text: Zi.LAN.CUSTOMSSTATUS,
|
|
|
width: 56,
|
|
|
renderer: function (value, meta, record) {
|
|
|
if (record.data.CUSTOMSSTATUS == 1) {
|
|
|
return '<a style="text-decoration:none;"><span style=\"color:green;font-size:30px;text-align:center\"> ●</span></a>'
|
|
|
} else if (record.data.CUSTOMSSTATUS == 2) {
|
|
|
return '<a style="text-decoration:none;"><span style=\"color:yellow;font-size:30px;text-align:center\"> ●</span></a>'
|
|
|
} else {
|
|
|
return "";
|
|
|
}
|
|
|
}
|
|
|
}, {
|
|
|
sortable: false,
|
|
|
dataIndex: 'CANGDANSTATUS',
|
|
|
text: Zi.LAN.CANGDANSTATUS,
|
|
|
width: 56,
|
|
|
renderer: function (value, meta, record) {
|
|
|
if (record.data.CANGDANSTATUS == 1) {
|
|
|
return '<a style="text-decoration:none;"><span style=\"color:green;font-size:30px;text-align:center\"> ●</span></a>'
|
|
|
} else if (record.data.CANGDANSTATUS == 2) {
|
|
|
return '<a style="text-decoration:none;"><span style=\"color:yellow;font-size:30px;text-align:center\"> ●</span></a>'
|
|
|
} else {
|
|
|
return "";
|
|
|
}
|
|
|
}
|
|
|
}
|
|
|
,
|
|
|
{
|
|
|
sortable: true,
|
|
|
id: '',
|
|
|
dataIndex: 'INSPECTSERVICE',
|
|
|
header: Zi.LAN.INSPECTSERVICE, //'NOTIFYPARTY',
|
|
|
width: 100,
|
|
|
renderer: function (value, meta, record) {
|
|
|
var records = DsStoreQueryBy(_this.storeINSPECTSERVICE, 'EnumValueId', value);
|
|
|
if (records.getCount() > 0) {
|
|
|
var data = records.getAt(0).data;
|
|
|
var EnumValueName = data.EnumValueName;
|
|
|
return EnumValueName;
|
|
|
} else return value;
|
|
|
}
|
|
|
}
|
|
|
];
|
|
|
|
|
|
this.Pagenum = Ext.create('Ext.form.field.Number', {
|
|
|
name: 'bottles',
|
|
|
fieldLabel: Zi.LAN.bottles, //'每页记录数',
|
|
|
labelAlign: 'right',
|
|
|
value: this.PageSize,
|
|
|
maxValue: 100000,
|
|
|
width: 180,
|
|
|
minValue: 0,
|
|
|
listeners: {
|
|
|
specialkey: function (field, e) {
|
|
|
if (e.getKey() == e.ENTER) {
|
|
|
_this.onRefreshClick();
|
|
|
}
|
|
|
}
|
|
|
}
|
|
|
});
|
|
|
|
|
|
this.girdcolums = this.initgirdcolums;
|
|
|
this.GridCheckBoxModel = Ext.create('Ext.selection.CheckboxModel');
|
|
|
|
|
|
|
|
|
//定义Grid
|
|
|
this.gridList = new Ext.grid.GridPanel({
|
|
|
store: this.storeList,
|
|
|
enableHdMenu: false,
|
|
|
region: 'center',
|
|
|
loadMask: { msg: Zi.LAN.ShuJuJiaZaiZhongQingShaoDeng },
|
|
|
trackMouseOver: true,
|
|
|
disableSelection: false,
|
|
|
columns: this.girdcolums,
|
|
|
selModel: this.GridCheckBoxModel,
|
|
|
viewConfig: {
|
|
|
enableTextSelection: true, //允许复制数据
|
|
|
autoFill: true
|
|
|
},
|
|
|
plugins: [{
|
|
|
ptype: 'rowexpander',
|
|
|
rowBodyTpl: [
|
|
|
'<div id="{BSNO}">',
|
|
|
'</div>'
|
|
|
]
|
|
|
}],
|
|
|
// paging bar on the bottom
|
|
|
bbar: [Ext.create('Ext.PagingToolbar', {
|
|
|
store: this.storeList,
|
|
|
displayInfo: true,
|
|
|
displayMsg: Zi.LAN.displayMsg, //'当前显示 {0} - {1}条记录 /共 {2}条记录',
|
|
|
emptyMsg: Zi.LAN.emptyMsg //"没有数据"
|
|
|
}), this.Pagenum]
|
|
|
});
|
|
|
|
|
|
/////////////以下部分为获取存储的gridpanel显示样式
|
|
|
this.girdcolums = DsTruck.GetGridPanel(USERID, this.formname, this.girdcolums, 1); //使用者id,表名,中间column数组,跳过一开始的几列
|
|
|
|
|
|
// this.girdcolums.unshift(new Ext.grid.RowNumberer());
|
|
|
|
|
|
this.gridList.reconfigure(this.storeList, this.girdcolums);
|
|
|
this.gridList.columns[1] = new Ext.grid.RowNumberer();
|
|
|
|
|
|
////////////////////////////////////////////////
|
|
|
|
|
|
this.gridList.addListener('itemdblclick', function (dataview, record, item, index, e, b) {
|
|
|
this.SelectedRecord = record;
|
|
|
this.OprationStatus = 'edit';
|
|
|
// DsOpenMultiEditWin('/MvcShipping/MsOpSeai/Edit', record.data.BSNO);
|
|
|
DsOpenEditWin('/MvcShipping/MsOpSeai/Edit?BSNO=' + record.data.BSNO, record.data.BSNO);
|
|
|
}, this);
|
|
|
|
|
|
this.gridList.addListener('itemclick', function (dataview, record, item, index, e, b) {
|
|
|
this.SelectedRecord = record;
|
|
|
var bsno = record.get('BSNO');
|
|
|
_this.bsno = bsno;
|
|
|
var btntxt = Ext.getCmp('btnCover').getText();
|
|
|
if (btntxt == '隐藏Cover')
|
|
|
_this.RefreshCover(bsno);
|
|
|
}, this);
|
|
|
|
|
|
this.gridList.addListener('sortchange', function (ct, column, direction, eOpts) {
|
|
|
this.sortfield = column.dataIndex;
|
|
|
this.sortdire = direction;
|
|
|
}, this);
|
|
|
|
|
|
this.gridList.view.on('expandBody', function (rowNode, record, expandRow, eOpts) {
|
|
|
_this.displayInnerGrid(record.get('BSNO'), record.get('FENPIAO'));
|
|
|
});
|
|
|
|
|
|
this.gridList.view.on('collapsebody', function (rowNode, record, expandRow, eOpts) {
|
|
|
_this.destroyInnerGrid(record);
|
|
|
});
|
|
|
|
|
|
//#endregion
|
|
|
|
|
|
_this = this;
|
|
|
|
|
|
//#region formSearch 下拉框信息加载
|
|
|
//权限范围
|
|
|
this.StoreOpRange = Ext.create('DsExt.ux.RefTableStore', {
|
|
|
model: 'MsOP',
|
|
|
proxy: { url: '/MvcShipping/MsBaseInfo/GetOpRang' }
|
|
|
});
|
|
|
this.StoreOpRange.load({ params: { optype: "modSeaImportList"} });
|
|
|
|
|
|
//人员信息加载
|
|
|
this.storeOpCode = Ext.create('DsExt.ux.RefTableStore', {
|
|
|
model: 'DsShipping.ux.UserRefModel',
|
|
|
proxy: { url: '/CommMng/BasicDataRef/GetUserRefList' }
|
|
|
});
|
|
|
this.storeOpCode.load();
|
|
|
//客服
|
|
|
this.comboxCUSTSERVICE = Ext.create('DsExt.ux.RefTableCombox', {
|
|
|
fieldLabel: Zi.LAN.CUSTSERVICE, //'客服',
|
|
|
store: this.storeOpCode,
|
|
|
forceSelection: true,
|
|
|
name: 'CUSTSERVICE',
|
|
|
valueField: 'UserName',
|
|
|
displayField: 'CodeAndName'
|
|
|
});
|
|
|
//揽货人
|
|
|
this.comboxSALE = Ext.create('DsExt.ux.RefTableCombox', {
|
|
|
fieldLabel: Zi.LAN.SALE, //'揽货人',
|
|
|
store: this.storeOpCode,
|
|
|
forceSelection: true,
|
|
|
flex: 0.8,
|
|
|
name: 'SALE',
|
|
|
valueField: 'UserName',
|
|
|
displayField: 'CodeAndName'
|
|
|
});
|
|
|
//操 作
|
|
|
this.comboxOP = Ext.create('DsExt.ux.RefTableCombox', {
|
|
|
fieldLabel: Zi.LAN.OP, //'操 作',
|
|
|
store: this.storeOpCode,
|
|
|
forceSelection: true,
|
|
|
flex: 0.8,
|
|
|
name: 'OP',
|
|
|
valueField: 'UserName',
|
|
|
displayField: 'CodeAndName',
|
|
|
enableKeyEvents: true,
|
|
|
listeners: {
|
|
|
keyup: function (field, e) {
|
|
|
if (e.getKey() == e.ENTER) {
|
|
|
_this.onRefreshClick();
|
|
|
}
|
|
|
}
|
|
|
}
|
|
|
});
|
|
|
//录入人
|
|
|
this.comboxINPUTBY = Ext.create('DsExt.ux.RefTableCombox', {
|
|
|
fieldLabel: Zi.LAN.INPUTBY, //'录入人',
|
|
|
store: this.storeOpCode,
|
|
|
forceSelection: true,
|
|
|
flex: 0.8,
|
|
|
name: 'INPUTBY',
|
|
|
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.storeCustCode.load({ params: { condition: "ISCONTROLLER='1'"} });
|
|
|
//委托单位
|
|
|
this.comboxCustCode = Ext.create('DsExt.ux.RefTableCombox', {
|
|
|
fieldLabel: Zi.LAN.CUSTOMERNAME, //'委托单位',
|
|
|
store: this.storeCustCode,
|
|
|
forceSelection: true,
|
|
|
queryMode: 'remote',
|
|
|
minChars: 0,
|
|
|
queryParam: 'CODENAME',
|
|
|
name: 'CUSTOMERNAME',
|
|
|
valueField: 'CustName',
|
|
|
displayField: 'CodeAndName',
|
|
|
enableKeyEvents: true,
|
|
|
listeners: {
|
|
|
keyup: function (field, e) {
|
|
|
if (e.getKey() == e.ENTER) {
|
|
|
_this.onRefreshClick();
|
|
|
}
|
|
|
}
|
|
|
}
|
|
|
});
|
|
|
//this.comboxCustENTERP = Ext.create('DsExt.ux.RefTableCombox', {
|
|
|
// fieldLabel: Zi.LAN.ENTERP, //'经营单位',
|
|
|
// store: this.storeCustCode,
|
|
|
// forceSelection: true,
|
|
|
// name: 'ENTERP',
|
|
|
// valueField: 'CustName',
|
|
|
// displayField: 'CodeAndName'
|
|
|
//});
|
|
|
////仓储出库货主
|
|
|
//this.comboxCustWmsCode = Ext.create('DsExt.ux.RefTableCombox', {
|
|
|
// fieldLabel: Zi.LAN.CUSTOMERNAME_WMS, //'仓储货主',
|
|
|
// store: this.storeCustCode,
|
|
|
// forceSelection: true,
|
|
|
// name: 'CUSTOMERNAME_WMS',
|
|
|
// valueField: 'CustName',
|
|
|
// displayField: 'CodeAndName'
|
|
|
//});
|
|
|
////仓储出库货转对象
|
|
|
//this.comboxCustWmsOutCode = Ext.create('DsExt.ux.RefTableCombox', {
|
|
|
// fieldLabel: Zi.LAN.CUSTOMERNAME_WMS_OUT, //'货转对象',
|
|
|
// store: this.storeCustCode,
|
|
|
// forceSelection: true,
|
|
|
// name: 'CUSTOMERNAME_WMS_OUT',
|
|
|
// valueField: 'CustName',
|
|
|
// displayField: 'CodeAndName'
|
|
|
//});
|
|
|
|
|
|
////客户加载_贸易代理
|
|
|
//this.storeTRADINGAGENCY = Ext.create('DsExt.ux.RefTableStore', {
|
|
|
// model: 'DsShipping.ux.CustomRefModel',
|
|
|
// proxy: { url: '/CommMng/BasicDataRef/GetCustomRefList' }
|
|
|
//});
|
|
|
//this.storeTRADINGAGENCY.load({ params: { condition: "ISTRADINGAGENCY='1'"} });
|
|
|
////贸易代理
|
|
|
//this.comboxTRADINGAGENCY = Ext.create('DsExt.ux.RefTableCombox', {
|
|
|
// fieldLabel: Zi.LAN.TRADINGAGENCY, //'贸易代理',
|
|
|
// store: this.storeTRADINGAGENCY,
|
|
|
// forceSelection: true,
|
|
|
// name: 'TRADINGAGENCY',
|
|
|
// valueField: 'CustName',
|
|
|
// displayField: 'CodeAndName'
|
|
|
//});
|
|
|
|
|
|
////客户加载_船公司
|
|
|
//this.storeCARRIER = Ext.create('DsExt.ux.RefTableStore', {
|
|
|
// model: 'DsShipping.ux.CustomRefModel',
|
|
|
// proxy: { url: '/CommMng/BasicDataRef/GetCustomRefList' }
|
|
|
//});
|
|
|
//this.storeCARRIER.load({ params: { condition: "ISCARRIER='1'"} });
|
|
|
////船公司
|
|
|
//this.comboxCARRIER = Ext.create('DsExt.ux.RefTableCombox', {
|
|
|
// fieldLabel: Zi.LAN.CARRIER, //'船公司',
|
|
|
// store: this.storeCARRIER,
|
|
|
// forceSelection: true,
|
|
|
// name: 'CARRIER',
|
|
|
// valueField: 'CustName',
|
|
|
// displayField: 'CodeAndName'
|
|
|
//});
|
|
|
|
|
|
////客户加载_车队
|
|
|
//this.storeTRUCKER = Ext.create('DsExt.ux.RefTableStore', {
|
|
|
// model: 'DsShipping.ux.CustomRefModel',
|
|
|
// proxy: { url: '/CommMng/BasicDataRef/GetCustomRefList' }
|
|
|
//});
|
|
|
//this.storeTRUCKER.load({ params: { condition: "ISTRUCK='1'"} });
|
|
|
////车队
|
|
|
//this.comboxTRUCKER = Ext.create('DsExt.ux.RefTableCombox', {
|
|
|
// fieldLabel: Zi.LAN.TRUCKER, //'车队',
|
|
|
// store: this.storeTRUCKER,
|
|
|
// forceSelection: true,
|
|
|
// name: 'TRUCKER',
|
|
|
// valueField: 'CustName',
|
|
|
// displayField: 'CodeAndName'
|
|
|
//});
|
|
|
|
|
|
////客户加载_报关报检
|
|
|
//this.storeCUSTOMSER = Ext.create('DsExt.ux.RefTableStore', {
|
|
|
// model: 'DsShipping.ux.CustomRefModel',
|
|
|
// proxy: { url: '/CommMng/BasicDataRef/GetCustomRefList' }
|
|
|
//});
|
|
|
//this.storeCUSTOMSER.load({ params: { condition: "ISCUSTOM='1'"} });
|
|
|
////报关行
|
|
|
//this.comboxCUSTOMSER = Ext.create('DsExt.ux.RefTableCombox', {
|
|
|
// fieldLabel: Zi.LAN.CUSTOMSER, //'报关行',
|
|
|
// store: this.storeCUSTOMSER,
|
|
|
// forceSelection: true,
|
|
|
// name: 'CUSTOMSER',
|
|
|
// valueField: 'CustName',
|
|
|
// displayField: 'CodeAndName'
|
|
|
//});
|
|
|
////报检
|
|
|
//this.comboxINSPECTION = Ext.create('DsExt.ux.RefTableCombox', {
|
|
|
// fieldLabel: Zi.LAN.INSPECTION, //'报检',
|
|
|
// store: this.storeCUSTOMSER,
|
|
|
// forceSelection: true,
|
|
|
// name: 'INSPECTION',
|
|
|
// valueField: 'CustName',
|
|
|
// displayField: 'CodeAndName'
|
|
|
//});
|
|
|
|
|
|
//键值维护表_贸易方式
|
|
|
//this.storeCrmKeyCodeCode = Ext.create('DsExt.ux.RefTableStore', {
|
|
|
// model: 'DsShipping.ux.CrmKeyCodeModel',
|
|
|
// proxy: { url: '/CommMng/BasicDataRef/GetCrmKeyCodeList' }
|
|
|
//});
|
|
|
//this.storeCrmKeyCodeCode.load({ params: { condition: " and KEYTYPE='贸易方式'"} });
|
|
|
//this.comboxTRADETYPE = Ext.create('DsExt.ux.RefTableCombox', {
|
|
|
// fieldLabel: Zi.LAN.TRADETYPE, //'贸易方式',
|
|
|
// store: this.storeCrmKeyCodeCode,
|
|
|
// forceSelection: true,
|
|
|
// name: 'TRADETYPE',
|
|
|
// valueField: 'KEYVALUE',
|
|
|
// displayField: 'KEYVALUE'
|
|
|
//});
|
|
|
|
|
|
//键值维护表_仓储类型
|
|
|
//this.storeCrmKeyCodeCode2 = Ext.create('DsExt.ux.RefTableStore', {
|
|
|
// model: 'DsShipping.ux.CrmKeyCodeModel',
|
|
|
// proxy: { url: '/CommMng/BasicDataRef/GetCrmKeyCodeList' }
|
|
|
//});
|
|
|
//this.storeCrmKeyCodeCode2.load({ params: { condition: " and KEYTYPE='仓储类型'"} });
|
|
|
//this.comboxWMSTYPE = Ext.create('DsExt.ux.RefTableCombox', {
|
|
|
// fieldLabel: Zi.LAN.WMSTYPE, //'仓储类型',
|
|
|
// store: this.storeCrmKeyCodeCode2,
|
|
|
// forceSelection: true,
|
|
|
// name: 'WMSTYPE',
|
|
|
// valueField: 'KEYVALUE',
|
|
|
// displayField: 'KEYVALUE'
|
|
|
//});
|
|
|
|
|
|
//键值维护表_装运方式
|
|
|
//this.storeCrmKeyCodeCode3 = Ext.create('DsExt.ux.RefTableStore', {
|
|
|
// model: 'DsShipping.ux.CrmKeyCodeModel',
|
|
|
// proxy: { url: '/CommMng/BasicDataRef/GetCrmKeyCodeList' }
|
|
|
//});
|
|
|
//this.storeCrmKeyCodeCode3.load({ params: { condition: " and KEYTYPE='装运方式'"} });
|
|
|
//this.comboxBLTYPE = Ext.create('DsExt.ux.RefTableCombox', {
|
|
|
// fieldLabel: Zi.LAN.BLTYPE, //'装运方式',
|
|
|
// store: this.storeCrmKeyCodeCode3,
|
|
|
// forceSelection: true,
|
|
|
// name: 'BLTYPE',
|
|
|
// valueField: 'KEYVALUE',
|
|
|
// displayField: 'KEYVALUE'
|
|
|
//});
|
|
|
|
|
|
//键值维护表_委托单类型
|
|
|
//this.storeCrmKeyCodeCode4 = Ext.create('DsExt.ux.RefTableStore', {
|
|
|
// model: 'DsShipping.ux.CrmKeyCodeModel',
|
|
|
// proxy: { url: '/CommMng/BasicDataRef/GetCrmKeyCodeList' }
|
|
|
//});
|
|
|
//this.storeCrmKeyCodeCode4.load({ params: { condition: " and KEYTYPE='委托单类型'"} });
|
|
|
//this.comboxBSTYPE = Ext.create('DsExt.ux.RefTableCombox', {
|
|
|
// fieldLabel: Zi.LAN.BSTYPE, //'委托单类型',
|
|
|
// store: this.storeCrmKeyCodeCode4,
|
|
|
// forceSelection: true,
|
|
|
// name: 'BSTYPE',
|
|
|
// valueField: 'KEYVALUE',
|
|
|
// displayField: 'KEYVALUE'
|
|
|
//});
|
|
|
|
|
|
//品名
|
|
|
//this.storeCodeGoodsList = Ext.create('DsExt.ux.RefTableStore', {
|
|
|
// model: 'DsShipping.ux.CodeGoodsModel',
|
|
|
// proxy: { url: '/CommMng/BasicDataRef/GetCodeGoodsList' }
|
|
|
//});
|
|
|
//this.storeCodeGoodsList.load();
|
|
|
//this.comboxGOODSNAME = Ext.create('DsExt.ux.RefTableCombox', {
|
|
|
// fieldLabel: Zi.LAN.GOODSNAME, //'品名',
|
|
|
// store: this.storeCodeGoodsList,
|
|
|
// forceSelection: true,
|
|
|
// name: 'GOODSNAME',
|
|
|
// valueField: 'GOODNAME',
|
|
|
// displayField: 'CodeAndName'
|
|
|
//});
|
|
|
|
|
|
//业务来源
|
|
|
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: Zi.LAN.BSSOURCE, //'业务来源',
|
|
|
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.formHead.getForm().findField('BSSOURCEDETAIL');
|
|
|
BSSOURCEDETAIL.setValue('');
|
|
|
}
|
|
|
}
|
|
|
}
|
|
|
}
|
|
|
});
|
|
|
this.comboxBSSOURCEDETAIL = Ext.create('DsExt.ux.RefTableCombox', {
|
|
|
fieldLabel: Zi.LAN.BSSOURCEDETAIL, //'来源明细',
|
|
|
store: this.storeSourceDetail,
|
|
|
forceSelection: true,
|
|
|
name: 'BSSOURCEDETAIL',
|
|
|
valueField: 'SourceDetail',
|
|
|
displayField: 'SourceDetail'
|
|
|
});
|
|
|
|
|
|
//状态_业务状态
|
|
|
Ext.define('BSSTATUSModel', {
|
|
|
extend: 'Ext.data.Model',
|
|
|
fields: [
|
|
|
{ name: 'Name', type: 'string' }
|
|
|
]
|
|
|
});
|
|
|
var dataBSSTATUS = [{ "Name": "未锁定" }, { "Name": "锁定" }, { "Name": ""}];
|
|
|
var storeBSSTATUS = Ext.create('Ext.data.Store', {
|
|
|
model: 'BSSTATUSModel',
|
|
|
data: dataBSSTATUS
|
|
|
});
|
|
|
//业务状态
|
|
|
this.comboxBSSTATUS = Ext.create('DsExt.ux.RefTableCombox', {
|
|
|
fieldLabel: Zi.LAN.BSSTATUSREF, //'业务锁定',
|
|
|
forceSelection: true,
|
|
|
store: storeBSSTATUS,
|
|
|
name: 'BSSTATUS',
|
|
|
valueField: 'Name',
|
|
|
displayField: 'Name'
|
|
|
});
|
|
|
//费用状态
|
|
|
this.comboxFEESTATUS = Ext.create('DsExt.ux.RefTableCombox', {
|
|
|
fieldLabel: Zi.LAN.FEESTATUSREF, //'费用锁定',
|
|
|
forceSelection: true,
|
|
|
store: storeBSSTATUS,
|
|
|
name: 'FEESTATUS',
|
|
|
valueField: 'Name',
|
|
|
displayField: 'Name'
|
|
|
});
|
|
|
|
|
|
//所属部门
|
|
|
this.storeDept = Ext.create('DsExt.ux.RefTableStore', {
|
|
|
model: 'DsShipping.ux.DeptModel',
|
|
|
proxy: { url: '/CommMng/BasicDataRef/GetDeptList_All_Group' }//proxy: { url: '/CommMng/BasicDataRef/GetDeptList' }
|
|
|
});
|
|
|
this.storeDept.load();
|
|
|
this.comboxDept = Ext.create('DsExt.ux.RefTableCombox', {
|
|
|
fieldLabel: Zi.LAN.SALEDEPT2, //'所属部门',
|
|
|
store: this.storeDept,
|
|
|
forceSelection: true,
|
|
|
name: 'SALEDEPT',
|
|
|
valueField: 'DeptName',
|
|
|
displayField: 'DeptName'
|
|
|
//,hidden: true
|
|
|
});
|
|
|
|
|
|
//国际港口(进口装货港、出口卸货港)
|
|
|
this.storeCodeDisport = Ext.create('DsExt.ux.RefTableStore', {
|
|
|
model: 'DsShipping.ux.CodeDisportModel',
|
|
|
proxy: { url: '/CommMng/BasicDataRef/GetCodeDisportListRm' }
|
|
|
});
|
|
|
// this.storeCodeDisport.load();
|
|
|
this.comboxPORTLOAD = Ext.create('DsExt.ux.RefTableCombox', {
|
|
|
fieldLabel: Zi.LAN.PORTLOAD, //'装货港',
|
|
|
store: this.storeCodeDisport,
|
|
|
forceSelection: true,
|
|
|
name: 'PORTLOAD',
|
|
|
queryMode: 'remote',
|
|
|
minChars: 1,
|
|
|
queryParam: 'PORT',
|
|
|
valueField: 'CNAME',
|
|
|
displayField: 'CodeAndName'
|
|
|
});
|
|
|
|
|
|
//国内港口(出口装货港、进口卸货港)
|
|
|
//this.storeCodeLoadport = Ext.create('DsExt.ux.RefTableStore', {
|
|
|
// model: 'DsShipping.ux.CodeLoadportModel',
|
|
|
// proxy: { url: '/CommMng/BasicDataRef/GetCodeLoadportList' }
|
|
|
//});
|
|
|
//this.storeCodeLoadport.load();
|
|
|
//this.comboxPORTDISCHARGE = Ext.create('DsExt.ux.RefTableCombox', {
|
|
|
// fieldLabel: Zi.LAN.PORTDISCHARGE, //'卸货港',
|
|
|
// store: this.storeCodeLoadport,
|
|
|
// forceSelection: true,
|
|
|
// name: 'PORTDISCHARGE',
|
|
|
// valueField: 'CNAME',
|
|
|
// displayField: 'CodeAndName'
|
|
|
//});
|
|
|
|
|
|
//品名类型
|
|
|
//this.storeCodeGoodsType = Ext.create('DsExt.ux.RefTableStore', {
|
|
|
// model: 'DsShipping.ux.CodeGoodsTypeModel',
|
|
|
// proxy: { url: '/CommMng/BasicDataRef/GetCodeGoodsTypeList' }
|
|
|
//});
|
|
|
//this.storeCodeGoodsType.load();
|
|
|
//this.comboxGOODSTYPENAME = Ext.create('DsExt.ux.RefTableCombox', {
|
|
|
// fieldLabel: Zi.LAN.GOODSTYPENAME, //'品名类型',
|
|
|
// store: this.storeCodeGoodsType,
|
|
|
// forceSelection: true,
|
|
|
// name: 'GOODSTYPENAME',
|
|
|
// valueField: 'GoodsTypeName',
|
|
|
// displayField: 'CodeAndName'
|
|
|
//});
|
|
|
//#endregion
|
|
|
|
|
|
//#region formSearch 查询面板
|
|
|
this.formSearch = Ext.widget('form', {
|
|
|
frame: true,
|
|
|
region: 'center',
|
|
|
bodyPadding: 5,
|
|
|
fieldDefaults: {
|
|
|
margins: '2 2 2 2',
|
|
|
labelAlign: 'right',
|
|
|
flex: 1,
|
|
|
labelWidth: 60,
|
|
|
msgTarget: 'qtip'
|
|
|
},
|
|
|
|
|
|
items: [{//fieldset 1
|
|
|
xtype: 'container',
|
|
|
defaultType: 'textfield',
|
|
|
layout: 'anchor',
|
|
|
defaults: {
|
|
|
anchor: '100%'
|
|
|
},
|
|
|
items: [{
|
|
|
xtype: 'container',
|
|
|
layout: 'hbox',
|
|
|
defaultType: 'textfield',
|
|
|
items: [{
|
|
|
fieldLabel: Zi.LAN.MblNo2, //'编号',
|
|
|
name: 'MblNo',
|
|
|
enableKeyEvents: true,
|
|
|
listeners: {
|
|
|
specialkey: function (field, e) {
|
|
|
if (e.getKey() == e.ENTER) {
|
|
|
_this.onRefreshClick();
|
|
|
}
|
|
|
}
|
|
|
}
|
|
|
}, {
|
|
|
xtype: 'button',
|
|
|
width: 25,
|
|
|
text:'', //"高级查询",
|
|
|
iconCls: "btnmore",
|
|
|
handler: function (button, event) {
|
|
|
_this.winMBLPLQueryShow.show();
|
|
|
return;
|
|
|
},
|
|
|
scope: this
|
|
|
}, this.comboxCustCode
|
|
|
// , {
|
|
|
// fieldLabel: Zi.LAN., //'会计期间',
|
|
|
// format: 'Y-m',
|
|
|
// xtype: 'datefield',
|
|
|
// name: 'ACCDATE'
|
|
|
// }
|
|
|
|
|
|
, {
|
|
|
fieldLabel: Zi.LAN.ETD, //'到港日期',
|
|
|
format: 'Y-m-d',
|
|
|
xtype: 'datefield',
|
|
|
name: 'ETDbgn',
|
|
|
enableKeyEvents: true,
|
|
|
listeners: {
|
|
|
specialkey: function (field, e) {
|
|
|
if (e.getKey() == e.ENTER) {
|
|
|
_this.onRefreshClick();
|
|
|
}
|
|
|
}
|
|
|
}
|
|
|
}, {
|
|
|
fieldLabel: Zi.LAN.ETDend, //'到',
|
|
|
format: 'Y-m-d',
|
|
|
xtype: 'datefield',
|
|
|
name: 'ETDend',
|
|
|
enableKeyEvents: true,
|
|
|
listeners: {
|
|
|
specialkey: function (field, e) {
|
|
|
if (e.getKey() == e.ENTER) {
|
|
|
_this.onRefreshClick();
|
|
|
}
|
|
|
}
|
|
|
}
|
|
|
}, this.comboxOP, this.comboxSALE, {
|
|
|
xtype: 'button',
|
|
|
width: 90,
|
|
|
text: Zi.LAN.btnrefresh, //"执行查询",
|
|
|
iconCls: "btnrefresh",
|
|
|
handler: function (button, event) {
|
|
|
this.onRefreshClick(button, event);
|
|
|
},
|
|
|
scope: this
|
|
|
}, {
|
|
|
xtype: 'button',
|
|
|
width: 90,
|
|
|
text: Zi.LAN.btnmore, //"高级查询",
|
|
|
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
|
|
|
}]
|
|
|
}
|
|
|
|
|
|
// , {
|
|
|
// xtype: 'container',
|
|
|
// layout: 'hbox',
|
|
|
// defaultType: 'textfield',
|
|
|
// items: [this.comboxOP, this.comboxSALE, this.comboxTRADETYPE, this.comboxGOODSNAME, {
|
|
|
// fieldLabel: Zi.LAN., //'牌号',
|
|
|
// name: 'NUMBERPLATE'
|
|
|
// }]
|
|
|
// }, {
|
|
|
// xtype: 'container',
|
|
|
// layout: 'hbox',
|
|
|
// defaultType: 'textfield',
|
|
|
// items: [{
|
|
|
// fieldLabel: Zi.LAN., //'接单日期',
|
|
|
// format: 'Y-m-d',
|
|
|
// xtype: 'datefield',
|
|
|
// name: 'BSDATEbgn'
|
|
|
// }, {
|
|
|
// fieldLabel: Zi.LAN., //'到',
|
|
|
// format: 'Y-m-d',
|
|
|
// xtype: 'datefield',
|
|
|
// name: 'BSDATEend'
|
|
|
// }, this.comboxBSSTATUS, this.comboxFEESTATUS, this.comboxWMSTYPE]
|
|
|
// }
|
|
|
|
|
|
|
|
|
|
|
|
]//end items(fieldset 1)
|
|
|
}]//end root items
|
|
|
});
|
|
|
//#endregion formSearch
|
|
|
|
|
|
//#region formSearch2 隐藏查询面板
|
|
|
// this.formSearch2 = Ext.widget('form', {
|
|
|
// frame: true,
|
|
|
// region: 'north',
|
|
|
// bodyPadding: 0,
|
|
|
// fieldDefaults: {
|
|
|
// margins: '2 2 2 2',
|
|
|
// labelAlign: 'right',
|
|
|
// flex: 1, //所占列
|
|
|
// labelWidth: 70, //值 能够使 text框也是对齐状态
|
|
|
// msgTarget: 'qtip'//文本框显示的必填样式,修改这里的值msgTarget:"title" msgTarget:"under" msgTarget:"side"
|
|
|
// },
|
|
|
|
|
|
// items: [{//fieldset 1
|
|
|
// xtype: 'container',
|
|
|
// defaultType: 'textfield',
|
|
|
// layout: 'anchor',
|
|
|
// defaults: {
|
|
|
// anchor: '100%'
|
|
|
// },
|
|
|
// items: [{
|
|
|
// xtype: 'container',
|
|
|
// layout: 'hbox',
|
|
|
// defaultType: 'textfield',
|
|
|
// items: [this.comboxCustWmsCode, {
|
|
|
// fieldLabel: Zi.LAN., //'建单日期',
|
|
|
// format: 'Y-m-d',
|
|
|
// xtype: 'datefield',
|
|
|
// name: 'CREATETIMEbgn'
|
|
|
// }, {
|
|
|
// fieldLabel: Zi.LAN., //'到',
|
|
|
// format: 'Y-m-d',
|
|
|
// xtype: 'datefield',
|
|
|
// name: 'CREATETIMEend'
|
|
|
// }, this.comboxINPUTBY, this.comboxBSTYPE, {
|
|
|
// fieldLabel: Zi.LAN., //'集装箱',
|
|
|
// name: 'CNTRTOTAL'
|
|
|
// }]
|
|
|
// }, {
|
|
|
// xtype: 'container',
|
|
|
// layout: 'hbox',
|
|
|
// defaultType: 'textfield',
|
|
|
// items: [this.comboxCustWmsOutCode, this.comboxPORTLOAD, this.comboxPORTDISCHARGE, {
|
|
|
// fieldLabel: Zi.LAN., //'船名',
|
|
|
// name: 'VESSEL'
|
|
|
// }, {
|
|
|
// fieldLabel: Zi.LAN., //'航次',
|
|
|
// name: 'VOYNO'
|
|
|
// }]
|
|
|
// }, {
|
|
|
// xtype: 'container',
|
|
|
// layout: 'hbox',
|
|
|
// defaultType: 'textfield',
|
|
|
// items: [this.comboxCARRIER, {
|
|
|
// fieldLabel: Zi.LAN., //'箱使到期',
|
|
|
// format: 'Y-m-d',
|
|
|
// xtype: 'datefield',
|
|
|
// name: 'BMDDATEbgn'
|
|
|
// }, {
|
|
|
// fieldLabel: Zi.LAN., //'到',
|
|
|
// format: 'Y-m-d',
|
|
|
// xtype: 'datefield',
|
|
|
// name: 'BMDDATEend'
|
|
|
// }, {
|
|
|
// fieldLabel: Zi.LAN., //'搬倒日期',
|
|
|
// format: 'Y-m-d',
|
|
|
// xtype: 'datefield',
|
|
|
// name: 'MDTDATEbgn'
|
|
|
// }, {
|
|
|
// fieldLabel: Zi.LAN., //'到',
|
|
|
// format: 'Y-m-d',
|
|
|
// xtype: 'datefield',
|
|
|
// name: 'MDTDATEend'
|
|
|
// }]
|
|
|
// }, {
|
|
|
// xtype: 'container',
|
|
|
// layout: 'hbox',
|
|
|
// defaultType: 'textfield',
|
|
|
// items: [this.comboxGOODSTYPENAME, this.comboxTRADINGAGENCY, {
|
|
|
// fieldLabel: Zi.LAN., //'原产地',
|
|
|
// name: 'COUNTRYOFORIGIN'
|
|
|
// }, {
|
|
|
// fieldLabel: Zi.LAN., //'BALES',
|
|
|
// name: 'BALES'
|
|
|
// }, this.comboxTRUCKER]
|
|
|
// }, {
|
|
|
// xtype: 'container',
|
|
|
// layout: 'hbox',
|
|
|
// defaultType: 'textfield',
|
|
|
// items: [this.comboxCUSTOMSER, {
|
|
|
// fieldLabel: Zi.LAN., //'通关日期',
|
|
|
// format: 'Y-m-d',
|
|
|
// xtype: 'datefield',
|
|
|
// name: 'CUSTOMDATEbgn'
|
|
|
// }, {
|
|
|
// fieldLabel: Zi.LAN., //'到',
|
|
|
// format: 'Y-m-d',
|
|
|
// xtype: 'datefield',
|
|
|
// name: 'CUSTOMDATEend'
|
|
|
// }, {
|
|
|
// fieldLabel: Zi.LAN., //'申报日期',
|
|
|
// format: 'Y-m-d',
|
|
|
// xtype: 'datefield',
|
|
|
// name: 'UPDATETIMEbgn'
|
|
|
// }, {
|
|
|
// fieldLabel: Zi.LAN., //'到',
|
|
|
// format: 'Y-m-d',
|
|
|
// xtype: 'datefield',
|
|
|
// name: 'UPDATETIMEend'
|
|
|
// }]
|
|
|
// }, {
|
|
|
// xtype: 'container',
|
|
|
// layout: 'hbox',
|
|
|
// defaultType: 'textfield',
|
|
|
// items: [this.comboxINSPECTION, {
|
|
|
// fieldLabel: Zi.LAN., //'报检日期',
|
|
|
// format: 'Y-m-d',
|
|
|
// xtype: 'datefield',
|
|
|
// name: 'INSPECTIONDATEbgn'
|
|
|
// }, {
|
|
|
// fieldLabel: Zi.LAN., //'到',
|
|
|
// format: 'Y-m-d',
|
|
|
// xtype: 'datefield',
|
|
|
// name: 'INSPECTIONDATEend'
|
|
|
// }, {
|
|
|
// fieldLabel: Zi.LAN., //'交关税时间',
|
|
|
// format: 'Y-m-d',
|
|
|
// xtype: 'datefield',
|
|
|
// name: 'TARRIFSPAIEDTIEMbgn'
|
|
|
// }, {
|
|
|
// fieldLabel: Zi.LAN., //'到',
|
|
|
// format: 'Y-m-d',
|
|
|
// xtype: 'datefield',
|
|
|
// name: 'TARRIFSPAIEDTIEMend'
|
|
|
// }]
|
|
|
// }, {
|
|
|
// xtype: 'container',
|
|
|
// layout: 'hbox',
|
|
|
// defaultType: 'textfield',
|
|
|
// items: [this.comboxBSSOURCE, this.comboxBSSOURCEDETAIL, this.comboxBSTYPE, this.comboxBLTYPE, {
|
|
|
// fieldLabel: Zi.LAN., //'备注',
|
|
|
// name: 'REMARK'
|
|
|
// }]//, { xtype: 'hiddenfield'}
|
|
|
// }, {
|
|
|
// xtype: 'container',
|
|
|
// layout: 'hbox',
|
|
|
// defaultType: 'textfield',
|
|
|
// items: [{
|
|
|
// fieldLabel: Zi.LAN., //'发货人内容',
|
|
|
// name: 'SHIPPER'
|
|
|
// }, {
|
|
|
// fieldLabel: Zi.LAN., //'收货人内容',
|
|
|
// name: 'CONSIGNEE'
|
|
|
// }, {
|
|
|
// fieldLabel: Zi.LAN., //'通知人内容',
|
|
|
// name: 'NOTIFYPARTY'
|
|
|
// }, this.comboxCustENTERP, { xtype: 'hiddenfield'}]//, { xtype: 'hiddenfield'}
|
|
|
// }]//end items(fieldset 1)
|
|
|
// }]//end root items
|
|
|
// });
|
|
|
//#endregion formSearch2
|
|
|
|
|
|
//#region 按钮工具条
|
|
|
_this = this;
|
|
|
this.panelBtn = new Ext.Panel({
|
|
|
region: "north",
|
|
|
tbar: [{
|
|
|
text: Zi.LAN.btnadd, //"新建",
|
|
|
iconCls: "btnadd",
|
|
|
handler: function (button, event) {
|
|
|
this.OprationStatus = 'add';
|
|
|
DsOpenEditWin('/MvcShipping/MsOpSeai/Edit');
|
|
|
},
|
|
|
scope: this
|
|
|
}, {
|
|
|
text: Zi.LAN.copyadd, //"复制新建",
|
|
|
iconCls: "btnadd",
|
|
|
menu: [{
|
|
|
text: Zi.LAN.copyadd, //"复制新建",
|
|
|
iconCls: "btnadd",
|
|
|
handler: function (button, event) {
|
|
|
var selections = this.gridList.getSelectionModel().getSelection();
|
|
|
if (selections.length == 0) {
|
|
|
Ext.Msg.show({ title: Zi.LAN.TiShi, msg: Zi.LAN.QingXianXuanZeYeWu, icon: Ext.Msg.INFO, buttons: Ext.Msg.OK }); //'提示', '请先选择要复制的业务!'
|
|
|
return;
|
|
|
}
|
|
|
var record = selections[0];
|
|
|
this.SelectedRecord = record;
|
|
|
this.OprationStatus = 'copyadd';
|
|
|
DsOpenEditWin('/MvcShipping/MsOpSeai/Edit');
|
|
|
},
|
|
|
scope: this
|
|
|
}, {
|
|
|
text: Zi.LAN.copyadd + "(含费用)", //"复制新建",
|
|
|
iconCls: "btnadd",
|
|
|
handler: function (button, event) {
|
|
|
var selections = this.gridList.getSelectionModel().getSelection();
|
|
|
if (selections.length == 0) {
|
|
|
Ext.Msg.show({ title: Zi.LAN.TiShi, msg: Zi.LAN.QingXianXuanZeYeWu, icon: Ext.Msg.INFO, buttons: Ext.Msg.OK });
|
|
|
return;
|
|
|
}
|
|
|
var record = selections[0];
|
|
|
this.SelectedRecord = record;
|
|
|
this.OprationStatus = 'copyaddfee';
|
|
|
DsOpenEditWin('/MvcShipping/MsOpSeai/Edit');
|
|
|
},
|
|
|
scope: this
|
|
|
}],
|
|
|
scope: this
|
|
|
}, {
|
|
|
text: Zi.LAN.btndelete, //"删除",
|
|
|
iconCls: "btndelete",
|
|
|
handler: function (button, event) {
|
|
|
this.onDeleteClick(button, event);
|
|
|
},
|
|
|
scope: this
|
|
|
}, '-', {
|
|
|
text: Zi.LAN.btnrefresh, //"执行查询",
|
|
|
iconCls: "btnrefresh",
|
|
|
handler: function (button, event) {
|
|
|
this.onRefreshClick(button, event);
|
|
|
},
|
|
|
scope: this
|
|
|
}, {
|
|
|
text: Zi.LAN.btnreset, //"重置条件",
|
|
|
iconCls: "btnreset",
|
|
|
handler: function (button, event) {
|
|
|
this.onClearSql(button, event);
|
|
|
},
|
|
|
scope: this
|
|
|
}, '-', {
|
|
|
text: Zi.LAN.btnExportExcel, //"导出Excel",
|
|
|
id: "btnExportExcel",
|
|
|
iconCls: 'btnexportexcel',
|
|
|
handler: function (button, event) {
|
|
|
this.onExportClick(button, event);
|
|
|
},
|
|
|
scope: this
|
|
|
}, '-', {
|
|
|
text: Zi.LAN.ChuanDaiCangDan, //"船代舱单",
|
|
|
menu: [
|
|
|
{ text: Zi.LAN.CustomManifest, //"舱单申报",
|
|
|
handler: function (menu, event) {
|
|
|
_this.onCreateCustomClick(menu, event, 'CUSTOM');
|
|
|
}
|
|
|
}],
|
|
|
scope: this
|
|
|
}, '-', {
|
|
|
text: Zi.LAN.EdiExport, //"EDI报文导出",
|
|
|
menu: [{
|
|
|
text: Zi.LAN.WDEDI, //"外代EDI",
|
|
|
handler: function (menu, event) {
|
|
|
_this.onCreateEDIClick(menu, event, 'WDSEAIEDI');
|
|
|
}
|
|
|
}, {
|
|
|
text: Zi.LAN.IFTMBFEDI, //"交通部EDI",
|
|
|
handler: function (menu, event) {
|
|
|
_this.onCreateIFTMBFClick(menu, event);
|
|
|
}
|
|
|
}, {
|
|
|
text: Zi.LAN.DHLEDI, //"交通部EDI",
|
|
|
handler: function (menu, event) {
|
|
|
_this.onCreateDHLClick(menu, event);
|
|
|
}
|
|
|
}],
|
|
|
scope: this
|
|
|
},
|
|
|
'-',
|
|
|
{
|
|
|
text: Zi.LAN.ImportEdi, //"EDI导入",
|
|
|
iconCls: "btnexportexcel",
|
|
|
handler: function (button, event) {
|
|
|
this.onImportEdiClick(button, event);
|
|
|
},
|
|
|
scope: this
|
|
|
}, '-', {
|
|
|
text: Zi.LAN.btntest, //"保存列表样式",
|
|
|
id: "btntest",
|
|
|
menu: [{
|
|
|
text: Zi.LAN.SaveGridPanel, //"保存",
|
|
|
handler: function (button, event) {
|
|
|
this.girdcolums = DsTruck.SaveGridPanel(USERID, _this.formname, _this.gridList.columns, _this.girdcolums, 1, true);
|
|
|
}
|
|
|
}, {
|
|
|
text: Zi.LAN.SaveGridPanel2, //"初始化",
|
|
|
handler: function (menu, event) {
|
|
|
_this.InitGrid(_this.initgirdcolums);
|
|
|
_this.girdcolums = DsTruck.SaveGridPanel(USERID, _this.formname, _this.gridList.columns, _this.initgirdcolums, 21, true);
|
|
|
}
|
|
|
}],
|
|
|
scope: this
|
|
|
}, '-',
|
|
|
{ text: Zi.LAN.btnprint, //"打印",
|
|
|
iconCls: 'btnprint',
|
|
|
menu: [
|
|
|
{ text: Zi.LAN.Print, //"全部",
|
|
|
handler: function (menu, event) {
|
|
|
_this.Print();
|
|
|
}
|
|
|
}, { text: Zi.LAN.PrintSelect, //"选择打印",
|
|
|
handler: function (menu, event) {
|
|
|
_this.PrintSelect();
|
|
|
}
|
|
|
}],
|
|
|
|
|
|
scope: this
|
|
|
}, '-', {
|
|
|
text: Zi.LAN.OtherCaoZuo, //"其他操作",
|
|
|
menu: [
|
|
|
{ text: Zi.LAN.UpOpStatus, //"批量状态更新",
|
|
|
handler: function (menu, event) {
|
|
|
_this.onUpOpStatusClick(menu, event, 1);
|
|
|
}
|
|
|
}, { text: Zi.LAN.FeeEdit, //"费用编辑",
|
|
|
handler: function (menu, event) {
|
|
|
_this.onFeeEditClick(menu, event);
|
|
|
}
|
|
|
}, { text: Zi.LAN.PiLiangSubmit, //"批量费用提交",
|
|
|
handler: function (menu, event) {
|
|
|
_this.onPiLiangSubmitClick(menu, event, 1);
|
|
|
}
|
|
|
}, { text: "放单通知", //"放单通知",
|
|
|
handler: function (menu, event) {
|
|
|
_this.onFDTZClick(menu, event);
|
|
|
}
|
|
|
}, { text: Zi.LAN.YinRuFenGongSiWeiTuo, //"引入分公司委托",
|
|
|
handler: function (menu, event) {
|
|
|
_this.onImpSeaeClick(menu, event);
|
|
|
}
|
|
|
}, {
|
|
|
text: Zi.LAN.PiLiangAddFeeTemplate, //"批量费用提交",
|
|
|
handler: function (menu, event) {
|
|
|
_this.onPiLiangAddFeeTemplate(menu, event, 1);
|
|
|
}
|
|
|
}, {
|
|
|
text: '批量整票提交', //"批量整票提交",
|
|
|
handler: function (menu, event) {
|
|
|
_this.onPiLiangZhengPiaoTiJiaoClick(menu, event, 1);
|
|
|
}
|
|
|
}, {
|
|
|
text: '取消整票提交', //"批量整票提交",
|
|
|
handler: function (menu, event) {
|
|
|
_this.onPiLiangZhengPiaoTiJiaoClick(menu, event, 0);
|
|
|
}
|
|
|
}, {
|
|
|
text: Zi.LAN.MAKEYX, //"生成押箱业务",
|
|
|
handler: function (menu, event) {
|
|
|
_this.onaddYXClick();
|
|
|
}
|
|
|
}, '-', {
|
|
|
text: '查看罐箱业务成本核算',
|
|
|
handler: function (menu, event) {
|
|
|
_this.onCheckCtnApply();
|
|
|
}
|
|
|
}],
|
|
|
scope: this
|
|
|
}, '-', {
|
|
|
text: '显示Cover',
|
|
|
id: 'btnCover',
|
|
|
handler: function (button, event) {
|
|
|
this.readingPaneChange(button);
|
|
|
},
|
|
|
scope: this
|
|
|
}, {
|
|
|
text: '创建跑单',
|
|
|
id: 'btnRunBill',
|
|
|
handler: function (button, event) {
|
|
|
|
|
|
this.onCreateRunBill(button, event);
|
|
|
},
|
|
|
scope: this
|
|
|
}, {
|
|
|
iconCls: "btnotherinf",
|
|
|
menu: [{
|
|
|
text: "青岛港单票查询", //"青岛港单票查询",
|
|
|
handler: function (menu, event) {
|
|
|
_this.onQQCTUBILLClick(menu, event);
|
|
|
}
|
|
|
}, {
|
|
|
text: Zi.LAN.GETCARRIER, //"船公司运踪",
|
|
|
handler: function (menu, event) {
|
|
|
_this.onGETCARRIERClick(menu, event);
|
|
|
}
|
|
|
}
|
|
|
]
|
|
|
}]
|
|
|
});
|
|
|
//#endregion
|
|
|
|
|
|
//#region 合计列表
|
|
|
|
|
|
this.SumField = [
|
|
|
{ name: 'NOBILL', type: 'number' },
|
|
|
{ name: 'TEU', type: 'number' },
|
|
|
{ name: 'KGS', type: 'number' },
|
|
|
{ name: 'NETKGS', type: 'number' },
|
|
|
{ name: 'PKGS', type: 'number' },
|
|
|
{ name: 'CBM', type: 'number' }
|
|
|
];
|
|
|
|
|
|
this.storeSumList = Ext.create('Ext.data.Store', {
|
|
|
pageSize: this.PageSize,
|
|
|
fields: this.SumField,
|
|
|
remoteSort: true,
|
|
|
proxy: {
|
|
|
type: 'ajax',
|
|
|
url: '/MvcShipping/MsOpSeai/GetCtnSum',
|
|
|
reader: {
|
|
|
id: '',
|
|
|
root: 'data',
|
|
|
totalProperty: 'totalCount'
|
|
|
}
|
|
|
}
|
|
|
});
|
|
|
|
|
|
this.girdcolumsSum = [{
|
|
|
sortable: true,
|
|
|
dataIndex: 'NOBILL',
|
|
|
header: Zi.LAN.NOBILL2, //'票数',
|
|
|
align: 'right',
|
|
|
width: 80
|
|
|
}, {
|
|
|
sortable: true,
|
|
|
dataIndex: 'TEU',
|
|
|
header: Zi.LAN.TEU, //'TEU',
|
|
|
align: 'right',
|
|
|
width: 80
|
|
|
}, {
|
|
|
sortable: true,
|
|
|
dataIndex: 'PKGS',
|
|
|
header: Zi.LAN.PKGS, //'件数',
|
|
|
renderer: function (value, cellmeta, record, rowIndex, columnIndex, store) { try { var lsValue = usMoney(value, 2, '', false); if (lsValue != "NaN") { value = lsValue; if (parseFloat(lsValue) < 0) { return '<SPAN style="COLOR: red">' + lsValue + '</SPAN>'; } } else { return value; } } catch (e) { return value; } return value; },
|
|
|
align: 'right',
|
|
|
width: 80
|
|
|
}, {
|
|
|
sortable: true,
|
|
|
dataIndex: 'KGS',
|
|
|
header: Zi.LAN.KGS2, //'毛重',
|
|
|
renderer: function (value, cellmeta, record, rowIndex, columnIndex, store) { try { var lsValue = usMoney(value, 2, '', false); if (lsValue != "NaN") { value = lsValue; if (parseFloat(lsValue) < 0) { return '<SPAN style="COLOR: red">' + lsValue + '</SPAN>'; } } else { return value; } } catch (e) { return value; } return value; },
|
|
|
align: 'right',
|
|
|
width: 80
|
|
|
}, {
|
|
|
sortable: true,
|
|
|
dataIndex: 'NETKGS',
|
|
|
header: Zi.LAN.NETWEIGHT, //'毛重',
|
|
|
renderer: function (value, cellmeta, record, rowIndex, columnIndex, store) { try { var lsValue = usMoney(value, 2, '', false); if (lsValue != "NaN") { value = lsValue; if (parseFloat(lsValue) < 0) { return '<SPAN style="COLOR: red">' + lsValue + '</SPAN>'; } } else { return value; } } catch (e) { return value; } return value; },
|
|
|
align: 'right',
|
|
|
width: 80
|
|
|
}, {
|
|
|
sortable: true,
|
|
|
dataIndex: 'CBM',
|
|
|
header: Zi.LAN.CBM, //'尺码',
|
|
|
renderer: function (value, cellmeta, record, rowIndex, columnIndex, store) { try { var lsValue = usMoney(value, 2, '', false); if (lsValue != "NaN") { value = lsValue; if (parseFloat(lsValue) < 0) { return '<SPAN style="COLOR: red">' + lsValue + '</SPAN>'; } } else { return value; } } catch (e) { return value; } return value; },
|
|
|
align: 'right',
|
|
|
width: 80
|
|
|
}, {
|
|
|
sortable: true,
|
|
|
dataIndex: 'WMSCTNNUM',
|
|
|
header: Zi.LAN.WMSCTNNUM, //'TEU',
|
|
|
align: 'right',
|
|
|
width: 80
|
|
|
}
|
|
|
|
|
|
];
|
|
|
|
|
|
this.gridListSum = new Ext.grid.GridPanel({
|
|
|
store: this.storeSumList,
|
|
|
enableHdMenu: false,
|
|
|
region: 'center',
|
|
|
loadMask: { msg: Zi.LAN.ShuJuJiaZaiZhongQingShaoDeng },
|
|
|
trackMouseOver: true,
|
|
|
disableSelection: false,
|
|
|
columns: this.girdcolumsSum
|
|
|
});
|
|
|
|
|
|
this.panelSum = new Ext.Panel({
|
|
|
//title: '合 计',
|
|
|
layout: "border",
|
|
|
height: 70,
|
|
|
region: 'south',
|
|
|
margin: '0 0',
|
|
|
frame: true,
|
|
|
items: [this.gridListSum]
|
|
|
});
|
|
|
//#endregion
|
|
|
|
|
|
//#region 页面框架
|
|
|
// this.panelSearch = new Ext.Panel({
|
|
|
// layout: "border",
|
|
|
// region: "north",
|
|
|
// height: 215,
|
|
|
// autoSize: true,
|
|
|
// hidden: true,
|
|
|
// items: [this.formSearch2]
|
|
|
// });
|
|
|
|
|
|
this.panelTop = new Ext.Panel({
|
|
|
layout: "border",
|
|
|
region: "north",
|
|
|
height: 75,
|
|
|
items: [this.panelBtn, this.formSearch]
|
|
|
});
|
|
|
|
|
|
Ext.apply(this, {
|
|
|
items: [this.panelTop, this.panelSearch, this.gridList, this.panelSum, this.createEast()]
|
|
|
});
|
|
|
|
|
|
//#endregion
|
|
|
|
|
|
//#region 其他
|
|
|
var myDate = new Date();
|
|
|
var mydatestr = Ext.util.Format.date(myDate, 'Y-m');
|
|
|
this.sqlcontext = " B.ACCDATE='" + mydatestr + "'";
|
|
|
|
|
|
this.storeCtnList = Ext.create('Ext.data.Store', {
|
|
|
pageSize: this.PageSize,
|
|
|
fields: [
|
|
|
{ name: 'CTNALL', type: 'string' }
|
|
|
],
|
|
|
remoteSort: true,
|
|
|
proxy: {
|
|
|
type: 'ajax',
|
|
|
url: '/MvcShipping/MsOpSeai/GetCtnList',
|
|
|
reader: {
|
|
|
id: '',
|
|
|
root: 'data',
|
|
|
totalProperty: 'totalCount'
|
|
|
}
|
|
|
}
|
|
|
});
|
|
|
|
|
|
this.InitGrid(this.girdcolums);
|
|
|
|
|
|
this.storeList.load({
|
|
|
params: { start: 0, limit: this.PageSize, sort: '', condition: _this.sqlcontext },
|
|
|
waitMsg: Zi.LAN.ZhengZaiChaXunShuJu, //"正在查询数据...",
|
|
|
scope: this
|
|
|
});
|
|
|
|
|
|
this.onRefreshSumClick(_this.sqlcontext);
|
|
|
|
|
|
this.storeList.on('beforeload', function (store) {
|
|
|
|
|
|
Ext.apply(store.proxy.extraParams, { condition: _this.sqlcontext });
|
|
|
}, this);
|
|
|
//#endregion
|
|
|
|
|
|
//#region 外代 EDI
|
|
|
this.CheckNoCtn = new Ext.form.Checkbox({
|
|
|
fieldLabel: Zi.LAN.CheckNoCtn, //'不输出箱号封号',
|
|
|
checked: true
|
|
|
});
|
|
|
this.CheckBill = new Ext.form.Checkbox({
|
|
|
fieldLabel: Zi.LAN.CheckBill, //'货代提单',
|
|
|
checked: false
|
|
|
});
|
|
|
this.formEdiShow = Ext.widget('form', {
|
|
|
frame: true,
|
|
|
region: 'center',
|
|
|
bodyPadding: 5,
|
|
|
fieldDefaults: {
|
|
|
margins: '2 2 2 2',
|
|
|
labelAlign: 'right',
|
|
|
flex: 1,
|
|
|
labelWidth: 90,
|
|
|
msgTarget: 'qtip'
|
|
|
},
|
|
|
|
|
|
items: [
|
|
|
{//fieldset 1
|
|
|
xtype: 'container',
|
|
|
defaultType: 'textfield',
|
|
|
layout: 'anchor',
|
|
|
defaults: {
|
|
|
anchor: '100%'
|
|
|
},
|
|
|
items: [{
|
|
|
xtype: 'container',
|
|
|
layout: 'hbox',
|
|
|
defaultType: 'textfield',
|
|
|
items: [{
|
|
|
xtype: 'radiogroup',
|
|
|
fieldLabel: Zi.LAN.rFILETYPE, //'报文类型',
|
|
|
id: 'rFILETYPE',
|
|
|
defaults: {
|
|
|
flex: 1
|
|
|
},
|
|
|
layout: 'hbox',
|
|
|
items: [
|
|
|
{
|
|
|
boxLabel: Zi.LAN.FILETYPE_B, //'订舱',
|
|
|
name: 'FILETYPE',
|
|
|
checked: true,
|
|
|
inputValue: 'B',
|
|
|
id: 'radio1'
|
|
|
}, {
|
|
|
boxLabel: Zi.LAN.FILETYPE_E, //'确认',
|
|
|
name: 'FILETYPE',
|
|
|
inputValue: 'E',
|
|
|
id: 'radio2'
|
|
|
}
|
|
|
]
|
|
|
}
|
|
|
]
|
|
|
}, {
|
|
|
xtype: 'container',
|
|
|
layout: 'hbox',
|
|
|
defaultType: 'textfield',
|
|
|
items: [{
|
|
|
xtype: 'radiogroup',
|
|
|
fieldLabel: Zi.LAN.rFILEROLE, //'文件功能',
|
|
|
id: 'rFILEROLE',
|
|
|
defaults: {
|
|
|
flex: 1
|
|
|
},
|
|
|
layout: 'hbox',
|
|
|
items: [
|
|
|
{
|
|
|
boxLabel: Zi.LAN.FILEROLE_YS, //'原始',
|
|
|
name: 'FILEROLE',
|
|
|
inputValue: '9',
|
|
|
checked: true,
|
|
|
id: 'radio3'
|
|
|
}, {
|
|
|
boxLabel: Zi.LAN.FILEROLE_ZJ, //'增加',
|
|
|
name: 'FILEROLE',
|
|
|
inputValue: '2',
|
|
|
id: 'radio4'
|
|
|
}, {
|
|
|
boxLabel: Zi.LAN.FILEROLE_SC, //'删除',
|
|
|
name: 'FILEROLE',
|
|
|
inputValue: '3',
|
|
|
id: 'radio5'
|
|
|
}, {
|
|
|
boxLabel: Zi.LAN.FILEROLE_GX, //'更新',
|
|
|
name: 'FILEROLE',
|
|
|
inputValue: '4',
|
|
|
id: 'radio6'
|
|
|
}
|
|
|
]
|
|
|
}
|
|
|
]
|
|
|
}, , {
|
|
|
xtype: 'container',
|
|
|
layout: 'hbox',
|
|
|
defaultType: 'textfield',
|
|
|
items: [
|
|
|
this.CheckNoCtn, this.CheckBill
|
|
|
|
|
|
]
|
|
|
}
|
|
|
]//end items(fieldset 1)
|
|
|
}//end fieldset 1
|
|
|
]//end root items
|
|
|
});
|
|
|
|
|
|
me = this;
|
|
|
this.winEDIShow = Ext.create('Ext.window.Window', {
|
|
|
title: Zi.LAN.winEDIShow, //"生成EDI",
|
|
|
width: 450,
|
|
|
//height : 120,
|
|
|
//plain : true,
|
|
|
iconCls: "addicon",
|
|
|
resizable: false,
|
|
|
// 是否可以拖动
|
|
|
// draggable:false,
|
|
|
collapsible: true, // 允许缩放条
|
|
|
closeAction: 'close',
|
|
|
closable: true,
|
|
|
modal: 'true',
|
|
|
buttonAlign: "center",
|
|
|
bodyStyle: "padding:0 0 0 0",
|
|
|
items: [this.formEdiShow],
|
|
|
buttons: [{
|
|
|
text: Zi.LAN.ShangChuanEdi, //"上传EDI",
|
|
|
minWidth: 70,
|
|
|
handler: function () {
|
|
|
var cgFILETYPE = Ext.getCmp('rFILETYPE');
|
|
|
var FILETYPE = cgFILETYPE.getValue();
|
|
|
var cgFILEROLE = Ext.getCmp('rFILEROLE');
|
|
|
var FILEROLE = cgFILEROLE.getValue();
|
|
|
var IsNoCtn = 0;
|
|
|
if (me.CheckNoCtn.checked)
|
|
|
IsNoCtn = 1;
|
|
|
var IsBill = 0;
|
|
|
if (me.CheckBill.checked)
|
|
|
IsBill = 1;
|
|
|
|
|
|
me.onSendEDI(me.editype, FILETYPE.FILETYPE, FILEROLE.FILEROLE, IsBill, IsNoCtn);
|
|
|
}
|
|
|
}, {
|
|
|
text: Zi.LAN.BaoCunEdiWenJian, //"保存EDI文件",
|
|
|
minWidth: 70,
|
|
|
handler: function () {
|
|
|
var cgFILETYPE = Ext.getCmp('rFILETYPE');
|
|
|
var FILETYPE = cgFILETYPE.getValue();
|
|
|
var cgFILEROLE = Ext.getCmp('rFILEROLE');
|
|
|
var FILEROLE = cgFILEROLE.getValue();
|
|
|
var IsNoCtn = 0;
|
|
|
if (me.CheckNoCtn.checked)
|
|
|
IsNoCtn = 1;
|
|
|
var IsBill = 0;
|
|
|
if (me.CheckBill.checked)
|
|
|
IsBill = 1;
|
|
|
|
|
|
me.onSaveEDI(me.editype, FILETYPE.FILETYPE, FILEROLE.FILEROLE, IsBill, IsNoCtn);
|
|
|
}
|
|
|
}, {
|
|
|
text: Zi.LAN.GuanBi, //"关闭",
|
|
|
minWidth: 70,
|
|
|
handler: function () {
|
|
|
me.winEDIShow.close();
|
|
|
}
|
|
|
}]
|
|
|
});
|
|
|
//#endregion
|
|
|
|
|
|
//#region 交通部EDI窗体
|
|
|
this.formIFTMBFShow = Ext.widget('form', {
|
|
|
frame: true,
|
|
|
region: 'center',
|
|
|
bodyPadding: 5,
|
|
|
fieldDefaults: {
|
|
|
margins: '2 2 2 2',
|
|
|
labelAlign: 'right',
|
|
|
flex: 1,
|
|
|
labelWidth: 90,
|
|
|
msgTarget: 'qtip'
|
|
|
},
|
|
|
|
|
|
items: [{//fieldset 1
|
|
|
xtype: 'container',
|
|
|
defaultType: 'textfield',
|
|
|
layout: 'anchor',
|
|
|
defaults: {
|
|
|
anchor: '100%'
|
|
|
},
|
|
|
items: [{
|
|
|
xtype: 'container',
|
|
|
layout: 'hbox',
|
|
|
defaultType: 'textfield',
|
|
|
items: [{
|
|
|
xtype: 'radiogroup',
|
|
|
fieldLabel: Zi.LAN.jtbFILEROLE, //'文件功能',
|
|
|
id: 'jtbFILEROLE',
|
|
|
defaults: { flex: 1 },
|
|
|
layout: 'hbox',
|
|
|
items: [{
|
|
|
boxLabel: Zi.LAN.FILEROLE_YS, //'原始',
|
|
|
name: 'FILEROLE',
|
|
|
inputValue: '9',
|
|
|
checked: true
|
|
|
}, {
|
|
|
boxLabel: Zi.LAN.FILEROLE_GX, //'更新',
|
|
|
name: 'FILEROLE',
|
|
|
inputValue: '5'
|
|
|
}, {
|
|
|
boxLabel: Zi.LAN.FILEROLE_SC, //'删除',
|
|
|
name: 'FILEROLE',
|
|
|
inputValue: '4'
|
|
|
}]
|
|
|
}
|
|
|
]
|
|
|
}, {
|
|
|
xtype: 'container',
|
|
|
layout: 'hbox',
|
|
|
defaultType: 'textfield',
|
|
|
items: [{
|
|
|
xtype: 'radiogroup',
|
|
|
fieldLabel: Zi.LAN.CARRIER, //'船公司',
|
|
|
columns: 2,
|
|
|
vertical: true,
|
|
|
id: 'jtbCARRIER',
|
|
|
items: [{
|
|
|
boxLabel: Zi.LAN.NBCDI, //'宁波船代(NBCDI)',
|
|
|
name: 'CARRIER',
|
|
|
inputValue: 'NBCDI',
|
|
|
checked: true
|
|
|
}, {
|
|
|
boxLabel: Zi.LAN.SHCDI, //'上海船代(SHCDI)',
|
|
|
name: 'CARRIER',
|
|
|
inputValue: 'SHCDI'
|
|
|
}]
|
|
|
}
|
|
|
]
|
|
|
}]//end items(fieldset 1)
|
|
|
}]//end root items
|
|
|
});
|
|
|
|
|
|
me = this;
|
|
|
this.winIFTMBFShow = Ext.create('Ext.window.Window', {
|
|
|
title: Zi.LAN.winIFTMBFShow, //"生成交通部报文",
|
|
|
width: 450,
|
|
|
//height : 120,
|
|
|
//plain : true,
|
|
|
iconCls: "addicon",
|
|
|
resizable: false,
|
|
|
// 是否可以拖动
|
|
|
// draggable:false,
|
|
|
collapsible: true, // 允许缩放条
|
|
|
closeAction: 'close',
|
|
|
closable: true,
|
|
|
modal: 'true',
|
|
|
buttonAlign: "center",
|
|
|
bodyStyle: "padding:0 0 0 0",
|
|
|
items: [this.formIFTMBFShow],
|
|
|
buttons: [{
|
|
|
text: Zi.LAN.ShangChuanEdi, //"上传EDI",
|
|
|
minWidth: 70,
|
|
|
handler: function () {
|
|
|
var cgFILEROLE = Ext.getCmp('jtbFILEROLE');
|
|
|
var FILEROLE = cgFILEROLE.getValue();
|
|
|
var cgCARRIER = Ext.getCmp('jtbCARRIER');
|
|
|
var CARRIER = cgCARRIER.getValue();
|
|
|
me.onSendIFTMBF(FILEROLE.FILEROLE, CARRIER.CARRIER);
|
|
|
}
|
|
|
}, {
|
|
|
text: Zi.LAN.BaoCunEdiWenJian, //"保存EDI文件",
|
|
|
minWidth: 70,
|
|
|
handler: function () {
|
|
|
var cgFILEROLE = Ext.getCmp('jtbFILEROLE');
|
|
|
var FILEROLE = cgFILEROLE.getValue();
|
|
|
var cgCARRIER = Ext.getCmp('jtbCARRIER');
|
|
|
var CARRIER = cgCARRIER.getValue();
|
|
|
me.onSaveIFTMBF(FILEROLE.FILEROLE, CARRIER.CARRIER);
|
|
|
}
|
|
|
}, {
|
|
|
text: Zi.LAN.GuanBi, //"关闭",
|
|
|
minWidth: 70,
|
|
|
handler: function () {
|
|
|
me.winIFTMBFShow.close();
|
|
|
}
|
|
|
}]
|
|
|
});
|
|
|
//#endregion
|
|
|
|
|
|
|
|
|
//#region DHL EDI窗体
|
|
|
this.formDHLShow = Ext.widget('form', {
|
|
|
frame: true,
|
|
|
region: 'center',
|
|
|
bodyPadding: 5,
|
|
|
fieldDefaults: {
|
|
|
margins: '2 2 2 2',
|
|
|
labelAlign: 'right',
|
|
|
flex: 1,
|
|
|
labelWidth: 90,
|
|
|
msgTarget: 'qtip'
|
|
|
},
|
|
|
|
|
|
items: [{//fieldset 1
|
|
|
xtype: 'container',
|
|
|
defaultType: 'textfield',
|
|
|
layout: 'anchor',
|
|
|
defaults: {
|
|
|
anchor: '100%'
|
|
|
},
|
|
|
items: [{
|
|
|
xtype: 'container',
|
|
|
layout: 'hbox',
|
|
|
defaultType: 'textfield',
|
|
|
items: [{
|
|
|
xtype: 'radiogroup',
|
|
|
fieldLabel: Zi.LAN.jtbFILEROLE, //'文件功能',
|
|
|
id: 'dhlFILEROLE',
|
|
|
defaults: { flex: 1 },
|
|
|
layout: 'hbox',
|
|
|
items: [{
|
|
|
boxLabel: Zi.LAN.FILEROLE_DOS, //'原始',
|
|
|
name: 'FILEROLE',
|
|
|
inputValue: 'DOS',
|
|
|
checked: true
|
|
|
}, {
|
|
|
boxLabel: Zi.LAN.FILEROLE_CLC, //'更新',
|
|
|
name: 'FILEROLE',
|
|
|
inputValue: 'CLC'
|
|
|
}, {
|
|
|
boxLabel: Zi.LAN.FILEROLE_GOU, //'更新',
|
|
|
name: 'FILEROLE',
|
|
|
inputValue: 'GOU'
|
|
|
}]
|
|
|
}
|
|
|
]
|
|
|
}]//end items(fieldset 1)
|
|
|
}]//end root items
|
|
|
});
|
|
|
|
|
|
me = this;
|
|
|
this.winDHLShow = Ext.create('Ext.window.Window', {
|
|
|
title: Zi.LAN.winDHLShow, //"生成交通部报文",
|
|
|
width: 450,
|
|
|
//height : 120,
|
|
|
//plain : true,
|
|
|
iconCls: "addicon",
|
|
|
resizable: false,
|
|
|
// 是否可以拖动
|
|
|
// draggable:false,
|
|
|
collapsible: true, // 允许缩放条
|
|
|
closeAction: 'close',
|
|
|
closable: true,
|
|
|
modal: 'true',
|
|
|
buttonAlign: "center",
|
|
|
bodyStyle: "padding:0 0 0 0",
|
|
|
items: [this.formDHLShow],
|
|
|
buttons: [{
|
|
|
text: Zi.LAN.ShangChuanEdi, //"上传EDI",
|
|
|
minWidth: 70,
|
|
|
handler: function () {
|
|
|
var cgFILEROLE = Ext.getCmp('dhlFILEROLE');
|
|
|
var FILEROLE = cgFILEROLE.getValue();
|
|
|
me.onSendDHL(FILEROLE.FILEROLE);
|
|
|
}
|
|
|
}, {
|
|
|
text: Zi.LAN.BaoCunEdiWenJian, //"保存EDI文件",
|
|
|
minWidth: 70,
|
|
|
handler: function () {
|
|
|
var cgFILEROLE = Ext.getCmp('dhlFILEROLE');
|
|
|
var FILEROLE = cgFILEROLE.getValue();
|
|
|
me.onSaveDHL(FILEROLE.FILEROLE);
|
|
|
}
|
|
|
}, {
|
|
|
text: Zi.LAN.GuanBi, //"关闭",
|
|
|
minWidth: 70,
|
|
|
handler: function () {
|
|
|
me.winDHLShow.close();
|
|
|
}
|
|
|
}]
|
|
|
});
|
|
|
//#endregion
|
|
|
|
|
|
|
|
|
//#region 下载窗体
|
|
|
this.formDownloadShow = Ext.widget('form', {
|
|
|
frame: true,
|
|
|
region: 'center',
|
|
|
height: 100,
|
|
|
bodyPadding: 5,
|
|
|
fieldDefaults: {
|
|
|
margins: '2 2 2 2',
|
|
|
labelAlign: 'right',
|
|
|
flex: 1,
|
|
|
labelWidth: 90,
|
|
|
msgTarget: 'qtip'
|
|
|
},
|
|
|
|
|
|
items: [{//fieldset 1
|
|
|
xtype: 'container',
|
|
|
defaultType: 'textfield',
|
|
|
layout: 'anchor',
|
|
|
id: 'downloadfile',
|
|
|
defaults: {
|
|
|
anchor: '100%'
|
|
|
},
|
|
|
items: [{
|
|
|
xtype: 'label',
|
|
|
html: '',
|
|
|
width: 120,
|
|
|
text: ''
|
|
|
}]//end items(fieldset 1)
|
|
|
}]//end root items
|
|
|
});
|
|
|
|
|
|
me = this;
|
|
|
this.winDownloadShow = Ext.create('Ext.window.Window', {
|
|
|
title: Zi.LAN.XiaZaiWenJian, //"下载文件",
|
|
|
width: 450,
|
|
|
height: 120,
|
|
|
//plain : true,
|
|
|
iconCls: "addicon",
|
|
|
resizable: false,
|
|
|
// 是否可以拖动
|
|
|
// draggable:false,
|
|
|
collapsible: true, // 允许缩放条
|
|
|
closeAction: 'close',
|
|
|
closable: true,
|
|
|
modal: 'true',
|
|
|
buttonAlign: "center",
|
|
|
bodyStyle: "padding:0 0 0 0",
|
|
|
items: [this.formDownloadShow],
|
|
|
buttons: [{
|
|
|
text: Zi.LAN.GuanBi, //"关闭",
|
|
|
minWidth: 70,
|
|
|
handler: function () {
|
|
|
me.winDownloadShow.close();
|
|
|
}
|
|
|
}]
|
|
|
});
|
|
|
|
|
|
//#endregion
|
|
|
|
|
|
|
|
|
//#region 放单通知 可放单
|
|
|
//this.gridList.addListener('itemcontextmenu', this.itemcontextmenu);
|
|
|
|
|
|
|
|
|
Ext.Ajax.request({
|
|
|
waitMsg: '',
|
|
|
url: '/MvcShipping/MsSysParamSet/GetData',
|
|
|
params: {
|
|
|
condition: "PARAMNAME='BLMUSTBEQR'"
|
|
|
},
|
|
|
callback: function (options, success, response) {
|
|
|
if (success) {
|
|
|
var result = Ext.JSON.decode(response.responseText);
|
|
|
if (result.Success != true) {
|
|
|
|
|
|
} else {
|
|
|
var data = result.data;
|
|
|
if (data.PARAMVALUE == '1') {
|
|
|
this.BLMUSTBEQR = 1;
|
|
|
} else {
|
|
|
|
|
|
}
|
|
|
|
|
|
}
|
|
|
} else {
|
|
|
|
|
|
}
|
|
|
},
|
|
|
scope: this
|
|
|
});
|
|
|
|
|
|
Ext.Ajax.request({
|
|
|
waitMsg: '',
|
|
|
url: '/MvcShipping/MsSysParamSet/GetData',
|
|
|
params: {
|
|
|
condition: "PARAMNAME='USEDSINTERFACE'"
|
|
|
},
|
|
|
callback: function (options, success, response) {
|
|
|
if (success) {
|
|
|
var result = Ext.JSON.decode(response.responseText);
|
|
|
if (result.Success != true) {
|
|
|
|
|
|
} else {
|
|
|
var data = result.data;
|
|
|
if (data.PARAMVALUE == '1') {
|
|
|
this.USEDSINTERFACE = 1;
|
|
|
} else {
|
|
|
|
|
|
}
|
|
|
|
|
|
}
|
|
|
} else {
|
|
|
|
|
|
}
|
|
|
},
|
|
|
scope: this
|
|
|
});
|
|
|
|
|
|
|
|
|
this.formReason = Ext.widget('form', {
|
|
|
frame: true,
|
|
|
region: 'center',
|
|
|
bodyPadding: 5,
|
|
|
bodyStyle: "padding:0 0 0 0;background:#FFF;",
|
|
|
fieldDefaults: {
|
|
|
margins: '2 2 2 2',
|
|
|
labelAlign: 'right',
|
|
|
flex: 1,
|
|
|
labelWidth: 45,
|
|
|
msgTarget: 'qtip'
|
|
|
},
|
|
|
items: [
|
|
|
{
|
|
|
xtype: 'label',
|
|
|
name: 'FDINFO',
|
|
|
id: "FDINFO",
|
|
|
padding: '0 0 0 0',
|
|
|
html: "",
|
|
|
height: 130,
|
|
|
width: 400
|
|
|
}, {
|
|
|
fieldLabel: '备注', //'备注', id: "REASON",
|
|
|
xtype: 'textareafield',
|
|
|
id: 'REASON',
|
|
|
name: 'REASON', width: 450, height: 50,
|
|
|
listeners: {
|
|
|
change: function (field, eOpts) {
|
|
|
|
|
|
if (field.lastValue != "") {
|
|
|
|
|
|
//this.formHead.getForm().findField('STOCKDATE_1').setValue(field.rawValue);
|
|
|
|
|
|
}
|
|
|
|
|
|
},
|
|
|
scope: this
|
|
|
}
|
|
|
}]
|
|
|
});
|
|
|
var _this2 = this;
|
|
|
this.winFDTZShow = Ext.create('Ext.window.Window', {
|
|
|
id: "winFDTZShow",
|
|
|
title: "放单通知", //"放单通知",
|
|
|
width: 450,
|
|
|
height: 260,
|
|
|
//plain : true,
|
|
|
iconCls: "addicon",
|
|
|
resizable: false,
|
|
|
// 是否可以拖动
|
|
|
// draggable:false,
|
|
|
collapsible: true, // 允许缩放条
|
|
|
closeAction: 'close',
|
|
|
closable: true,
|
|
|
modal: 'true',
|
|
|
buttonAlign: "center",
|
|
|
bodyStyle: "padding:0 0 0 0;background:#FFF;",
|
|
|
items: [this.formReason],
|
|
|
buttons: [
|
|
|
{
|
|
|
text: "确定", //"确定",
|
|
|
minWidth: 70,
|
|
|
handler: function () {
|
|
|
_this2.DoFDTZ(Ext.getCmp("REASON").getRawValue());
|
|
|
}
|
|
|
}, {
|
|
|
text: "取消", //"取消",
|
|
|
minWidth: 70,
|
|
|
handler: function () {
|
|
|
_this2.winFDTZShow.close();
|
|
|
}
|
|
|
}, {
|
|
|
text: "打印", //"打印",
|
|
|
minWidth: 70,
|
|
|
handler: function () {
|
|
|
_this2.Print_FDTZ();
|
|
|
}
|
|
|
}]
|
|
|
});
|
|
|
//#endregion
|
|
|
|
|
|
|
|
|
this.formMBLPLQueryShow = Ext.widget('form', {
|
|
|
frame: true,
|
|
|
region: 'center',
|
|
|
bodyPadding: 5,
|
|
|
fieldDefaults: {
|
|
|
margins: '2 2 2 2',
|
|
|
labelAlign: 'right',
|
|
|
flex: 1,
|
|
|
labelWidth: 85,
|
|
|
msgTarget: 'qtip'
|
|
|
},
|
|
|
|
|
|
items: [
|
|
|
{//fieldset 1
|
|
|
xtype: 'container',
|
|
|
defaultType: 'textfield',
|
|
|
layout: 'anchor',
|
|
|
defaults: {
|
|
|
anchor: '100%'
|
|
|
},
|
|
|
items: [{
|
|
|
xtype: 'container',
|
|
|
layout: 'hbox',
|
|
|
defaultType: 'textfield',
|
|
|
items: [{
|
|
|
fieldLabel: '', //'AGENT',
|
|
|
name: 'PLMBLNOS',
|
|
|
xtype: 'textareafield',
|
|
|
grow: true,
|
|
|
height: 180,
|
|
|
anchor: '100%'
|
|
|
|
|
|
}
|
|
|
]
|
|
|
}
|
|
|
|
|
|
]//end items(fieldset 1)
|
|
|
}//end fieldset 1
|
|
|
]//end root items
|
|
|
|
|
|
});
|
|
|
me = this;
|
|
|
|
|
|
|
|
|
|
|
|
this.winMBLPLQueryShow = Ext.create('Ext.window.Window', {
|
|
|
title: "主提单号批量查询",
|
|
|
width: 320,
|
|
|
//height : 120,
|
|
|
//plain : true,
|
|
|
iconCls: "addicon",
|
|
|
resizable: false,
|
|
|
// 是否可以拖动
|
|
|
// draggable:false,
|
|
|
collapsible: true, // 允许缩放条
|
|
|
closeAction: 'close',
|
|
|
closable: true,
|
|
|
modal: 'true',
|
|
|
buttonAlign: "center",
|
|
|
bodyStyle: "padding:0 0 0 0",
|
|
|
items: [this.formMBLPLQueryShow],
|
|
|
buttons: [{
|
|
|
text: "查询",
|
|
|
minWidth: 70,
|
|
|
handler: function () {
|
|
|
var form = me.formMBLPLQueryShow.getForm();
|
|
|
var mblnosql = "";
|
|
|
var PLMBLNOS = form.findField('PLMBLNOS').getValue();
|
|
|
if (PLMBLNOS == '') {
|
|
|
Ext.Msg.show({ title: Zi.LAN.TiShi, msg:'提单号不能为空!', icon: Ext.Msg.INFO, buttons: Ext.Msg.OK }); //请先选择要生成的业务!
|
|
|
return;
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
var i = PLMBLNOS.indexOf("\n");
|
|
|
if (i > 0) {
|
|
|
var mbllist = PLMBLNOS.split("\n");
|
|
|
for (var i = 0; i < mbllist.length; i += 1) {
|
|
|
var member = mbllist[i];
|
|
|
if (member != '') {
|
|
|
if (mblnosql == '')
|
|
|
mblnosql = "'" + member+"'";
|
|
|
else {
|
|
|
mblnosql = mblnosql + ",'" + member+"'";
|
|
|
}
|
|
|
}
|
|
|
}
|
|
|
} else {
|
|
|
if (PLMBLNOS != '') {
|
|
|
if (mblnosql == '')
|
|
|
mblnosql = "'" + PLMBLNOS + "'";
|
|
|
else {
|
|
|
mblnosql = mblnosql + ",'" + PLMBLNOS + "'";
|
|
|
}
|
|
|
}
|
|
|
|
|
|
}
|
|
|
|
|
|
mblnosql = " MBLNO IN (" + mblnosql + ")";
|
|
|
_this.onMblRefreshClick(mblnosql);
|
|
|
me.winMBLPLQueryShow.close();
|
|
|
|
|
|
}
|
|
|
}, {
|
|
|
text: "关闭",
|
|
|
minWidth: 70,
|
|
|
handler: function () {
|
|
|
me.winMBLPLQueryShow.close();
|
|
|
}
|
|
|
}]
|
|
|
});
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
this.relayEvents(this.PluginCover, ['opentab']);
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
//this.callParent(arguments);
|
|
|
}, //end initUIComponents
|
|
|
|
|
|
//#region 基本调用函数
|
|
|
InitGrid: function (grid) {
|
|
|
//var agirdcolums = Ext.clone(this.gridList.columns);
|
|
|
var agirdcolums = grid;
|
|
|
// var agirdcolumsSum = this.girdcolumsSum;
|
|
|
this.storectndisp.load({ params: { condition: "" },
|
|
|
callback: function (r, options, success) {
|
|
|
if (success) {
|
|
|
if (r.length != 0) {
|
|
|
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].header = 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].header = 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].header = 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].header = 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].header = 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].header = 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].header = 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].header = 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].header = memberyf.data.CNT10;
|
|
|
agirdcolums[j].hidden = false;
|
|
|
} else {
|
|
|
agirdcolums[j].hidden = true;
|
|
|
}
|
|
|
}
|
|
|
}
|
|
|
|
|
|
|
|
|
};
|
|
|
}
|
|
|
|
|
|
this.storecodeservice.load({ params: { condition: "OPTYPE='2'" },
|
|
|
callback: function (r, options, success) {
|
|
|
if (success) {
|
|
|
if (r.length != 0) {
|
|
|
for (i = 0; i < this.storecodeservice.getCount(); i += 1) {
|
|
|
var itemindex = i + 1;
|
|
|
var memberyf = this.storecodeservice.getAt(i);
|
|
|
for (var j = 0; j < agirdcolums.length; j++) {
|
|
|
if (agirdcolums[j].dataIndex == memberyf.data.OPField) {
|
|
|
agirdcolums[j].header = memberyf.data.SERVICENAME;
|
|
|
agirdcolums[j].hidden = false;
|
|
|
|
|
|
}
|
|
|
}
|
|
|
|
|
|
};
|
|
|
|
|
|
|
|
|
}
|
|
|
this.gridList.reconfigure(this.storeList, agirdcolums);
|
|
|
}
|
|
|
},
|
|
|
scope: this
|
|
|
});
|
|
|
|
|
|
// this.gridList.reconfigure(this.storeList, agirdcolums);
|
|
|
// this.gridListSum.reconfigure(this.storeSumList, agirdcolumsSum);
|
|
|
}
|
|
|
},
|
|
|
scope: this
|
|
|
});
|
|
|
},
|
|
|
onRefreshClick: function (button, event) {
|
|
|
//var girdcolums = this.gridList.getColumnMode();
|
|
|
var sql = this.getCondition();
|
|
|
this.sqlcontext = sql;
|
|
|
this.PageSize = this.Pagenum.getValue();
|
|
|
this.storeList.pageSize = this.PageSize;
|
|
|
this.storeList.load({
|
|
|
params: { start: 0, limit: this.PageSize, sort: '', condition: sql },
|
|
|
waitMsg: Zi.LAN.ZhengZaiChaXunShuJu, //"正在查询数据...",
|
|
|
scope: this
|
|
|
});
|
|
|
this.onRefreshSumClick(sql);
|
|
|
},
|
|
|
onDsQuery: function () {
|
|
|
//var girdcolums = this.gridList.getColumnMode();
|
|
|
var sql = this.sqlcontext;
|
|
|
this.PageSize = this.Pagenum.getValue();
|
|
|
this.storeList.pageSize = this.PageSize;
|
|
|
this.storeList.load({
|
|
|
params: { start: 0, limit: this.PageSize, sort: '', condition: sql },
|
|
|
waitMsg: Zi.LAN.ZhengZaiChaXunShuJu, //"正在查询数据...",
|
|
|
scope: this
|
|
|
});
|
|
|
this.onRefreshSumClick(sql);
|
|
|
},
|
|
|
onMblRefreshClick: function (mblnostr) {
|
|
|
//var girdcolums = this.gridList.getColumnMode();
|
|
|
var sql = this.getCondition();
|
|
|
sql = sql + getAndConSql(sql, mblnostr, mblnostr);
|
|
|
this.sqlcontext = sql;
|
|
|
this.PageSize = this.Pagenum.getValue();
|
|
|
this.storeList.pageSize = this.PageSize;
|
|
|
this.storeList.load({
|
|
|
params: { start: 0, limit: this.PageSize, sort: '', condition: sql },
|
|
|
waitMsg: Zi.LAN.ZhengZaiChaXunShuJu, //"正在查询数据...",
|
|
|
scope: this
|
|
|
});
|
|
|
this.onRefreshSumClick(sql);
|
|
|
},
|
|
|
|
|
|
onRefreshSumClick: function (sql) {
|
|
|
|
|
|
|
|
|
this.SumField = [
|
|
|
{ name: 'NOBILL', type: 'number' },
|
|
|
{ name: 'TEU', type: 'number' },
|
|
|
{ name: 'KGS', type: 'number' },
|
|
|
{ name: 'NETKGS', type: 'number' },
|
|
|
{ name: 'PKGS', type: 'number' },
|
|
|
{ name: 'CBM', type: 'number' },
|
|
|
{ name: 'WMSCTNNUM', type: 'number' }
|
|
|
];
|
|
|
|
|
|
|
|
|
this.girdcolumsSum = [{
|
|
|
sortable: true,
|
|
|
dataIndex: 'NOBILL',
|
|
|
header: Zi.LAN.NOBILL2, //'票数',
|
|
|
align: 'right',
|
|
|
width: 80
|
|
|
}, {
|
|
|
sortable: true,
|
|
|
dataIndex: 'TEU',
|
|
|
header: Zi.LAN.TEU, //'TEU',
|
|
|
align: 'right',
|
|
|
width: 80
|
|
|
}, {
|
|
|
sortable: true,
|
|
|
dataIndex: 'PKGS',
|
|
|
header: Zi.LAN.PKGS, //'件数',
|
|
|
renderer: function (value, cellmeta, record, rowIndex, columnIndex, store) { try { var lsValue = usMoney(value, 2, '', false); if (lsValue != "NaN") { value = lsValue; if (parseFloat(lsValue) < 0) { return '<SPAN style="COLOR: red">' + lsValue + '</SPAN>'; } } else { return value; } } catch (e) { return value; } return value; },
|
|
|
align: 'right',
|
|
|
width: 80
|
|
|
}, {
|
|
|
sortable: true,
|
|
|
dataIndex: 'KGS',
|
|
|
header: Zi.LAN.KGS2, //'毛重',
|
|
|
renderer: function (value, cellmeta, record, rowIndex, columnIndex, store) { try { var lsValue = usMoney(value, 2, '', false); if (lsValue != "NaN") { value = lsValue; if (parseFloat(lsValue) < 0) { return '<SPAN style="COLOR: red">' + lsValue + '</SPAN>'; } } else { return value; } } catch (e) { return value; } return value; },
|
|
|
align: 'right',
|
|
|
width: 80
|
|
|
}, {
|
|
|
sortable: true,
|
|
|
dataIndex: 'NETKGS',
|
|
|
header: Zi.LAN.NETWEIGHT, //'毛重',
|
|
|
renderer: function (value, cellmeta, record, rowIndex, columnIndex, store) { try { var lsValue = usMoney(value, 2, '', false); if (lsValue != "NaN") { value = lsValue; if (parseFloat(lsValue) < 0) { return '<SPAN style="COLOR: red">' + lsValue + '</SPAN>'; } } else { return value; } } catch (e) { return value; } return value; },
|
|
|
align: 'right',
|
|
|
width: 80
|
|
|
}, {
|
|
|
sortable: true,
|
|
|
dataIndex: 'CBM',
|
|
|
header: Zi.LAN.CBM, //'尺码',
|
|
|
renderer: function (value, cellmeta, record, rowIndex, columnIndex, store) { try { var lsValue = usMoney(value, 2, '', false); if (lsValue != "NaN") { value = lsValue; if (parseFloat(lsValue) < 0) { return '<SPAN style="COLOR: red">' + lsValue + '</SPAN>'; } } else { return value; } } catch (e) { return value; } return value; },
|
|
|
align: 'right',
|
|
|
width: 80
|
|
|
}, {
|
|
|
sortable: true,
|
|
|
dataIndex: 'WMSCTNNUM',
|
|
|
header: Zi.LAN.WMSCTNNUM, //'TEU',
|
|
|
align: 'right',
|
|
|
width: 80
|
|
|
}
|
|
|
|
|
|
];
|
|
|
|
|
|
|
|
|
|
|
|
_this = this;
|
|
|
this.storeCtnList.load({ params: { condition: sql },
|
|
|
callback: function (r, options, success) {
|
|
|
if (success) {
|
|
|
if (r.length != 0) {
|
|
|
for (i = 0; i < _this.storeCtnList.getCount(); i += 1) {
|
|
|
var itemindex = i + 1;
|
|
|
var memberyf = _this.storeCtnList.getAt(i);
|
|
|
_this.SumField.push({ name: 'C' + memberyf.data.CTNALL, type: 'number' });
|
|
|
_this.girdcolumsSum.push({
|
|
|
sortable: true,
|
|
|
dataIndex: 'C' + memberyf.data.CTNALL,
|
|
|
header: memberyf.data.CTNALL,
|
|
|
width: 80
|
|
|
});
|
|
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
_this.storeSumList = Ext.create('Ext.data.Store', {
|
|
|
pageSize: this.PageSize,
|
|
|
fields: _this.SumField,
|
|
|
remoteSort: true,
|
|
|
proxy: {
|
|
|
type: 'ajax',
|
|
|
url: '/MvcShipping/MsOpSeai/GetCtnSum',
|
|
|
reader: {
|
|
|
id: '',
|
|
|
root: 'data',
|
|
|
totalProperty: 'totalCount'
|
|
|
}
|
|
|
}
|
|
|
});
|
|
|
|
|
|
|
|
|
_this.gridListSum.reconfigure(_this.storeSumList, _this.girdcolumsSum);
|
|
|
_this.storeSumList.load({
|
|
|
params: { condition: sql },
|
|
|
waitMsg: Zi.LAN.ZhengZaiChaXunShuJu, //"正在查询数据...",
|
|
|
scope: this
|
|
|
});
|
|
|
|
|
|
}
|
|
|
}
|
|
|
});
|
|
|
|
|
|
},
|
|
|
|
|
|
onDeleteClick: function (button, event) {
|
|
|
var selections = this.gridList.getSelectionModel().getSelection();
|
|
|
if (selections.length == 0) {
|
|
|
Ext.Msg.show({ title: Zi.LAN.TiShi, msg: Zi.LAN.QingXianXuanZeYeWu, icon: Ext.Msg.INFO, buttons: Ext.Msg.OK }); //'提示', '请先选择业务!'
|
|
|
return;
|
|
|
}
|
|
|
|
|
|
var record = selections[0];
|
|
|
if (record.data.BSSTATUS == 'true') {
|
|
|
Ext.Msg.show({ title: Zi.LAN.JingGao, msg: Zi.LAN.YeWuYiSuoDingBuYunXuShanChu, icon: Ext.Msg.WARNING, buttons: Ext.Msg.OK }); //'警告', '业务已锁定,不允许删除!'
|
|
|
return;
|
|
|
}
|
|
|
|
|
|
if (record.data.FEESTATUS == 'true') {
|
|
|
Ext.Msg.show({ title: Zi.LAN.JingGao, msg: Zi.LAN.FeiYongYiSuoDingBuYunXuShanChu, icon: Ext.Msg.WARNING, buttons: Ext.Msg.OK }); //'警告', 费用已锁定,不允许删除!'
|
|
|
return;
|
|
|
}
|
|
|
|
|
|
if (this.StoreOpRange.getCount() == 0) {
|
|
|
Ext.Msg.show({ title: Zi.LAN.JingGao, msg: Zi.LAN.QuanXianBuZuBuYunXuShanChu, icon: Ext.Msg.WARNING, buttons: Ext.Msg.OK }); //'警告', 权限不足,不允许删除!'
|
|
|
return;
|
|
|
} else {
|
|
|
var op = record.data.OP;
|
|
|
var inputby = record.data.INPUTBY;
|
|
|
var records = DsStoreQueryBy(this.StoreOpRange, 'OPID', op);
|
|
|
if (records.getCount() > 0) {
|
|
|
} else {
|
|
|
var recordins = DsStoreQueryBy(this.StoreOpRange, 'OPID', inputby);
|
|
|
if (recordins.getCount() > 0) {
|
|
|
} else {
|
|
|
canedit = false;
|
|
|
Ext.Msg.show({ title: Zi.LAN.JingGao, msg: Zi.LAN.QuanXianBuZuBuYunXuShanChu, icon: Ext.Msg.WARNING, buttons: Ext.Msg.OK }); //'警告', 权限不足,不允许删除!'
|
|
|
return;
|
|
|
}
|
|
|
}
|
|
|
}
|
|
|
|
|
|
Ext.MessageBox.confirm('提示', '确定删除该记录吗?', function (btn) {
|
|
|
if (btn == 'yes') {
|
|
|
Ext.Msg.wait(Zi.LAN.ZhengZaiCaoZuoShuJu); //'正在删除数据...'
|
|
|
Ext.Ajax.request({
|
|
|
waitMsg: Zi.LAN.ZhengZaiCaoZuoShuJu, //'正在删除数据...',
|
|
|
url: '/MvcShipping/MsOpSeai/Delete',
|
|
|
params: {
|
|
|
data: Ext.JSON.encode(record.data)
|
|
|
},
|
|
|
callback: function (options, success, response) {
|
|
|
if (success) {
|
|
|
var jsonresult = Ext.JSON.decode(response.responseText);
|
|
|
if (jsonresult.Success) {
|
|
|
this.storeList.remove(record);
|
|
|
Ext.Msg.show({ title: Zi.LAN.TiShi, msg: jsonresult.Message, icon: Ext.Msg.INFO, buttons: Ext.Msg.OK });
|
|
|
}
|
|
|
else {
|
|
|
Ext.Msg.show({ title: Zi.LAN.ChuoWu, msg: jsonresult.Message, icon: Ext.Msg.ERROR, buttons: Ext.Msg.OK });
|
|
|
}
|
|
|
}
|
|
|
},
|
|
|
failure: function (response, options) {
|
|
|
Ext.Msg.show({ title: Zi.LAN.JingGao, msg: Zi.LAN.FuWuQiXiangYingChuCuo, icon: Ext.Msg.INFO, buttons: Ext.Msg.OK }); //'警告', msg: Zi.LAN.FuWuQiXiangYingChuCuo
|
|
|
},
|
|
|
success: function (response, options) { },
|
|
|
scope: this
|
|
|
}); //end Ext.Ajax.request
|
|
|
}
|
|
|
}, this);
|
|
|
},
|
|
|
//#endregion
|
|
|
|
|
|
//#region 拼箱分票Grid
|
|
|
|
|
|
displayInnerGrid: function (renderId, fenpiao) {
|
|
|
if (fenpiao == '0')
|
|
|
return;
|
|
|
var storeBodyList = Ext.create('Ext.data.Store', {
|
|
|
model: 'MsOpSeaiModel',
|
|
|
remoteSort: true,
|
|
|
proxy: {
|
|
|
type: 'ajax',
|
|
|
url: '/MvcShipping/MsOpSeai/GetFenList',
|
|
|
reader: {
|
|
|
id: 'BSNO',
|
|
|
root: 'data',
|
|
|
totalProperty: 'totalCount'
|
|
|
}
|
|
|
}
|
|
|
});
|
|
|
|
|
|
innerGrid = Ext.create('Ext.grid.Panel', {
|
|
|
store: storeBodyList,
|
|
|
viewConfig: {
|
|
|
enableTextSelection: true, //允许复制数据
|
|
|
autoFill: true
|
|
|
},
|
|
|
columns: this.girdcolums,
|
|
|
// columnLines: true,
|
|
|
// autoWidth: true,
|
|
|
// autoHeight: true,
|
|
|
frame: false,
|
|
|
renderTo: renderId
|
|
|
});
|
|
|
|
|
|
innerGrid.columns[0] = new Ext.grid.RowNumberer();
|
|
|
innerGrid.addListener('itemdblclick', function (dataview, record, item, index, e, b) {
|
|
|
this.SelectedRecord = record;
|
|
|
this.OprationStatus = 'edit';
|
|
|
DsOpenEditWin('/MvcShipping/MsOpSeai/Edit');
|
|
|
}, this);
|
|
|
storeBodyList.on('beforeload', function (store) {
|
|
|
var sql = " MASTERNO='" + renderId + "' AND BSNO<>'" + renderId + "'"
|
|
|
Ext.apply(store.proxy.extraParams, { condition: sql });
|
|
|
}, this);
|
|
|
|
|
|
storeBodyList.load({ params: { start: 0, limit: this.PageSize, sort: '', condition: " MASTERNO='" + renderId + "' AND BSNO<>'" + renderId + "'"} });
|
|
|
|
|
|
// innerGrid.getEl().swallowEvent([
|
|
|
// 'mousedown', 'mouseup', 'click',
|
|
|
// 'contextmenu', 'mouseover', 'mouseout',
|
|
|
// 'dblclick', 'mousemove'
|
|
|
// ]);
|
|
|
|
|
|
},
|
|
|
|
|
|
destroyInnerGrid: function (record) {
|
|
|
|
|
|
var parent = document.getElementById(record.get('BSNO'));
|
|
|
var child = parent.firstChild;
|
|
|
|
|
|
while (child) {
|
|
|
child.parentNode.removeChild(child);
|
|
|
child = child.nextSibling;
|
|
|
}
|
|
|
|
|
|
},
|
|
|
|
|
|
|
|
|
|
|
|
//#endregion
|
|
|
|
|
|
//#region 其他调用函数
|
|
|
onImportEdiClick: function (button, event) {
|
|
|
|
|
|
var winAccess = new Shipping.EDIImport({
|
|
|
|
|
|
});
|
|
|
winAccess.StoreList = this.storeList;
|
|
|
winAccess.show();
|
|
|
return;
|
|
|
},
|
|
|
|
|
|
onClearSql: function () {
|
|
|
var form = this.formSearch.getForm();
|
|
|
form.reset();
|
|
|
}, //onDeleteClick
|
|
|
|
|
|
getCondition: function () {
|
|
|
var form = this.formSearch.getForm();
|
|
|
// var form2 = this.formSearch2.getForm();
|
|
|
if (!form.isValid()) {
|
|
|
Ext.Msg.alert('提示', '查询条件赋值错误,请检查。');
|
|
|
return '';
|
|
|
}
|
|
|
//隐藏查询面板
|
|
|
// this.panelSearch.hide();
|
|
|
this.isShowAdvancedQuery = 0;
|
|
|
//
|
|
|
var sql = '';
|
|
|
|
|
|
//#region formSearch 查询面板
|
|
|
//编号包括(主提单号)
|
|
|
var MblNo = form.findField('MblNo').getValue();
|
|
|
sql = sql + getAndConSql(sql, MblNo, "(MblNo like '%" + MblNo + "%' or CONTRACTNO like '%" + MblNo + "%' or CUSTNO like '%" + MblNo + "%' or HBLNO like '%" + MblNo + "%' or CUSTOMNO like '%" + MblNo + "%' or INSPECTIONNO like '%" + MblNo + "%' or VOUNO like '%" + MblNo + "%' or APPROVENO like '%" + MblNo + "%' or ORDERNO like '%" + MblNo + "%' or APPLYNO like '%" + MblNo + "%')");
|
|
|
|
|
|
//客户名称
|
|
|
var CUSTOMERNAME = form.findField('CUSTOMERNAME').getValue();
|
|
|
sql = sql + getAndConSql(sql, CUSTOMERNAME, "CUSTOMERNAME='" + CUSTOMERNAME + "'");
|
|
|
|
|
|
// //会计期间
|
|
|
// var ACCDATE = form.findField('ACCDATE').getRawValue();
|
|
|
// sql = sql + getAndConSql(sql, ACCDATE, "ACCDATE='" + ACCDATE + "'");
|
|
|
|
|
|
//到港日期
|
|
|
var ETDbgn = form.findField('ETDbgn').getRawValue();
|
|
|
sql = sql + getAndConSql(sql, ETDbgn, "ETD >='" + ETDbgn + "'");
|
|
|
var ETDend = form.findField('ETDend').getRawValue();
|
|
|
sql = sql + getAndConSql(sql, ETDend, "ETD <='" + ETDend + "'");
|
|
|
|
|
|
//操作人
|
|
|
var OP = form.findField('OP').getValue();
|
|
|
sql = sql + getAndConSql(sql, OP, "OP='" + OP + "'");
|
|
|
|
|
|
//揽货人
|
|
|
var SALE = form.findField('SALE').getValue();
|
|
|
sql = sql + getAndConSql(sql, SALE, "SALE='" + SALE + "'");
|
|
|
|
|
|
// //贸易方式
|
|
|
// var TRADETYPE = form.findField('TRADETYPE').getValue();
|
|
|
// sql = sql + getAndConSql(sql, TRADETYPE, "TRADETYPE='" + TRADETYPE + "'");
|
|
|
|
|
|
// //品名
|
|
|
// var GOODSNAME = form.findField('GOODSNAME').getValue();
|
|
|
// sql = sql + getAndConSql(sql, GOODSNAME, "GOODSNAME='" + GOODSNAME + "'");
|
|
|
|
|
|
// //牌号
|
|
|
// var NUMBERPLATE = form.findField('NUMBERPLATE').getValue();
|
|
|
// sql = sql + getAndConSql(sql, NUMBERPLATE, "NUMBERPLATE like '%" + NUMBERPLATE + "%'");
|
|
|
|
|
|
// //接单日期
|
|
|
// var BSDATEbgn = form.findField('BSDATEbgn').getRawValue();
|
|
|
// sql = sql + getAndConSql(sql, BSDATEbgn, "BSDATE >='" + BSDATEbgn + "'");
|
|
|
// var BSDATEend = form.findField('BSDATEend').getRawValue();
|
|
|
// sql = sql + getAndConSql(sql, BSDATEend, "BSDATE <='" + BSDATEend + "'");
|
|
|
|
|
|
// //业务状态
|
|
|
// var BSSTATUS = form.findField('BSSTATUS').getValue();
|
|
|
// if (BSSTATUS != null) {
|
|
|
// if (BSSTATUS.toString().trim() == "锁定") {
|
|
|
// sql = sql + getAndConSql(sql, BSSTATUS, "BSSTATUS=1");
|
|
|
// }
|
|
|
// else if (BSSTATUS.toString().trim() == "未锁定") {
|
|
|
// sql = sql + getAndConSql(sql, BSSTATUS, "BSSTATUS=0");
|
|
|
// }
|
|
|
// }
|
|
|
|
|
|
// //费用状态
|
|
|
// var FEESTATUS = form.findField('FEESTATUS').getValue();
|
|
|
// if (FEESTATUS != null) {
|
|
|
// if (FEESTATUS.toString().trim() == "锁定") {
|
|
|
// sql = sql + getAndConSql(sql, FEESTATUS, "FEESTATUS=1");
|
|
|
// }
|
|
|
// else if (FEESTATUS.toString().trim() == "未锁定") {
|
|
|
// sql = sql + getAndConSql(sql, FEESTATUS, "FEESTATUS=0");
|
|
|
// }
|
|
|
// }
|
|
|
|
|
|
// //仓储状态
|
|
|
// var WMSTYPE = form.findField('WMSTYPE').getValue();
|
|
|
// sql = sql + getAndConSql(sql, WMSTYPE, "WMSTYPE='" + WMSTYPE + "'");
|
|
|
//#endregion formSearch
|
|
|
|
|
|
//#region formSearch2 隐藏查询面板
|
|
|
|
|
|
// //建单日期
|
|
|
// var CREATETIMEbgn = form2.findField('CREATETIMEbgn').getRawValue();
|
|
|
// sql = sql + getAndConSql(sql, CREATETIMEbgn, "CREATETIME >='" + CREATETIMEbgn + "'");
|
|
|
// var CREATETIMEend = form2.findField('CREATETIMEend').getRawValue();
|
|
|
// sql = sql + getAndConSql(sql, CREATETIMEend, "CREATETIME <='" + CREATETIMEend + "'");
|
|
|
|
|
|
// //录入人
|
|
|
// var INPUTBY = form2.findField('INPUTBY').getValue();
|
|
|
// sql = sql + getAndConSql(sql, INPUTBY, "INPUTBY='" + INPUTBY + "'");
|
|
|
|
|
|
// //
|
|
|
// var BSTYPE = form2.findField('BSTYPE').getValue();
|
|
|
// sql = sql + getAndConSql(sql, BSTYPE, "BSTYPE='" + BSTYPE + "'");
|
|
|
|
|
|
// //牌号
|
|
|
// var CNTRTOTAL = form2.findField('CNTRTOTAL').getValue();
|
|
|
// sql = sql + getAndConSql(sql, CNTRTOTAL, "CNTRTOTAL like '%" + CNTRTOTAL + "%'");
|
|
|
|
|
|
// //仓储入库货主
|
|
|
// var CUSTOMERNAME_WMS = form2.findField('CUSTOMERNAME_WMS').getValue();
|
|
|
// sql = sql + getAndConSql(sql, CUSTOMERNAME_WMS, "bsno in (select ASSOCIATEDNO from wms where CUSTOMERNAME='" + CUSTOMERNAME_WMS + "' and CORPID='" + COMPANYID + "')");
|
|
|
|
|
|
// //仓储出库货转对象
|
|
|
// var CUSTOMERNAME_WMS_OUT = form2.findField('CUSTOMERNAME_WMS_OUT').getValue();
|
|
|
// sql = sql + getAndConSql(sql, CUSTOMERNAME_WMS_OUT, "bsno in (select ASSOCIATEDNO from wms_out where CLIENTNAMEOLD='" + CUSTOMERNAME_WMS_OUT + "' and CORPID='" + COMPANYID + "')");
|
|
|
|
|
|
// //装货港
|
|
|
// var PORTLOAD = form2.findField('PORTLOAD').getValue();
|
|
|
// sql = sql + getAndConSql(sql, PORTLOAD, "PORTLOAD like '%" + PORTLOAD + "%'");
|
|
|
|
|
|
// //卸货港
|
|
|
// var PORTDISCHARGE = form2.findField('PORTDISCHARGE').getValue();
|
|
|
// sql = sql + getAndConSql(sql, PORTDISCHARGE, "PORTDISCHARGE like '%" + PORTDISCHARGE + "%'");
|
|
|
|
|
|
// //船名
|
|
|
// var VESSEL = form2.findField('VESSEL').getValue();
|
|
|
// sql = sql + getAndConSql(sql, VESSEL, "VESSEL like '%" + VESSEL + "%'");
|
|
|
|
|
|
// //航次
|
|
|
// var VOYNO = form2.findField('VOYNO').getValue();
|
|
|
// sql = sql + getAndConSql(sql, VOYNO, "VOYNO like '%" + VOYNO + "%'");
|
|
|
|
|
|
// //船公司
|
|
|
// var CARRIER = form2.findField('CARRIER').getValue();
|
|
|
// sql = sql + getAndConSql(sql, CARRIER, "CARRIER='" + CARRIER + "'");
|
|
|
|
|
|
// //箱使到期
|
|
|
// var BMDDATEbgn = form2.findField('BMDDATEbgn').getRawValue();
|
|
|
// sql = sql + getAndConSql(sql, BMDDATEbgn, "BMDDATE >='" + BMDDATEbgn + "'");
|
|
|
// var BMDDATEend = form2.findField('BMDDATEend').getRawValue();
|
|
|
// sql = sql + getAndConSql(sql, BMDDATEend, "BMDDATE <='" + BMDDATEend + "'");
|
|
|
|
|
|
// //搬倒日期
|
|
|
// var MDTDATEbgn = form2.findField('MDTDATEbgn').getRawValue();
|
|
|
// sql = sql + getAndConSql(sql, MDTDATEbgn, "MDTDATE >='" + MDTDATEbgn + "'");
|
|
|
// var MDTDATEend = form2.findField('MDTDATEend').getRawValue();
|
|
|
// sql = sql + getAndConSql(sql, MDTDATEend, "MDTDATE <='" + MDTDATEend + "'");
|
|
|
|
|
|
// //品名类型
|
|
|
// var GOODSTYPENAME = form2.findField('GOODSTYPENAME').getValue();
|
|
|
// sql = sql + getAndConSql(sql, GOODSTYPENAME, "GOODSTYPENAME like '%" + GOODSTYPENAME + "%'");
|
|
|
|
|
|
// //贸易代理
|
|
|
// var TRADINGAGENCY = form2.findField('TRADINGAGENCY').getValue();
|
|
|
// sql = sql + getAndConSql(sql, TRADINGAGENCY, "TRADINGAGENCY='" + TRADINGAGENCY + "'");
|
|
|
|
|
|
// //原产地
|
|
|
// var COUNTRYOFORIGIN = form2.findField('COUNTRYOFORIGIN').getValue();
|
|
|
// sql = sql + getAndConSql(sql, COUNTRYOFORIGIN, "COUNTRYOFORIGIN like '%" + COUNTRYOFORIGIN + "%'");
|
|
|
|
|
|
// //BALES
|
|
|
// var BALES = form2.findField('BALES').getValue();
|
|
|
// sql = sql + getAndConSql(sql, BALES, "BALES like '%" + BALES + "%'");
|
|
|
|
|
|
// //车队
|
|
|
// var TRUCKER = form2.findField('TRUCKER').getValue();
|
|
|
// sql = sql + getAndConSql(sql, TRUCKER, "TRUCKER='" + TRUCKER + "'");
|
|
|
|
|
|
// //报关行
|
|
|
// var CUSTOMSER = form2.findField('CUSTOMSER').getValue();
|
|
|
// sql = sql + getAndConSql(sql, CUSTOMSER, "CUSTOMSER='" + CUSTOMSER + "'");
|
|
|
|
|
|
// //发货人
|
|
|
// var SHIPPER = form2.findField('SHIPPER').getValue();
|
|
|
// sql = sql + getAndConSql(sql, SHIPPER, "SHIPPER like '%" + SHIPPER + "%'");
|
|
|
// //收货人
|
|
|
// var CONSIGNEE = form2.findField('CONSIGNEE').getValue();
|
|
|
// sql = sql + getAndConSql(sql, CONSIGNEE, "CONSIGNEE like '%" + CONSIGNEE + "%'");
|
|
|
// //通知人
|
|
|
// var NOTIFYPARTY = form2.findField('NOTIFYPARTY').getValue();
|
|
|
// sql = sql + getAndConSql(sql, NOTIFYPARTY, "NOTIFYPARTY like '%" + NOTIFYPARTY + "%'");
|
|
|
|
|
|
// var ENTERP = form2.findField('ENTERP').getValue();
|
|
|
// sql = sql + getAndConSql(sql, ENTERP, "ENTERP ='" + ENTERP + "'");
|
|
|
|
|
|
// //通关日期
|
|
|
// var CUSTOMDATEbgn = form2.findField('CUSTOMDATEbgn').getRawValue();
|
|
|
// sql = sql + getAndConSql(sql, CUSTOMDATEbgn, "CUSTOMDATE >='" + CUSTOMDATEbgn + "'");
|
|
|
// var CUSTOMDATEend = form2.findField('CUSTOMDATEend').getRawValue();
|
|
|
// sql = sql + getAndConSql(sql, CUSTOMDATEend, "CUSTOMDATE <='" + CUSTOMDATEend + "'");
|
|
|
|
|
|
// //申报日期
|
|
|
// var UPDATETIMEbgn = form2.findField('UPDATETIMEbgn').getRawValue();
|
|
|
// sql = sql + getAndConSql(sql, UPDATETIMEbgn, "UPDATETIME >='" + UPDATETIMEbgn + "'");
|
|
|
// var UPDATETIMEend = form2.findField('UPDATETIMEend').getRawValue();
|
|
|
// sql = sql + getAndConSql(sql, UPDATETIMEend, "UPDATETIME <='" + UPDATETIMEend + "'");
|
|
|
|
|
|
// //报检
|
|
|
// var INSPECTION = form2.findField('INSPECTION').getValue();
|
|
|
// sql = sql + getAndConSql(sql, INSPECTION, "INSPECTION='" + INSPECTION + "'");
|
|
|
|
|
|
// //报检日期
|
|
|
// var INSPECTIONDATEbgn = form2.findField('INSPECTIONDATEbgn').getRawValue();
|
|
|
// sql = sql + getAndConSql(sql, INSPECTIONDATEbgn, "INSPECTIONDATE >='" + INSPECTIONDATEbgn + "'");
|
|
|
// var INSPECTIONDATEend = form2.findField('INSPECTIONDATEend').getRawValue();
|
|
|
// sql = sql + getAndConSql(sql, INSPECTIONDATEend, "INSPECTIONDATE <='" + INSPECTIONDATEend + "'");
|
|
|
|
|
|
// //交关税时间
|
|
|
// var TARRIFSPAIEDTIEMbgn = form2.findField('TARRIFSPAIEDTIEMbgn').getRawValue();
|
|
|
// sql = sql + getAndConSql(sql, TARRIFSPAIEDTIEMbgn, "TARRIFSPAIEDTIEM >='" + TARRIFSPAIEDTIEMbgn + "'");
|
|
|
// var TARRIFSPAIEDTIEMend = form2.findField('TARRIFSPAIEDTIEMend').getRawValue();
|
|
|
// sql = sql + getAndConSql(sql, TARRIFSPAIEDTIEMend, "TARRIFSPAIEDTIEM <='" + TARRIFSPAIEDTIEMend + "'");
|
|
|
|
|
|
// //业务来源
|
|
|
// var BSSOURCE = form2.findField('BSSOURCE').getValue();
|
|
|
// sql = sql + getAndConSql(sql, BSSOURCE, "BSSOURCE='" + BSSOURCE + "'");
|
|
|
|
|
|
// //来源明细
|
|
|
// var BSSOURCEDETAIL = form2.findField('BSSOURCEDETAIL').getValue();
|
|
|
// sql = sql + getAndConSql(sql, BSSOURCEDETAIL, "BSSOURCEDETAIL='" + BSSOURCEDETAIL + "'");
|
|
|
|
|
|
// //装运方式
|
|
|
// var BLTYPE = form2.findField('BLTYPE').getValue();
|
|
|
// sql = sql + getAndConSql(sql, BLTYPE, "BLTYPE='" + BLTYPE + "'");
|
|
|
|
|
|
// //备注
|
|
|
// var REMARK = form2.findField('REMARK').getValue();
|
|
|
// sql = sql + getAndConSql(sql, REMARK, "REMARK like '%" + REMARK + "%'");
|
|
|
|
|
|
|
|
|
//#endregion formSearch2
|
|
|
|
|
|
return sql;
|
|
|
},
|
|
|
|
|
|
setIsShowAdvancedQuery: function () {
|
|
|
if (this.isShowAdvancedQuery == 0) {
|
|
|
this.panelSearch.show();
|
|
|
this.isShowAdvancedQuery = 1;
|
|
|
} else {
|
|
|
this.panelSearch.hide();
|
|
|
this.isShowAdvancedQuery = 0;
|
|
|
}
|
|
|
},
|
|
|
|
|
|
//
|
|
|
|
|
|
onCreateRunBill: function (button, event) {
|
|
|
var selections = this.gridList.getSelectionModel().getSelection();
|
|
|
if (selections.length == 0) {
|
|
|
Ext.Msg.show({ title: Zi.LAN.TiShi, msg: Zi.LAN.QingXianXuanZeYeWu, icon: Ext.Msg.INFO, buttons: Ext.Msg.OK });
|
|
|
return;
|
|
|
}
|
|
|
|
|
|
var strBSNO = '';
|
|
|
for (var c = 0; c < selections.length; c++) {
|
|
|
if (strBSNO.length > 0) {
|
|
|
strBSNO += ",";
|
|
|
}
|
|
|
strBSNO += selections[c].data.BSNO;
|
|
|
}
|
|
|
|
|
|
var left = (window.outerWidth - 600) / 2;
|
|
|
var top = (window.outerHeight - 600) / 2;
|
|
|
DsOpenEditWin('/MvcShipping/MsOpSeaeRunBill/Create?strBSNO=' + strBSNO, '新建跑单', 600, 600, top, left);
|
|
|
},
|
|
|
onUpOpStatusClick: function (menu, event, type) {
|
|
|
|
|
|
var selections = this.GridCheckBoxModel.selected.items;
|
|
|
if (selections.length == 0) {
|
|
|
Ext.Msg.show({ title: Zi.LAN.TiShi, msg: Zi.LAN.QingXianXuanZeYeWu, icon: Ext.Msg.INFO, buttons: Ext.Msg.OK }); //'提示', '请先选择要更新的业务!'
|
|
|
return;
|
|
|
}
|
|
|
var BSNOStr = '';
|
|
|
for (var i = 0; i < selections.length; i++) {
|
|
|
var rec = selections[i];
|
|
|
var BSNO = "'" + rec.data.BSNO + "'";
|
|
|
if (BSNOStr == '')
|
|
|
BSNOStr = BSNO;
|
|
|
else {
|
|
|
|
|
|
BSNOStr = BSNOStr + ',' + BSNO;
|
|
|
}
|
|
|
}
|
|
|
|
|
|
|
|
|
if (BSNOStr == '') {
|
|
|
Ext.Msg.show({ title: Zi.LAN.TiShi, msg: Zi.LAN.MeiYouYaoGengXinDeYeWu, icon: Ext.Msg.INFO, buttons: Ext.Msg.OK });
|
|
|
return;
|
|
|
|
|
|
} else {
|
|
|
|
|
|
this.selectbsno = " BSNO IN (" + BSNOStr + ")";
|
|
|
|
|
|
window.open('/MvcShipping/MsOpStatus/PiLiang', "PILIANGOPSTATUS", 'width=1200,height=600,top=0,left=0,resizable=yes,status=yes,menubar=no,scrollbars=yes');
|
|
|
}
|
|
|
|
|
|
|
|
|
},
|
|
|
onPiLiangSubmitClick: function (menu, event, type) {
|
|
|
|
|
|
var selections = this.GridCheckBoxModel.selected.items;
|
|
|
if (selections.length == 0) {
|
|
|
Ext.Msg.show({ title: Zi.LAN.TiShi, msg: Zi.LAN.QingXianXuanZeYeWu, icon: Ext.Msg.INFO, buttons: Ext.Msg.OK }); //'提示', '请先选择要更新的业务!'
|
|
|
return;
|
|
|
}
|
|
|
var BSNOStr = '';
|
|
|
for (var i = 0; i < selections.length; i++) {
|
|
|
var rec = selections[i];
|
|
|
var BSNO = "'" + rec.data.BSNO + "'";
|
|
|
if (BSNOStr == '')
|
|
|
BSNOStr = BSNO;
|
|
|
else {
|
|
|
|
|
|
BSNOStr = BSNOStr + ',' + BSNO;
|
|
|
}
|
|
|
}
|
|
|
this.storePLList.removeAll();
|
|
|
for (var i = 0; i < selections.length; i++) {
|
|
|
var rec = selections[i];
|
|
|
this.storePLList.add(rec.data);
|
|
|
}
|
|
|
|
|
|
if (BSNOStr == '') {
|
|
|
Ext.Msg.show({ title: Zi.LAN.TiShi, msg: Zi.LAN.MeiYouYaoGengXinDeYeWu, icon: Ext.Msg.INFO, buttons: Ext.Msg.OK });
|
|
|
return;
|
|
|
|
|
|
} else {
|
|
|
|
|
|
this.selectbsno = " MASTERNO IN (" + BSNOStr + ")";
|
|
|
|
|
|
window.open('/Account/Chfee_Audit/PiLiangSubmit', "PILIANGSUBMIT", 'width=1200,height=600,top=0,left=0,resizable=yes,status=yes,menubar=no,scrollbars=yes');
|
|
|
}
|
|
|
|
|
|
|
|
|
},
|
|
|
|
|
|
onImpSeaeClick: function (menu, event) {
|
|
|
DsOpenEditWin('/MvcShipping/MsOpSeai/Seae2SeaiIndex', "分公司委托引入", "600", "940", "10", "10");
|
|
|
},
|
|
|
|
|
|
onPiLiangAddFeeTemplate: function (menu, event, type) {
|
|
|
|
|
|
var selections = this.GridCheckBoxModel.selected.items;
|
|
|
if (selections.length == 0) {
|
|
|
Ext.Msg.show({ title: Zi.LAN.TiShi, msg: Zi.LAN.QingXianXuanZeYeWu, icon: Ext.Msg.INFO, buttons: Ext.Msg.OK }); //请先选择要更新的业务!
|
|
|
return;
|
|
|
}
|
|
|
var BSNOStr = '';
|
|
|
for (var i = 0; i < selections.length; i++) {
|
|
|
var rec = selections[i];
|
|
|
if (rec.data.FEESTATUSREF != '锁定') {
|
|
|
var BSNO = "'" + rec.data.BSNO + "'";
|
|
|
if (BSNOStr == '')
|
|
|
BSNOStr = BSNO;
|
|
|
else {
|
|
|
|
|
|
BSNOStr = BSNOStr + ',' + BSNO;
|
|
|
}
|
|
|
}
|
|
|
}
|
|
|
|
|
|
|
|
|
if (BSNOStr == '') {
|
|
|
Ext.Msg.show({ title: Zi.LAN.TiShi, msg: Zi.LAN.MeiYouYaoGengXinDeYeWu, icon: Ext.Msg.INFO, buttons: Ext.Msg.OK });
|
|
|
return;
|
|
|
|
|
|
} else {
|
|
|
|
|
|
this.selectbsno = " BSNO IN (" + BSNOStr + ")";
|
|
|
|
|
|
window.open('/MvcShipping/MsFeeTemplate/AddFeePLIndex', "PILIANGADDFEE", 'width=1200,height=600,top=0,left=0,resizable=yes,status=yes,menubar=no,scrollbars=yes');
|
|
|
}
|
|
|
|
|
|
|
|
|
},
|
|
|
|
|
|
onFeeEditClick: function (menu, event) {
|
|
|
|
|
|
var selections = this.gridList.getSelectionModel().getSelection();
|
|
|
if (selections.length == 0) {
|
|
|
Ext.Msg.show({ title: Zi.LAN.TiShi, msg: Zi.LAN.QingXianXuanZeYeWu, icon: Ext.Msg.INFO, buttons: Ext.Msg.OK }); //'提示', '请先选择业务!'
|
|
|
return;
|
|
|
}
|
|
|
|
|
|
var record = selections[0];
|
|
|
|
|
|
this.SelectedRecord = record;
|
|
|
this.OprationStatus = 'edit';
|
|
|
DsOpenEditWin('/MvcShipping/MsOpSeai/PiLiangFeeEdit');
|
|
|
|
|
|
|
|
|
},
|
|
|
//#endregion
|
|
|
|
|
|
//#region 导出EDI
|
|
|
onCreateEDIClick: function (menu, event, type) {
|
|
|
this.editype = type;
|
|
|
this.winEDIShow.show();
|
|
|
},
|
|
|
onSendEDI: function (type, filetype, filerole, isbill, isnoctn) {
|
|
|
var GidStr = '';
|
|
|
var selections = this.GridCheckBoxModel.selected.items;
|
|
|
if (selections.length == 0) {
|
|
|
Ext.Msg.show({ title: Zi.LAN.TiShi, msg: Zi.LAN.QingXianXuanZeYeWu, icon: Ext.Msg.INFO, buttons: Ext.Msg.OK }); //'提示', '请先选择要生成的业务!'
|
|
|
return;
|
|
|
}
|
|
|
var bodyAddDatas = [];
|
|
|
var j = 0;
|
|
|
var Mblno = '';
|
|
|
for (var i = 0; i < selections.length; i++) {
|
|
|
var rec = selections[i];
|
|
|
Mblno = rec.data.MBLNO;
|
|
|
bodyAddDatas.push(rec);
|
|
|
}
|
|
|
var jsonbodyAddDatas = ConvertRecordsToJsonAll(bodyAddDatas);
|
|
|
|
|
|
Ext.Ajax.request({
|
|
|
waitMsg: Zi.LAN.ZhengZaiCaoZuoShuJu, //'正在生成...',
|
|
|
url: '/MvcShipping/MsOpSeai/CreateEDIList',
|
|
|
params: {
|
|
|
headData: jsonbodyAddDatas,
|
|
|
mblno: Mblno,
|
|
|
type: type,
|
|
|
filetype: filetype,
|
|
|
filerole: filerole,
|
|
|
isbill: isbill,
|
|
|
isnoctn: isnoctn
|
|
|
},
|
|
|
callback: function (options, success, response) {
|
|
|
if (success) {
|
|
|
var result = Ext.JSON.decode(response.responseText);
|
|
|
if (!result.Success) {
|
|
|
Ext.Msg.show({
|
|
|
title: Zi.LAN.TiShi, msg: result.Message, icon: Ext.MessageBox.ERROR, buttons: Ext.Msg.OK
|
|
|
});
|
|
|
return;
|
|
|
} else {
|
|
|
Ext.Msg.show({ title: Zi.LAN.TiShi, msg: result.Message, icon: Ext.Msg.INFO, buttons: Ext.Msg.OK });
|
|
|
}
|
|
|
} else {
|
|
|
Ext.MessageBox.alert(Zi.LAN.FuWuQiXiangYingChuCuo, response.responseText);
|
|
|
}
|
|
|
},
|
|
|
scope: this
|
|
|
});
|
|
|
},
|
|
|
onSaveEDI: function (type, filetype, filerole, isbill, isnoctn) {
|
|
|
var GidStr = '';
|
|
|
var records = this.GridCheckBoxModel.selected.items;
|
|
|
if (records.length == 0) {
|
|
|
Ext.Msg.show({ title: Zi.LAN.TiShi, msg: Zi.LAN.QingXianXuanZeYeWu, icon: Ext.Msg.INFO, buttons: Ext.Msg.OK }); //'提示', '请先选择要存为文件的业务!'
|
|
|
return;
|
|
|
}
|
|
|
|
|
|
var insert;
|
|
|
var bodyAddDatas = [];
|
|
|
var j = 0;
|
|
|
var Mblno = '';
|
|
|
for (var i = 0; i < records.length; i++) {
|
|
|
var rec = records[i];
|
|
|
var EDISTATUS = rec.data.EDISTATUS;
|
|
|
if (EDISTATUS == "已发送") {
|
|
|
j = j + 1;
|
|
|
}
|
|
|
Mblno = rec.data.MBLNO;
|
|
|
bodyAddDatas.push(rec);
|
|
|
}
|
|
|
var jsonbodyAddDatas = ConvertRecordsToJsonAll(bodyAddDatas);
|
|
|
|
|
|
var msg = '';
|
|
|
msg = '确定要保存EDI文件吗?';
|
|
|
var strlo = window.location.host;
|
|
|
|
|
|
_this = this;
|
|
|
Ext.MessageBox.confirm('提示', msg, function (btn) {
|
|
|
if (btn == 'yes') {
|
|
|
Ext.Ajax.request({
|
|
|
waitMsg: Zi.LAN.Changing, //'Changing...',
|
|
|
url: '/MvcShipping/MsOpSeai/SaveEDIList',
|
|
|
params: {
|
|
|
headData: jsonbodyAddDatas,
|
|
|
mblno: Mblno,
|
|
|
type: type,
|
|
|
filetype: filetype,
|
|
|
filerole: filerole,
|
|
|
isbill: isbill,
|
|
|
isnoctn: isnoctn
|
|
|
},
|
|
|
callback: function (options, success, response) {
|
|
|
if (success) {
|
|
|
var result = Ext.JSON.decode(response.responseText);
|
|
|
if (!result.Success) {
|
|
|
Ext.Msg.show({ title: Zi.LAN.TiShi, msg: result.Message, icon: Ext.MessageBox.ERROR, buttons: Ext.Msg.OK });
|
|
|
return;
|
|
|
} else {
|
|
|
var downloadfile = Ext.getCmp('downloadfile');
|
|
|
var filehtml = '<a href="' + result.Data + '" style=' + '"text-decoration:none"' + '>' + result.Message + '</a>'
|
|
|
downloadfile.html = filehtml;
|
|
|
this.winDownloadShow.show();
|
|
|
}
|
|
|
} else {
|
|
|
Ext.MessageBox.alert('The Server Response Error, Please Try Again', response.responseText);
|
|
|
}
|
|
|
},
|
|
|
scope: this
|
|
|
});
|
|
|
}
|
|
|
}, this);
|
|
|
},
|
|
|
//#endregion
|
|
|
|
|
|
|
|
|
onCreateCustomClick: function (menu, event, type) {
|
|
|
|
|
|
|
|
|
var GidStr = '';
|
|
|
var selections = this.GridCheckBoxModel.selected.items;
|
|
|
if (selections.length == 0) {
|
|
|
Ext.Msg.show({ title: Zi.LAN.TiShi, msg: Zi.LAN.QingXianXuanZeYeWu, icon: Ext.Msg.INFO, buttons: Ext.Msg.OK }); //请先选择要生成的业务!
|
|
|
return;
|
|
|
}
|
|
|
var BSNOStr = '';
|
|
|
for (var i = 0; i < selections.length; i++) {
|
|
|
var rec = selections[i];
|
|
|
var BSNO = rec.data.BSNO;
|
|
|
if (BSNOStr == '')
|
|
|
BSNOStr = BSNO;
|
|
|
else {
|
|
|
|
|
|
BSNOStr = BSNOStr + ',' + BSNO;
|
|
|
}
|
|
|
}
|
|
|
|
|
|
|
|
|
if (BSNOStr == '') {
|
|
|
Ext.Msg.show({ title: Zi.LAN.TiShi, msg: Zi.LAN.MeiYouYaoCaoZuoDeYeWu, icon: Ext.Msg.INFO, buttons: Ext.Msg.OK });
|
|
|
return;
|
|
|
|
|
|
} else {
|
|
|
|
|
|
|
|
|
Ext.Ajax.request({
|
|
|
waitMsg: Zi.LAN.ZhengZaiCaoZuoShuJu,
|
|
|
url: '/MvcShipping/MsOpSeai/CreateCustomList',
|
|
|
params: {
|
|
|
BSNOS: BSNOStr,
|
|
|
type: type
|
|
|
},
|
|
|
callback: function (options, success, response) {
|
|
|
if (success) {
|
|
|
var result = Ext.JSON.decode(response.responseText);
|
|
|
if (!result.Success) {
|
|
|
Ext.Msg.show({
|
|
|
title: Zi.LAN.TiShi,
|
|
|
msg: result.Message,
|
|
|
icon: Ext.MessageBox.ERROR,
|
|
|
buttons: Ext.Msg.OK
|
|
|
});
|
|
|
return;
|
|
|
} else {
|
|
|
|
|
|
Ext.Msg.show({ title: Zi.LAN.TiShi, msg: result.Message, icon: Ext.Msg.INFO, buttons: Ext.Msg.OK });
|
|
|
|
|
|
}
|
|
|
|
|
|
} else {
|
|
|
Ext.MessageBox.alert('请求出现错误,请重试', response.responseText);
|
|
|
}
|
|
|
},
|
|
|
scope: this
|
|
|
});
|
|
|
}
|
|
|
|
|
|
},
|
|
|
|
|
|
|
|
|
//#region 交通部EDI
|
|
|
onCreateIFTMBFClick: function (menu, event) {
|
|
|
this.winIFTMBFShow.show();
|
|
|
},
|
|
|
onSendIFTMBF: function (filerole, carrier) {
|
|
|
var GidStr = '';
|
|
|
var selections = this.GridCheckBoxModel.selected.items;
|
|
|
if (selections.length == 0) {
|
|
|
Ext.Msg.show({ title: Zi.LAN.TiShi, msg: Zi.LAN.QingXianXuanZeYeWu, icon: Ext.Msg.INFO, buttons: Ext.Msg.OK }); //'提示', '请先选择要生成的业务!'
|
|
|
return;
|
|
|
}
|
|
|
var BSNOStr = '';
|
|
|
var j = 0;
|
|
|
var Mblno = '';
|
|
|
for (var i = 0; i < selections.length; i++) {
|
|
|
var rec = selections[i];
|
|
|
Mblno = rec.data.MBLNO;
|
|
|
var BSNO = rec.data.BSNO;
|
|
|
if (BSNOStr == '')
|
|
|
BSNOStr = BSNO;
|
|
|
else {
|
|
|
|
|
|
BSNOStr = BSNOStr + ',' + BSNO;
|
|
|
}
|
|
|
}
|
|
|
|
|
|
if (BSNOStr == '') {
|
|
|
Ext.Msg.show({ title: Zi.LAN.TiShi, msg: Zi.LAN.MeiYouYaoShengChengDeShuJu, icon: Ext.Msg.INFO, buttons: Ext.Msg.OK });
|
|
|
return;
|
|
|
} else {
|
|
|
Ext.Ajax.request({
|
|
|
waitMsg: Zi.LAN.ZhengZaiCaoZuoShuJu, //'正在生成...',
|
|
|
url: '/MvcShipping/MsOpSeai/CreateIFTMBFList',
|
|
|
params: {
|
|
|
bsnos: BSNOStr,
|
|
|
mblno: Mblno,
|
|
|
filerole: filerole,
|
|
|
carrier: carrier
|
|
|
},
|
|
|
callback: function (options, success, response) {
|
|
|
if (success) {
|
|
|
var result = Ext.JSON.decode(response.responseText);
|
|
|
if (!result.Success) {
|
|
|
Ext.Msg.show({
|
|
|
title: Zi.LAN.TiShi, msg: result.Message, icon: Ext.MessageBox.ERROR, buttons: Ext.Msg.OK
|
|
|
});
|
|
|
return;
|
|
|
} else {
|
|
|
|
|
|
Ext.Msg.show({ title: Zi.LAN.TiShi, msg: result.Message, icon: Ext.Msg.INFO, buttons: Ext.Msg.OK });
|
|
|
|
|
|
}
|
|
|
|
|
|
} else {
|
|
|
Ext.MessageBox.alert(Zi.LAN.FuWuQiXiangYingChuCuo, response.responseText);
|
|
|
}
|
|
|
},
|
|
|
scope: this
|
|
|
});
|
|
|
}
|
|
|
},
|
|
|
onSaveIFTMBF: function (filerole, carrier) {
|
|
|
var GidStr = '';
|
|
|
var selections = this.GridCheckBoxModel.selected.items;
|
|
|
if (selections.length == 0) {
|
|
|
Ext.Msg.show({ title: Zi.LAN.TiShi, msg: Zi.LAN.QingXianXuanZeYeWu, icon: Ext.Msg.INFO, buttons: Ext.Msg.OK }); //'提示', '请先选择要生成的业务!'
|
|
|
return;
|
|
|
}
|
|
|
|
|
|
var BSNOStr = '';
|
|
|
var j = 0;
|
|
|
var Mblno = '';
|
|
|
for (var i = 0; i < selections.length; i++) {
|
|
|
var rec = selections[i];
|
|
|
Mblno = rec.data.MBLNO;
|
|
|
var BSNO = rec.data.BSNO;
|
|
|
if (BSNOStr == '')
|
|
|
BSNOStr = BSNO;
|
|
|
else {
|
|
|
BSNOStr = BSNOStr + ',' + BSNO;
|
|
|
}
|
|
|
}
|
|
|
|
|
|
if (BSNOStr == '') {
|
|
|
Ext.Msg.show({ title: Zi.LAN.TiShi, msg: Zi.LAN.MeiYouYaoShengChengDeShuJu, icon: Ext.Msg.INFO, buttons: Ext.Msg.OK });
|
|
|
return;
|
|
|
} else {
|
|
|
|
|
|
Ext.Ajax.request({
|
|
|
waitMsg: Zi.LAN.Changing, //'Changing...',
|
|
|
url: '/MvcShipping/MsOpSeai/SaveIFTMBFList',
|
|
|
params: {
|
|
|
bsnos: BSNOStr,
|
|
|
mblno: Mblno,
|
|
|
filerole: filerole,
|
|
|
carrier: carrier
|
|
|
},
|
|
|
callback: function (options, success, response) {
|
|
|
if (success) {
|
|
|
var result = Ext.JSON.decode(response.responseText);
|
|
|
if (!result.Success) {
|
|
|
Ext.Msg.show({
|
|
|
title: Zi.LAN.TiShi, msg: result.Message, icon: Ext.MessageBox.ERROR, buttons: Ext.Msg.OK
|
|
|
});
|
|
|
return;
|
|
|
} else {
|
|
|
|
|
|
var downloadfile = Ext.getCmp('downloadfile');
|
|
|
var children = downloadfile.items;
|
|
|
if (children) {
|
|
|
for (var i = 0, len = children.length; i < len; i++) {
|
|
|
downloadfile.remove(children.items[i], true);
|
|
|
}
|
|
|
}
|
|
|
var downloadfiles = '<a href="' + result.Data + '" style=' + '"text-decoration:none"' + '>' + result.Message + '</a>';
|
|
|
var htmla = Ext.widget('label', {
|
|
|
html: downloadfiles,
|
|
|
width: 120,
|
|
|
text: ''
|
|
|
});
|
|
|
|
|
|
downloadfile.items.add(htmla);
|
|
|
this.winDownloadShow.show();
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
} else {
|
|
|
Ext.MessageBox.alert('The Server Response Error, Please Try Again', response.responseText);
|
|
|
}
|
|
|
},
|
|
|
scope: this
|
|
|
});
|
|
|
}
|
|
|
},
|
|
|
//#endregion
|
|
|
|
|
|
//#region DHL EDI
|
|
|
onCreateDHLClick: function (menu, event) {
|
|
|
this.winDHLShow.show();
|
|
|
},
|
|
|
onSendDHL: function (filerole, carrier) {
|
|
|
var GidStr = '';
|
|
|
var selections = this.GridCheckBoxModel.selected.items;
|
|
|
if (selections.length == 0) {
|
|
|
Ext.Msg.show({ title: Zi.LAN.TiShi, msg: Zi.LAN.QingXianXuanZeYeWu, icon: Ext.Msg.INFO, buttons: Ext.Msg.OK }); //'提示', '请先选择要生成的业务!'
|
|
|
return;
|
|
|
}
|
|
|
var BSNOStr = '';
|
|
|
var j = 0;
|
|
|
var Mblno = '';
|
|
|
for (var i = 0; i < selections.length; i++) {
|
|
|
var rec = selections[i];
|
|
|
Mblno = rec.data.MBLNO;
|
|
|
var BSNO = rec.data.BSNO;
|
|
|
if (BSNOStr == '')
|
|
|
BSNOStr = BSNO;
|
|
|
else {
|
|
|
|
|
|
BSNOStr = BSNOStr + ',' + BSNO;
|
|
|
}
|
|
|
}
|
|
|
|
|
|
if (BSNOStr == '') {
|
|
|
Ext.Msg.show({ title: Zi.LAN.TiShi, msg: Zi.LAN.MeiYouYaoShengChengDeShuJu, icon: Ext.Msg.INFO, buttons: Ext.Msg.OK });
|
|
|
return;
|
|
|
} else {
|
|
|
Ext.Ajax.request({
|
|
|
waitMsg: Zi.LAN.ZhengZaiCaoZuoShuJu, //'正在生成...',
|
|
|
url: '/MvcShipping/MsOpSeai/CreateDHLList',
|
|
|
params: {
|
|
|
bsnos: BSNOStr,
|
|
|
mblno: Mblno,
|
|
|
filerole: filerole
|
|
|
},
|
|
|
callback: function (options, success, response) {
|
|
|
if (success) {
|
|
|
var result = Ext.JSON.decode(response.responseText);
|
|
|
if (!result.Success) {
|
|
|
Ext.Msg.show({
|
|
|
title: Zi.LAN.TiShi, msg: result.Message, icon: Ext.MessageBox.ERROR, buttons: Ext.Msg.OK
|
|
|
});
|
|
|
return;
|
|
|
} else {
|
|
|
|
|
|
Ext.Msg.show({ title: Zi.LAN.TiShi, msg: result.Message, icon: Ext.Msg.INFO, buttons: Ext.Msg.OK });
|
|
|
|
|
|
}
|
|
|
|
|
|
} else {
|
|
|
Ext.MessageBox.alert(Zi.LAN.FuWuQiXiangYingChuCuo, response.responseText);
|
|
|
}
|
|
|
},
|
|
|
scope: this
|
|
|
});
|
|
|
}
|
|
|
},
|
|
|
onSaveDHL: function (filerole, carrier) {
|
|
|
var GidStr = '';
|
|
|
var selections = this.GridCheckBoxModel.selected.items;
|
|
|
if (selections.length == 0) {
|
|
|
Ext.Msg.show({ title: Zi.LAN.TiShi, msg: Zi.LAN.QingXianXuanZeYeWu, icon: Ext.Msg.INFO, buttons: Ext.Msg.OK }); //'提示', '请先选择要生成的业务!'
|
|
|
return;
|
|
|
}
|
|
|
|
|
|
var BSNOStr = '';
|
|
|
var j = 0;
|
|
|
var Mblno = '';
|
|
|
for (var i = 0; i < selections.length; i++) {
|
|
|
var rec = selections[i];
|
|
|
Mblno = rec.data.MBLNO;
|
|
|
var BSNO = rec.data.BSNO;
|
|
|
if (BSNOStr == '')
|
|
|
BSNOStr = BSNO;
|
|
|
else {
|
|
|
BSNOStr = BSNOStr + ',' + BSNO;
|
|
|
}
|
|
|
}
|
|
|
|
|
|
if (BSNOStr == '') {
|
|
|
Ext.Msg.show({ title: Zi.LAN.TiShi, msg: Zi.LAN.MeiYouYaoShengChengDeShuJu, icon: Ext.Msg.INFO, buttons: Ext.Msg.OK });
|
|
|
return;
|
|
|
} else {
|
|
|
|
|
|
Ext.Ajax.request({
|
|
|
waitMsg: Zi.LAN.Changing, //'Changing...',
|
|
|
url: '/MvcShipping/MsOpSeai/SaveDHLList',
|
|
|
params: {
|
|
|
bsnos: BSNOStr,
|
|
|
mblno: Mblno,
|
|
|
filerole: filerole
|
|
|
},
|
|
|
callback: function (options, success, response) {
|
|
|
if (success) {
|
|
|
var result = Ext.JSON.decode(response.responseText);
|
|
|
if (!result.Success) {
|
|
|
Ext.Msg.show({
|
|
|
title: Zi.LAN.TiShi, msg: result.Message, icon: Ext.MessageBox.ERROR, buttons: Ext.Msg.OK
|
|
|
});
|
|
|
return;
|
|
|
} else {
|
|
|
|
|
|
var downloadfile = Ext.getCmp('downloadfile');
|
|
|
var children = downloadfile.items;
|
|
|
if (children) {
|
|
|
for (var i = 0, len = children.length; i < len; i++) {
|
|
|
downloadfile.remove(children.items[i], true);
|
|
|
}
|
|
|
}
|
|
|
var downloadfiles = '<a href="' + result.Data + '" style=' + '"text-decoration:none"' + '>' + result.Message + '</a>';
|
|
|
var htmla = Ext.widget('label', {
|
|
|
html: downloadfiles,
|
|
|
width: 120,
|
|
|
text: ''
|
|
|
});
|
|
|
|
|
|
downloadfile.items.add(htmla);
|
|
|
this.winDownloadShow.show();
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
} else {
|
|
|
Ext.MessageBox.alert('The Server Response Error, Please Try Again', response.responseText);
|
|
|
}
|
|
|
},
|
|
|
scope: this
|
|
|
});
|
|
|
}
|
|
|
},
|
|
|
//#endregion
|
|
|
|
|
|
//#region 船公司运踪查询
|
|
|
|
|
|
onGETCARRIERClick: function (button, event) {
|
|
|
var selections = this.gridList.getSelectionModel().getSelection();
|
|
|
if (selections.length == 0) {
|
|
|
Ext.Msg.show({ title: Zi.LAN.TiShi, msg: Zi.LAN.QingXianXuanZeYeWu, icon: Ext.Msg.INFO, buttons: Ext.Msg.OK });
|
|
|
return;
|
|
|
}
|
|
|
|
|
|
var record = selections[0];
|
|
|
var BSNO = record.data.BSNO;
|
|
|
var MBLNO = record.data.MBLNO;
|
|
|
var CARRIER = record.data.CARRIER;
|
|
|
|
|
|
if (MBLNO == "" || CARRIER == "") {
|
|
|
Ext.Msg.show({ title: Zi.LAN.TiShi, msg: Zi.LAN.TiDanHaoHeChuanGongSiBuNengWeiKong, icon: Ext.Msg.INFO, buttons: Ext.Msg.OK }); //'提单号和场站不能为空!'
|
|
|
return;
|
|
|
|
|
|
} else {
|
|
|
Ext.Msg.wait(Zi.LAN.ZhengZaiCaoZuoShuJu);
|
|
|
Ext.Ajax.request({
|
|
|
waitMsg: Zi.LAN.ZhengZaiCaoZuoShuJu,
|
|
|
url: '/MvcShipping/MsOpSeae/GetYunDangUrl',
|
|
|
params: {
|
|
|
bs: BSNO,
|
|
|
mblno: MBLNO,
|
|
|
carrier: CARRIER
|
|
|
},
|
|
|
callback: function (options, success, response) {
|
|
|
if (success) {
|
|
|
var jsonresult = Ext.JSON.decode(response.responseText);
|
|
|
if (jsonresult.Success) {
|
|
|
|
|
|
var statusdata = jsonresult.Data;
|
|
|
var boxitems = "";
|
|
|
Ext.Msg.hide();
|
|
|
DsOpenEditWin(jsonresult.Data, '');
|
|
|
}
|
|
|
else {
|
|
|
Ext.Msg.show({ title: Zi.LAN.ChuoWu, msg: jsonresult.Message, icon: Ext.Msg.ERROR, buttons: Ext.Msg.OK });
|
|
|
}
|
|
|
}
|
|
|
},
|
|
|
failure: function (response, options) {
|
|
|
Ext.Msg.show({ title: Zi.LAN.JingGao, msg: Zi.LAN.FuWuQiXiangYingChuCuo, icon: Ext.Msg.INFO, buttons: Ext.Msg.OK });
|
|
|
},
|
|
|
success: function (response, options) { },
|
|
|
scope: this
|
|
|
}); //end Ext.Ajax.request
|
|
|
}
|
|
|
|
|
|
|
|
|
},
|
|
|
//#endregion
|
|
|
|
|
|
//#region 青岛港单票查询
|
|
|
onQQCTUBILLClick: function (button, event) {
|
|
|
var selections = this.gridList.getSelectionModel().getSelection();
|
|
|
if (selections.length === 0) {
|
|
|
Ext.Msg.show({ title: Zi.LAN.TiShi, msg: Zi.LAN.QingXianXuanZeYeWu, icon: Ext.Msg.INFO, buttons: Ext.Msg.OK });
|
|
|
return;
|
|
|
}
|
|
|
var record = selections[0];
|
|
|
var mblno = record.data.MBLNO;
|
|
|
var bsno = record.data.BSNO;
|
|
|
if (mblno === "") {
|
|
|
Ext.Msg.show({ title: Zi.LAN.TiShi, msg: Zi.LAN.TiDanHaoBuNengWeiKong, icon: Ext.Msg.INFO, buttons: Ext.Msg.OK });
|
|
|
return;
|
|
|
}
|
|
|
Ext.Msg.wait(Zi.LAN.ZhengZaiCaoZuoShuJu);
|
|
|
Ext.Ajax.request({
|
|
|
waitMsg: Zi.LAN.ZhengZaiCaoZuoShuJu,
|
|
|
url: '/MvcShipping/MsOpSeae/GetyardctnList',
|
|
|
params: {
|
|
|
bs: bsno,
|
|
|
mblno: mblno,
|
|
|
yard: 'YGT',
|
|
|
isweb: true,//值
|
|
|
jck: "jk"
|
|
|
},
|
|
|
callback: function (options, success, response) {
|
|
|
if (success) {
|
|
|
var jsonresult = Ext.JSON.decode(response.responseText);
|
|
|
if (jsonresult.Success) {
|
|
|
|
|
|
var statusdata = jsonresult.data;
|
|
|
var boxitems = "";
|
|
|
|
|
|
|
|
|
formCustomDataShow = Ext.widget('form', {
|
|
|
region: 'center',
|
|
|
autoScroll: true, height: 460,
|
|
|
// border: false,
|
|
|
bodyPadding: 0,
|
|
|
html: jsonresult.data
|
|
|
|
|
|
});
|
|
|
|
|
|
me = this;
|
|
|
winCustomDataShow = Ext.create('Ext.window.Window', {
|
|
|
title: "",
|
|
|
// closeAction: 'hide',
|
|
|
width: 1100,
|
|
|
height: 500,
|
|
|
layout: 'fit',
|
|
|
resizable: true,
|
|
|
modal: true,
|
|
|
closeAction: 'close',
|
|
|
closable: true,
|
|
|
items: [formCustomDataShow],
|
|
|
buttons: [{
|
|
|
text: Zi.LAN.GuanBi, //"关闭",
|
|
|
minWidth: 70,
|
|
|
handler: function () {
|
|
|
winCustomDataShow.close();
|
|
|
}
|
|
|
}]
|
|
|
});
|
|
|
|
|
|
winCustomDataShow.show();
|
|
|
|
|
|
Ext.Msg.hide();
|
|
|
|
|
|
}
|
|
|
else {
|
|
|
Ext.Msg.show({ title: Zi.LAN.ChuoWu, msg: jsonresult.Message, icon: Ext.Msg.ERROR, buttons: Ext.Msg.OK });
|
|
|
}
|
|
|
}
|
|
|
},
|
|
|
failure: function (response, options) {
|
|
|
Ext.Msg.show({ title: Zi.LAN.JingGao, msg: Zi.LAN.FuWuQiXiangYingChuCuo, icon: Ext.Msg.INFO, buttons: Ext.Msg.OK });
|
|
|
},
|
|
|
success: function (response, options) { },
|
|
|
scope: this
|
|
|
}); //end Ext.Ajax.request
|
|
|
|
|
|
},
|
|
|
//#endregion
|
|
|
|
|
|
|
|
|
//#region 导出Excel
|
|
|
onExportClick: function (button, event) {
|
|
|
//var strGIDs = "";
|
|
|
//var sql = escape(this.sqlcontext);
|
|
|
//var openSet = "height=1, width=400, toolbar=no, menubar=no,scrollbars=no, resizable=no,location=no, status=no,Top=" + (screen.height - 200) / 2 + ",Left=" + (screen.width - 400) / 2;
|
|
|
//var openType = "_blank";
|
|
|
//var openUrl = "../../Reports/RptExport.aspx?handle=MsOpSeaiIndex&formname=" + this.formname + "&condition1=" + sql + "&gids=" + strGIDs;
|
|
|
//window.open(openUrl, openType, openSet);
|
|
|
_this = this;
|
|
|
if (this.storeList.getCount() == 0) {
|
|
|
return;
|
|
|
}
|
|
|
|
|
|
Ext.Msg.wait(Zi.LAN.ZhengZaiCaoZuoShuJu); //'正在组织数据, 请稍侯..'
|
|
|
Ext.Ajax.request({
|
|
|
waitMsg: Zi.LAN.ZhengZaiCaoZuoShuJu, //'正在组织数据...',
|
|
|
url: '/MvcShipping/MsOpSeai/GetDataListStr',
|
|
|
scope: this,
|
|
|
params: {
|
|
|
condition: _this.sqlcontext,
|
|
|
printstr: 'true'
|
|
|
},
|
|
|
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 = 'MSOPSEAILIST';
|
|
|
var sql1 = returnstr;
|
|
|
sql1 = sql1.replace(/\+/g, "@@@")
|
|
|
if (sql1 != '') {
|
|
|
|
|
|
GridExportBySql(sql1, this.formname, '海运进口列表.xls');
|
|
|
|
|
|
//var openSet = "height=1, width=400, toolbar=no, menubar=no,scrollbars=no, resizable=no,location=no, status=no,Top=" + (screen.height - 200) / 2 + ",Left=" + (screen.width - 400) / 2;
|
|
|
//var openType = "_blank";
|
|
|
//var openUrl = "../../Reports/RptExport.aspx?handle=DsRptExcel&formname=" + this.formname + 'bs' + "&condition1=" + sql1;
|
|
|
//window.open(openUrl, openType, openSet);
|
|
|
|
|
|
}
|
|
|
|
|
|
} else {
|
|
|
Ext.Msg.show({ title: Zi.LAN.ChuoWu, msg: jsonresult.Message, icon: Ext.Msg.ERROR, buttons: Ext.Msg.OK });
|
|
|
}
|
|
|
} else {
|
|
|
Ext.Msg.show({ title: Zi.LAN.TiShi, msg: Zi.LAN.FuWuQiXiangYingChuCuo, icon: Ext.Msg.ERROR, buttons: Ext.Msg.OK }); //'请重试', msg: Zi.LAN.FuWuQiXiangYingChuCuo
|
|
|
}
|
|
|
}
|
|
|
});
|
|
|
},
|
|
|
//#endregion
|
|
|
|
|
|
OprationSwap: function () {
|
|
|
var ret = new Array();
|
|
|
ret[0] = this.OprationStatus;
|
|
|
ret[1] = this.storeList;
|
|
|
ret[2] = this.SelectedRecord;
|
|
|
ret[3] = this.selectbsno;
|
|
|
ret[4] = 'op_seai';
|
|
|
ret[5] = this.storePLList;
|
|
|
return ret;
|
|
|
},
|
|
|
//#region 放单通知 gridList_Edit的右键菜单
|
|
|
|
|
|
onFDTZClick: function (his, record, item, index, e) {
|
|
|
|
|
|
Ext.getCmp("FDINFO").update("");
|
|
|
|
|
|
var selections = this.gridList.getSelectionModel().getSelection();
|
|
|
if (selections.length == 0) {
|
|
|
Ext.Msg.show({ title: Zi.LAN.TiShi, msg: Zi.LAN.QingXianXuanZeYeWu, icon: Ext.Msg.INFO, buttons: Ext.Msg.OK });
|
|
|
return;
|
|
|
}
|
|
|
|
|
|
var rec = selections[0];
|
|
|
var BSNO = rec.data.BSNO;
|
|
|
|
|
|
if (rec.data.ISSUETYPE == '') {
|
|
|
Ext.Msg.show({ title: Zi.LAN.TiShi, msg: '签单方式不能为空!', icon: Ext.Msg.INFO, buttons: Ext.Msg.OK });
|
|
|
return;
|
|
|
}
|
|
|
|
|
|
|
|
|
_this = this;
|
|
|
Ext.Ajax.request({
|
|
|
waitMsg: Zi.LAN.ZhengZaiCaoZuoShuJu,
|
|
|
url: '/MvcShipping/MsOp_BLISSUE/GetBLINFO',
|
|
|
async: false,
|
|
|
params: {
|
|
|
BSNO: "'" + BSNO + "'"
|
|
|
},
|
|
|
callback: function (options, success, response) {
|
|
|
if (success) {
|
|
|
|
|
|
var result = Ext.JSON.decode(response.responseText);
|
|
|
if (result.Success) {
|
|
|
var _html = "<span style=\"clear:both;\">";
|
|
|
|
|
|
_this.结费类型 = result.data[0].结费类型.replace("<span style=\"colorred\">", " ").replace("</span>", " ");
|
|
|
_this.欠费超期 = result.data[0].欠费超期;
|
|
|
_this.累计欠费 = result.data[0].累计欠费;
|
|
|
_this.信用额度 = result.data[0].信用额度;
|
|
|
|
|
|
_html = _html + "<span style=\"clear:both;color:#000000;backgroud-color:#FF0000\"><p>  " + result.data[0].结费类型 + "</p></span>";
|
|
|
_html = _html + "<span style=\"color:#000000;backgroud-color:#FF0000\"><p>  " + result.data[0].欠费超期 + "</p></span>";
|
|
|
if (result.data[0].超期欠费 != '')
|
|
|
_html = _html + "<span style=\"color:#000000;backgroud-color:#FF0000\"><p>  " + result.data[0].超期欠费 + "</p></span>";
|
|
|
_html = _html + "<span style=\"color:#000000;backgroud-color:#FF0000\"><p>  " + result.data[0].累计欠费 + "</p></span>";
|
|
|
_html = _html + "<span style=\"color:#000000;backgroud-color:#FF0000\"><p>  " + result.data[0].信用额度 + "</p></span>";
|
|
|
_html = _html + "<br></br>";
|
|
|
|
|
|
if (result.data[0].IS欠费超期 == "yes") {
|
|
|
_html = _html + "  <span style=\"color:#900000;text-decoration:none;\">欠费超期</span>";
|
|
|
}
|
|
|
if (result.data[0].IS累计欠费 == "yes") {
|
|
|
_html = _html + "  <span style=\"color:#900000;text-decoration:none;\">总欠费超额度</span>";
|
|
|
}
|
|
|
_html = _html + "</span><br></br>";
|
|
|
Ext.getCmp("FDINFO").update(_html);
|
|
|
} else {
|
|
|
//return;
|
|
|
}
|
|
|
} else {
|
|
|
return;
|
|
|
}
|
|
|
},
|
|
|
scope: this
|
|
|
});
|
|
|
|
|
|
Ext.getCmp("MainSeaiPanel").SelectedRecord = rec;
|
|
|
Ext.getCmp("winFDTZShow").show();
|
|
|
},
|
|
|
DoFDTZ: function (REASON) {
|
|
|
|
|
|
Ext.define('MsOp_BLISSUEmb', {
|
|
|
extend: 'Ext.data.Model',
|
|
|
idProperty: 'GID',
|
|
|
fields: [
|
|
|
{ name: 'GID', type: 'string' },
|
|
|
{ name: 'BSNO', type: 'string' },
|
|
|
{ name: 'BLNO', type: 'string' },
|
|
|
{ name: 'HBLNO', type: 'string' },
|
|
|
{ name: 'ZDFD', type: 'string' },
|
|
|
{ name: 'BLNAME', type: 'string' },
|
|
|
{ name: 'BLSTATUS', type: 'string' },
|
|
|
{ name: 'BLORDERNO', type: 'string' },
|
|
|
{ name: 'ISSUETYPE', type: 'string' },
|
|
|
{ name: 'OPNAME', type: 'string' },
|
|
|
{ name: 'OPTIME', type: 'string' },
|
|
|
{ name: 'BSINKNO', type: 'string' },
|
|
|
{ name: 'REMARK', type: 'string' },
|
|
|
{ name: 'DELFLAG', type: 'string' },
|
|
|
{ name: 'EXPRESSCORP', type: 'string' },
|
|
|
{ name: 'EXPRESSNO', type: 'string' },
|
|
|
{ name: 'ISADD', type: 'string' },
|
|
|
{ name: 'PUTSINGLETIME', type: 'string' },
|
|
|
{ name: 'PUTSINGLE', type: 'string' },
|
|
|
{ name: 'PAYTIME', type: 'string' },
|
|
|
{ name: 'PAYRMB', type: 'string' },
|
|
|
{ name: 'PAYUSD', type: 'string' },
|
|
|
{ name: 'BLTYPE', type: 'string' },
|
|
|
{ name: 'CUSTNO', type: 'string' },
|
|
|
{ name: 'CUSTOMERNAME', type: 'string' },
|
|
|
{ name: 'SALE', type: 'string' },
|
|
|
{ name: 'ACCTYPE', type: 'string' },
|
|
|
{ name: 'ETD', type: 'string' },
|
|
|
{ name: 'STLDATE', type: 'string' },
|
|
|
{ name: 'CARRIER', type: 'string' },
|
|
|
{ name: 'VESSEL', type: 'string' },
|
|
|
{ name: 'VOYNO', type: 'string' },
|
|
|
{ name: 'OP', type: 'string' },
|
|
|
{ name: 'BLISSUESTATUS', type: 'string' },
|
|
|
{ name: 'TSFD', type: 'string' },
|
|
|
{ name: 'XYTS', type: 'string' },
|
|
|
{ name: 'CQTS', type: 'string' },
|
|
|
{ name: 'SJTS', type: 'string' },
|
|
|
{ name: 'RMBNODR', type: 'string' },
|
|
|
{ name: 'USDNODR', type: 'string' },
|
|
|
{ name: 'TTLNODR', type: 'string' },
|
|
|
{ name: 'TTLDR', type: 'string' },
|
|
|
{ name: 'OPLBNAME', type: 'string' },
|
|
|
{ name: 'SPREMARK', type: 'string' }
|
|
|
]
|
|
|
});
|
|
|
|
|
|
var _op_blissue = Ext.create('MsOp_BLISSUEmb', {
|
|
|
'GID': '',
|
|
|
'BSNO': this.SelectedRecord.data.BSNO,
|
|
|
'BLNO': this.SelectedRecord.data.MBLNO,
|
|
|
'BLNAME': '提单',
|
|
|
'BLSTATUS': '',
|
|
|
'BLORDERNO': '',
|
|
|
'ISSUETYPE': this.SelectedRecord.data.ISSUETYPE,
|
|
|
'OPNAME': '',
|
|
|
'OPTIME': '',
|
|
|
'BSINKNO': '',
|
|
|
'REMARK': '',
|
|
|
'DELFLAG': '0',
|
|
|
'EXPRESSCORP': '',
|
|
|
'EXPRESSNO': '',
|
|
|
'ISADD': '0',
|
|
|
'PUTSINGLETIME': '',
|
|
|
'PUTSINGLE': '',
|
|
|
'PAYTIME': '',
|
|
|
'PAYRMB': '0',
|
|
|
'PAYUSD': '0'
|
|
|
|
|
|
});
|
|
|
|
|
|
var bodyList = [];
|
|
|
|
|
|
bodyList.push(_op_blissue);
|
|
|
|
|
|
var jsonBody = ConvertRecordsToJsonAll(bodyList);
|
|
|
|
|
|
if (jsonBody == '') {
|
|
|
return;
|
|
|
}
|
|
|
if (_this.IS欠费超期 == 'yes') {
|
|
|
Ext.Msg.show({ title: Zi.LAN.TiShi, msg: '欠费超期,不允许放单通知!', icon: Ext.Msg.INFO, buttons: Ext.Msg.OK });
|
|
|
return;
|
|
|
}
|
|
|
|
|
|
|
|
|
Ext.Ajax.request({
|
|
|
waitMsg: Zi.LAN.ZhengZaiCaoZuoShuJu,
|
|
|
url: '/MvcShipping/MsOp_BLISSUE/FDTZ',
|
|
|
params: {
|
|
|
USERID: USERID,
|
|
|
data: jsonBody,
|
|
|
REASON: REASON
|
|
|
},
|
|
|
callback: function (options, success, response) {
|
|
|
if (success) {
|
|
|
this.winFDTZShow.close();
|
|
|
Ext.getCmp("REASON").setValue("");
|
|
|
this.storeList.reload();
|
|
|
//this.onRefreshClick();
|
|
|
}
|
|
|
},
|
|
|
failure: function (response, options) {
|
|
|
Ext.Msg.show({ title: Zi.LAN.JingGao, msg: Zi.LAN.FuWuQiXiangYingChuCuo, icon: Ext.Msg.INFO, buttons: Ext.Msg.OK });
|
|
|
},
|
|
|
success: function (response, options) { },
|
|
|
scope: this
|
|
|
}); //end Ext.Ajax.request
|
|
|
},
|
|
|
getFDINFO: function (result) {
|
|
|
var _html = "<span style=\"clear:both;\">";
|
|
|
_this = this;
|
|
|
_this.结费类型 = result.data[0].result.data[0].结费类型.replace("<span style=\"colorred\">", " ").replace("</span>", " ");
|
|
|
_this.欠费超期 = result.data[0].欠费超期;
|
|
|
_this.累计欠费 = result.data[0].累计欠费;
|
|
|
_this.信用额度 = result.data[0].信用额度;
|
|
|
_this.IS欠费超期 = result.data[0].IS欠费超期;
|
|
|
|
|
|
_html = _html + "<span style=\"clear:both;color:#000000;backgroud-color:#FF0000\"><p>  " + result.data[0].结费类型 + "</p></span>";
|
|
|
_html = _html + "<span style=\"color:#000000;backgroud-color:#FF0000\"><p>  " + result.data[0].欠费超期 + "</p></span>";
|
|
|
_html = _html + "<span style=\"color:#000000;backgroud-color:#FF0000\"><p>  " + result.data[0].累计欠费 + "</p></span>";
|
|
|
_html = _html + "<span style=\"color:#000000;backgroud-color:#FF0000\"><p>  " + result.data[0].信用额度 + "</p></span>";
|
|
|
_html = _html + "<br></br>";
|
|
|
|
|
|
if (result.data[0].IS欠费超期 == "yes") {
|
|
|
_html = _html + "  <span style=\"color:#900000;text-decoration:none;\">欠费超期</span>";
|
|
|
}
|
|
|
if (result.data[0].IS累计欠费 == "yes") {
|
|
|
_html = _html + "  <span style=\"color:#900000;text-decoration:none;\">总欠费超额度</span>";
|
|
|
}
|
|
|
_html = _html + "</span><p></p>";
|
|
|
return _html;
|
|
|
},
|
|
|
|
|
|
//#endregion
|
|
|
//#region 打印
|
|
|
Print: function () {
|
|
|
|
|
|
_this = this;
|
|
|
if (this.storeList.getCount() == 0) {
|
|
|
return;
|
|
|
}
|
|
|
|
|
|
Ext.Msg.wait(Zi.LAN.ZhengZaiCaoZuoShuJu); //'正在组织数据, 请稍侯..'
|
|
|
Ext.Ajax.request({
|
|
|
waitMsg: Zi.LAN.ZhengZaiCaoZuoShuJu, //'正在组织数据...',
|
|
|
url: '/MvcShipping/MsOpSeai/GetDataListStr',
|
|
|
scope: this,
|
|
|
params: {
|
|
|
condition: _this.sqlcontext,
|
|
|
printstr: 'true'
|
|
|
},
|
|
|
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 = 'MSOPSEAILIST';
|
|
|
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: Zi.LAN.ChuoWu, msg: jsonresult.Message, icon: Ext.Msg.ERROR, buttons: Ext.Msg.OK });
|
|
|
}
|
|
|
} else {
|
|
|
Ext.Msg.show({ title: Zi.LAN.TiShi, msg: Zi.LAN.FuWuQiXiangYingChuCuo, icon: Ext.Msg.ERROR, buttons: Ext.Msg.OK }); //'请重试', msg: Zi.LAN.FuWuQiXiangYingChuCuo
|
|
|
}
|
|
|
}
|
|
|
});
|
|
|
},
|
|
|
PrintSelect: function () {
|
|
|
|
|
|
_this = this;
|
|
|
if (this.storeList.getCount() == 0) {
|
|
|
return;
|
|
|
}
|
|
|
var selectedRecords = [];
|
|
|
var storeadd = null;
|
|
|
selectedRecords = this.GridCheckBoxModel.selected.items;
|
|
|
|
|
|
|
|
|
if (selectedRecords.length == 0) {
|
|
|
Ext.Msg.show({ title: Zi.LAN.TiShi, msg: Zi.LAN.QingXianXuanZeYeWu, icon: Ext.Msg.INFO, buttons: Ext.Msg.OK }); //'提示', '请先选择要打印的业务!'
|
|
|
return;
|
|
|
}
|
|
|
|
|
|
var sortstr = 'MBLNO desc';
|
|
|
|
|
|
if (this.sortfield != '' && this.sortdire != '') {
|
|
|
|
|
|
sortstr = this.sortfield + ' ' + this.sortdire;
|
|
|
}
|
|
|
|
|
|
|
|
|
var feeGidSql = '';
|
|
|
for (var i = 0; i < selectedRecords.length; i++) {
|
|
|
var record = selectedRecords[i];
|
|
|
var feeGId = "'" + record.get('BSNO') + "'";
|
|
|
if (feeGidSql == '') {
|
|
|
feeGidSql = feeGId;
|
|
|
} else {
|
|
|
feeGidSql = feeGidSql + "," + feeGId;
|
|
|
}
|
|
|
};
|
|
|
|
|
|
var bsno = '11111';
|
|
|
var selections = this.gridList.getSelectionModel().getSelection();
|
|
|
if (selections.length != 0) {
|
|
|
var record = selections[0];
|
|
|
bsno = record.data.BSNO;
|
|
|
}
|
|
|
|
|
|
var printType = 'MSOPSEAILISTSELECT';
|
|
|
var sql1 = "select * from op_seai WHERE MASTERNO IN (" + feeGidSql + ") order by " + sortstr;
|
|
|
var sql2 = "select * from op_seai where BSNO='" + bsno + "'";
|
|
|
var sql3 = "";
|
|
|
var sql4 = "";
|
|
|
var sql5 = "";
|
|
|
var sql6 = "";
|
|
|
|
|
|
PrintComm(printType, sql1, sql2, sql3, sql4, sql5, sql6);
|
|
|
},
|
|
|
//#endregion
|
|
|
//#region 增加cover模块
|
|
|
readingPaneChange: function (btn) {
|
|
|
this.east.add(this.PluginCover);
|
|
|
switch (btn.text) {
|
|
|
case '显示Cover':
|
|
|
this.east.show();
|
|
|
Ext.getCmp('btnCover').setText('隐藏Cover');
|
|
|
_this.RefreshCover(this.bsno);
|
|
|
break;
|
|
|
default:
|
|
|
this.east.hide();
|
|
|
Ext.getCmp('btnCover').setText('显示Cover');
|
|
|
break;
|
|
|
}
|
|
|
},
|
|
|
createEast: function () {
|
|
|
this.east = Ext.create('Ext.panel.Panel', {
|
|
|
layout: 'fit',
|
|
|
region: 'east',
|
|
|
title: 'COVER',
|
|
|
flex: 1,
|
|
|
split: true,
|
|
|
hidden: true,
|
|
|
width: 150,
|
|
|
minWidth: 150,
|
|
|
border: false
|
|
|
});
|
|
|
return this.east;
|
|
|
},
|
|
|
RefreshCover: function (bsno) {
|
|
|
this.PluginCover.loadCoverWithBSNO(bsno);
|
|
|
}
|
|
|
|
|
|
//#endregion
|
|
|
//#region 2018年2月7日 李进举 鼎世 批量整票提交
|
|
|
,onPiLiangZhengPiaoTiJiaoClick: function (menu, event, type) {
|
|
|
|
|
|
var selections = this.GridCheckBoxModel.selected.items;
|
|
|
if (selections.length == 0) {
|
|
|
Ext.Msg.show({ title: Zi.LAN.TiShi, msg: Zi.LAN.QingXianXuanZeYeWu, icon: Ext.Msg.INFO, buttons: Ext.Msg.OK }); //请先选择要更新的业务!
|
|
|
return;
|
|
|
}
|
|
|
var BSNOStr = '';
|
|
|
for (var i = 0; i < selections.length; i++) {
|
|
|
var rec = selections[i];
|
|
|
var BSNO = "'" + rec.data.BSNO + "'";
|
|
|
if (BSNOStr == '')
|
|
|
BSNOStr = BSNO;
|
|
|
else {
|
|
|
|
|
|
BSNOStr = BSNOStr + ',' + BSNO;
|
|
|
}
|
|
|
}
|
|
|
|
|
|
|
|
|
if (BSNOStr == '') {
|
|
|
Ext.Msg.show({ title: Zi.LAN.TiShi, msg: Zi.LAN.MeiYouYaoGengXinDeYeWu, icon: Ext.Msg.INFO, buttons: Ext.Msg.OK });
|
|
|
return;
|
|
|
|
|
|
} else {
|
|
|
Ext.Ajax.request({
|
|
|
waitMsg: '正在查询主表数据...',
|
|
|
url: '/MvcShipping/MsOpSeae/PiLiangZhengPiaoTiJiao',
|
|
|
params: {
|
|
|
bsno: BSNOStr,
|
|
|
statusvalue: type
|
|
|
},
|
|
|
callback: function (options, success, response) {
|
|
|
if (success) {
|
|
|
var result = Ext.JSON.decode(response.responseText);
|
|
|
if (!result.Success) {
|
|
|
Ext.Msg.show({
|
|
|
title: '提示',
|
|
|
msg: result.Message,
|
|
|
icon: Ext.MessageBox.ERROR,
|
|
|
buttons: Ext.Msg.OK
|
|
|
});
|
|
|
return;
|
|
|
}else {
|
|
|
this.storeList.load({
|
|
|
params: { start: 0, limit: this.PageSize, sort: '', condition: _this.sqlcontext, load: 'true' },
|
|
|
waitMsg: Zi.LAN.ZhengZaiChaXunShuJu, //"正在查询数据...",
|
|
|
scope: this
|
|
|
});
|
|
|
Ext.Msg.show({
|
|
|
title: '提示',
|
|
|
msg: result.Message,
|
|
|
icon: Ext.MessageBox.OK,
|
|
|
buttons: Ext.Msg.OK
|
|
|
});
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
} else {
|
|
|
Ext.MessageBox.alert('请求出现错误,请重试', response.responseText);
|
|
|
}
|
|
|
},
|
|
|
scope: this
|
|
|
});
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
}
|
|
|
//#endregion
|
|
|
|
|
|
//#region 2019年9月16日 李进举 鼎世 生成押箱业务
|
|
|
, getselectrecord:function (){
|
|
|
var selections = this.GridCheckBoxModel.selected.items;
|
|
|
if (selections.length == 0) {
|
|
|
Ext.Msg.show({ title: Zi.LAN.TiShi, msg: Zi.LAN.MAKEYX, icon: Ext.Msg.INFO, buttons: Ext.Msg.OK }); //请先选择要更新的业务!
|
|
|
return;
|
|
|
}
|
|
|
return selections[0];
|
|
|
}
|
|
|
|
|
|
, onaddYXClick: function (menu, event, type) {
|
|
|
|
|
|
var selections = this.GridCheckBoxModel.selected.items;
|
|
|
if (selections.length == 0) {
|
|
|
Ext.Msg.show({ title: Zi.LAN.TiShi, msg: Zi.LAN.MAKEYX, icon: Ext.Msg.INFO, buttons: Ext.Msg.OK }); //请先选择要更新的业务!
|
|
|
return;
|
|
|
}
|
|
|
var BSNOStr = '';
|
|
|
for (var i = 0; i < selections.length; i++) {
|
|
|
var rec = selections[i];
|
|
|
var BSNO = "'" + rec.data.BSNO + "'";
|
|
|
if (BSNOStr == '')
|
|
|
BSNOStr = BSNO;
|
|
|
else {
|
|
|
|
|
|
BSNOStr = BSNOStr + ',' + BSNO;
|
|
|
}
|
|
|
}
|
|
|
|
|
|
|
|
|
if (BSNOStr == '') {
|
|
|
Ext.Msg.show({ title: Zi.LAN.TiShi, msg: Zi.LAN.MAKEYX, icon: Ext.Msg.INFO, buttons: Ext.Msg.OK });
|
|
|
return;
|
|
|
} else {
|
|
|
Ext.Ajax.request({
|
|
|
waitMsg: '正在查询主表数据...',
|
|
|
url: '/MvcShipping/MsOp_YAXIANG/MakeYX',
|
|
|
params: {
|
|
|
SeaiGIDListStr: BSNOStr
|
|
|
},
|
|
|
callback: function (options, success, response) {
|
|
|
if (success) {
|
|
|
var result = Ext.JSON.decode(response.responseText);
|
|
|
if (!result.Success) {
|
|
|
Ext.Msg.show({
|
|
|
title: '提示',
|
|
|
msg: result.Message,
|
|
|
icon: Ext.MessageBox.ERROR,
|
|
|
buttons: Ext.Msg.OK
|
|
|
});
|
|
|
return;
|
|
|
} else {
|
|
|
this.storeList.load({
|
|
|
params: { start: 0, limit: this.PageSize, sort: '', condition: _this.sqlcontext, load: 'true' },
|
|
|
waitMsg: Zi.LAN.MAKEYX, //"正在查询数据...",
|
|
|
scope: this
|
|
|
});
|
|
|
Ext.Msg.show({
|
|
|
title: '提示',
|
|
|
msg: result.Message,
|
|
|
icon: Ext.MessageBox.OK,
|
|
|
buttons: Ext.Msg.OK
|
|
|
});
|
|
|
}
|
|
|
} else {
|
|
|
Ext.MessageBox.alert('请求出现错误,请重试', response.responseText);
|
|
|
}
|
|
|
},
|
|
|
scope: this
|
|
|
});
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
}
|
|
|
//#endregion
|
|
|
,onCheckCtnApply: function () {
|
|
|
//恒成 操作模块 点击放箱号,可以跳出成本核算 /MvcContainer/MsOpCtnApply/CostEdit
|
|
|
|
|
|
rec = this.getselectrecord();
|
|
|
APPLYNO = rec.data.APPLYNO;
|
|
|
if (isNullorEmpty(APPLYNO)) return;
|
|
|
DsOpenMultiEditWin('/MvcContainer/MsOpCtnApply/CostEdit?opener=OPSEAI&APPLYNO=' + APPLYNO);
|
|
|
}
|
|
|
});
|
|
|
|
|
|
|