|
|
|
|
Ext.namespace('Shipping');
|
|
|
|
|
|
|
|
|
|
Shipping.MsOpSeaeFenIndex = function (config) {
|
|
|
|
|
Ext.applyIf(this, config);
|
|
|
|
|
this.initUIComponents();
|
|
|
|
|
window.Shipping.MsOpSeaeFenIndex.superclass.constructor.call(this);
|
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
Ext.extend(Shipping.MsOpSeaeFenIndex, Ext.Panel, {
|
|
|
|
|
PageSize: 20,
|
|
|
|
|
OprationStatus: null, //仅当弹出界面时使用
|
|
|
|
|
SelectedRecord: null,
|
|
|
|
|
EditRecord: null,
|
|
|
|
|
BsNo: '',
|
|
|
|
|
sortfield: '',
|
|
|
|
|
sortdire: '',
|
|
|
|
|
mainWin:'',
|
|
|
|
|
|
|
|
|
|
initUIComponents: function () {
|
|
|
|
|
|
|
|
|
|
var mainform = window.panelEdit;
|
|
|
|
|
this.EditRecord = mainform.editRecord;
|
|
|
|
|
this.BsNo = this.EditRecord.get('BSNO');
|
|
|
|
|
|
|
|
|
|
this.mainWin = getMainForm(window.parent.opener);
|
|
|
|
|
|
|
|
|
|
this.formname = "formMsOpSeaeFenIndex"; //页面名称
|
|
|
|
|
//定义数据集
|
|
|
|
|
|
|
|
|
|
this.storectndisp = Ext.create('DsExt.ux.RefTableStore', {
|
|
|
|
|
model: 'DsShipping.ux.CtnDispModel',
|
|
|
|
|
proxy: { url: '/CommMng/BasicDataRef/GetCtnDisp' }
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
this.StoreOpRange = Ext.create('DsExt.ux.RefTableStore', {
|
|
|
|
|
model: 'MsOP',
|
|
|
|
|
proxy: { url: '/MvcShipping/MsBaseInfo/GetOpRang' }
|
|
|
|
|
});
|
|
|
|
|
this.StoreOpRange.load({ params: { optype: "modOrderManagement"} });
|
|
|
|
|
|
|
|
|
|
this.storeList = Ext.create('Ext.data.Store', {
|
|
|
|
|
pageSize: this.PageSize,
|
|
|
|
|
model: 'MsOpSeaeModel',
|
|
|
|
|
remoteSort: true,
|
|
|
|
|
proxy: {
|
|
|
|
|
type: 'ajax',
|
|
|
|
|
url: '/MvcShipping/MsOpSeae/GetFenList',
|
|
|
|
|
reader: {
|
|
|
|
|
id: 'BSNO',
|
|
|
|
|
root: 'data',
|
|
|
|
|
totalProperty: 'totalCount'
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
//#region List列表显示信息
|
|
|
|
|
Ext.grid.RowNumberer = Ext.extend(Ext.grid.RowNumberer, {
|
|
|
|
|
width: 30
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
this.initgirdcolums= [{
|
|
|
|
|
sortable: true,
|
|
|
|
|
id: '',
|
|
|
|
|
dataIndex: '',
|
|
|
|
|
header: '',
|
|
|
|
|
width: 0
|
|
|
|
|
}, {
|
|
|
|
|
sortable: true,
|
|
|
|
|
dataIndex: 'BSNO',
|
|
|
|
|
header: '业务编号',
|
|
|
|
|
width: 0
|
|
|
|
|
}, {
|
|
|
|
|
sortable: true,
|
|
|
|
|
dataIndex: 'CUSTNO',
|
|
|
|
|
header: '委托编号',
|
|
|
|
|
width: 120
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
sortable: true,
|
|
|
|
|
dataIndex: 'BSSTATUSREF',
|
|
|
|
|
header: '业务状态',
|
|
|
|
|
width: 60
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
sortable: true,
|
|
|
|
|
dataIndex: 'FEESTATUSREF',
|
|
|
|
|
header: '费用状态',
|
|
|
|
|
width: 60
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
sortable: true,
|
|
|
|
|
dataIndex: 'BLTYPE',
|
|
|
|
|
header: '装运方式',
|
|
|
|
|
width: 60
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
sortable: true,
|
|
|
|
|
dataIndex: 'ETD',
|
|
|
|
|
header: '开船日期',
|
|
|
|
|
width: 80
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
sortable: true,
|
|
|
|
|
dataIndex: 'MBLNO',
|
|
|
|
|
header: '主提单号',
|
|
|
|
|
width: 120
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
sortable: true,
|
|
|
|
|
dataIndex: 'CUSTOMERNAME',
|
|
|
|
|
header: '委托单位',
|
|
|
|
|
width: 120
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
sortable: true,
|
|
|
|
|
dataIndex: 'BSDATE',
|
|
|
|
|
header: '接单日期',
|
|
|
|
|
width: 80
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
sortable: true,
|
|
|
|
|
dataIndex: 'GOODSNAME',
|
|
|
|
|
header: '品名',
|
|
|
|
|
width: 120
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
sortable: true,
|
|
|
|
|
dataIndex: 'PKGS',
|
|
|
|
|
header: '件数',
|
|
|
|
|
width: 80
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
sortable: true,
|
|
|
|
|
dataIndex: 'KGS',
|
|
|
|
|
header: '毛重',
|
|
|
|
|
width: 80
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
sortable: true,
|
|
|
|
|
dataIndex: 'CNTRTOTAL',
|
|
|
|
|
header: '集装箱',
|
|
|
|
|
width: 80
|
|
|
|
|
},
|
|
|
|
|
|
|
|
|
|
{
|
|
|
|
|
sortable: true,
|
|
|
|
|
dataIndex: 'HBLNO',
|
|
|
|
|
header: '分提单号',
|
|
|
|
|
width: 120
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
sortable: true,
|
|
|
|
|
dataIndex: 'ACCDATE',
|
|
|
|
|
header: '会计期间',
|
|
|
|
|
width: 60
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
sortable: true,
|
|
|
|
|
dataIndex: 'BSSOURCE',
|
|
|
|
|
header: '业务来源',
|
|
|
|
|
width: 80
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
sortable: true,
|
|
|
|
|
dataIndex: 'BSSOURCEDETAIL',
|
|
|
|
|
header: '来源明细',
|
|
|
|
|
width: 80
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
sortable: true,
|
|
|
|
|
dataIndex: 'INPUTBY',
|
|
|
|
|
header: '录入人',
|
|
|
|
|
width: 80
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
sortable: true,
|
|
|
|
|
dataIndex: 'CREATETIME',
|
|
|
|
|
header: '创建时间',
|
|
|
|
|
width: 120
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
sortable: true,
|
|
|
|
|
dataIndex: 'OP',
|
|
|
|
|
header: '操作员',
|
|
|
|
|
width: 80
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
sortable: true,
|
|
|
|
|
dataIndex: 'SALE',
|
|
|
|
|
header: '揽货人',
|
|
|
|
|
width: 80
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
sortable: true,
|
|
|
|
|
dataIndex: 'VESSEL',
|
|
|
|
|
header: '船名',
|
|
|
|
|
width: 100
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
sortable: true,
|
|
|
|
|
dataIndex: 'VOYNO',
|
|
|
|
|
header: '航次',
|
|
|
|
|
width: 60
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
sortable: true,
|
|
|
|
|
dataIndex: 'PORTLOAD',
|
|
|
|
|
header: '装货港',
|
|
|
|
|
width: 100
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
sortable: true,
|
|
|
|
|
dataIndex: 'PORTDISCHARGE',
|
|
|
|
|
header: '卸货港',
|
|
|
|
|
width: 100
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
sortable: true,
|
|
|
|
|
dataIndex: 'CUSTOMSER',
|
|
|
|
|
header: '报关行',
|
|
|
|
|
width: 80
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
sortable: true,
|
|
|
|
|
dataIndex: 'KINDPKGS',
|
|
|
|
|
header: '件数包装',
|
|
|
|
|
width: 60
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
sortable: true,
|
|
|
|
|
dataIndex: 'CBM',
|
|
|
|
|
header: '立方/尺码',
|
|
|
|
|
width: 60
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
sortable: true,
|
|
|
|
|
dataIndex: 'CARRIER',
|
|
|
|
|
header: '船公司',
|
|
|
|
|
width: 100
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
sortable: true,
|
|
|
|
|
dataIndex: 'TRUCKER',
|
|
|
|
|
header: '承运车队',
|
|
|
|
|
width: 100
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
sortable: true,
|
|
|
|
|
dataIndex: 'VOUNO',
|
|
|
|
|
header: '凭证号',
|
|
|
|
|
width: 60
|
|
|
|
|
}];
|
|
|
|
|
this.Pagenum = Ext.create('Ext.form.field.Number', {
|
|
|
|
|
name: 'bottles',
|
|
|
|
|
fieldLabel: '每页记录数', //'每页记录数',
|
|
|
|
|
labelAlign: 'right',
|
|
|
|
|
value: this.PageSize,
|
|
|
|
|
maxValue: 100000,
|
|
|
|
|
width: 180,
|
|
|
|
|
minValue: 0,
|
|
|
|
|
listeners: {
|
|
|
|
|
specialkey: function (field, e) {
|
|
|
|
|
if (e.getKey() == e.ENTER) {
|
|
|
|
|
_thisfenlist.onRefreshClick();
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
this.girdcolums=this.initgirdcolums;
|
|
|
|
|
|
|
|
|
|
this.GridCheckBoxFenModel = Ext.create('Ext.selection.CheckboxModel');
|
|
|
|
|
|
|
|
|
|
//定义Grid
|
|
|
|
|
this.gridList = new Ext.grid.GridPanel({
|
|
|
|
|
store: this.storeList,
|
|
|
|
|
enableHdMenu: false,
|
|
|
|
|
region: 'center',
|
|
|
|
|
loadMask: { msg: "数据加载中,请稍等..." },
|
|
|
|
|
trackMouseOver: true,
|
|
|
|
|
selModel: this.GridCheckBoxFenModel,
|
|
|
|
|
disableSelection: false,
|
|
|
|
|
columns: this.girdcolums,
|
|
|
|
|
bbar: [Ext.create('Ext.PagingToolbar', {
|
|
|
|
|
store: this.storeList,
|
|
|
|
|
displayInfo: true,
|
|
|
|
|
displayMsg: '当前显示 {0} - {1}条记录 /共 {2}条记录', //'当前显示 {0} - {1}条记录 /共 {2}条记录',
|
|
|
|
|
emptyMsg: "没有数据"//'没有数据'
|
|
|
|
|
}), this.Pagenum]
|
|
|
|
|
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
/////////////以下部分为获取存储的gridpanel显示样式
|
|
|
|
|
// this.column = DsTruck.GetGridPanel(USERID, this.formname, this.girdcolums, 1); //使用者id,表名,中间column数组,跳过一开始的几列
|
|
|
|
|
|
|
|
|
|
this.girdcolums = DsTruck.GetGridPanel(USERID, this.formname, this.girdcolums, 1); //使用者id,表名,中间column数组,跳过一开始的几列
|
|
|
|
|
|
|
|
|
|
this.gridList.reconfigure(this.storeList, this.girdcolums);
|
|
|
|
|
this.gridList.columns[0] = new Ext.grid.RowNumberer();
|
|
|
|
|
////////////////////////////////////////////////
|
|
|
|
|
|
|
|
|
|
this.gridList.addListener('itemdblclick', function (dataview, record, item, index, e, b) {
|
|
|
|
|
this.SelectedRecord = record;
|
|
|
|
|
this.OprationStatus = 'edit';
|
|
|
|
|
DsOpenEditWin('/MvcShipping/MsOpSeae/Edit', "分票信息");
|
|
|
|
|
}, this);
|
|
|
|
|
this.gridList.addListener('sortchange', function (ct, column, direction, eOpts) {
|
|
|
|
|
this.sortfield = column.dataIndex;
|
|
|
|
|
this.sortdire = direction;
|
|
|
|
|
}, this);
|
|
|
|
|
|
|
|
|
|
_thisfenlist = this;
|
|
|
|
|
//按钮工具条
|
|
|
|
|
this.panelBtn = new Ext.Panel({
|
|
|
|
|
region: "north",
|
|
|
|
|
tbar: [{
|
|
|
|
|
text: "新建",
|
|
|
|
|
iconCls: "btnadd",
|
|
|
|
|
handler: function (button, event) {
|
|
|
|
|
if (this.EditRecord.get('BSSTATUSREF') == '锁定') {
|
|
|
|
|
Ext.Msg.show({ title: '提示', msg: '主票已业务锁定,不允许添加分票!', icon: Ext.Msg.INFO, buttons: Ext.Msg.OK });
|
|
|
|
|
return;
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
this.OprationStatus = 'add';
|
|
|
|
|
DsOpenEditWin('/MvcShipping/MsOpSeae/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 = 'copyadd';
|
|
|
|
|
DsOpenEditWin('/MvcShipping/MsOpSeae/Edit', "分票信息");
|
|
|
|
|
},
|
|
|
|
|
scope: this
|
|
|
|
|
}, {
|
|
|
|
|
text: "删除",
|
|
|
|
|
iconCls: "btndelete",
|
|
|
|
|
handler: function (button, event) {
|
|
|
|
|
this.onDeleteClick(button, event);
|
|
|
|
|
},
|
|
|
|
|
scope: this
|
|
|
|
|
}, '-', {
|
|
|
|
|
text: "执行查询",
|
|
|
|
|
iconCls: "btnrefresh",
|
|
|
|
|
handler: function (button, event) {
|
|
|
|
|
this.onRefreshClick(button, event);
|
|
|
|
|
},
|
|
|
|
|
scope: this
|
|
|
|
|
}, {
|
|
|
|
|
text: "重置条件",
|
|
|
|
|
iconCls: "btnreset",
|
|
|
|
|
handler: function (button, event) {
|
|
|
|
|
this.onClearSql(button, event);
|
|
|
|
|
},
|
|
|
|
|
scope: this
|
|
|
|
|
}, '-', {
|
|
|
|
|
text: Zi.LAN.btntest, //"保存列表样式",
|
|
|
|
|
id: "btntest",
|
|
|
|
|
menu: [
|
|
|
|
|
{ text: Zi.LAN.SaveGridPanel, //"保存",
|
|
|
|
|
handler: function (button, event) {
|
|
|
|
|
_thisfenlist.girdcolums = DsTruck.SaveGridPanel(USERID, _thisfenlist.formname, _thisfenlist.gridList.columns, _thisfenlist.girdcolums, 1, true);
|
|
|
|
|
}
|
|
|
|
|
}, { text: Zi.LAN.SaveGridPanel2, //"初始化",
|
|
|
|
|
handler: function (menu, event) {
|
|
|
|
|
_thisfenlist.gridList.reconfigure(_thisfenlist.storeList, _thisfenlist.initgirdcolums);
|
|
|
|
|
_thisfenlist.girdcolums = DsTruck.SaveGridPanel(USERID, _thisfenlist.formname, _thisfenlist.gridList.columns, _thisfenlist.initgirdcolums, 1, true);
|
|
|
|
|
}
|
|
|
|
|
}],
|
|
|
|
|
scope: this
|
|
|
|
|
}, '-', {
|
|
|
|
|
text: Zi.LAN.EdiExport, //"EDI报文导出",
|
|
|
|
|
menu: [{
|
|
|
|
|
text: Zi.LAN.CargoSmartEDI, //"Cargo Smart",
|
|
|
|
|
handler: function (menu, event) {
|
|
|
|
|
_thisfenlist.onCreateCargoSmartEDIClick(menu, event);
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
],
|
|
|
|
|
scope: this
|
|
|
|
|
}, '-', {
|
|
|
|
|
text: Zi.LAN.GuoWaiCangDan, //"国外舱单",
|
|
|
|
|
menu: [
|
|
|
|
|
{ text: Zi.LAN.JapanAFR, //"日本AFR",
|
|
|
|
|
handler: function (menu, event) {
|
|
|
|
|
_thisfenlist.onCreateAfrClick(menu, event, 1);
|
|
|
|
|
}
|
|
|
|
|
}, { text: Zi.LAN.JapanAMR, //"日本AMR",
|
|
|
|
|
handler: function (menu, event) {
|
|
|
|
|
_thisfenlist.onCreateAfrClick(menu, event, 2);
|
|
|
|
|
}
|
|
|
|
|
}, { text: Zi.LAN.AMS, //"AMS",
|
|
|
|
|
handler: function (menu, event) {
|
|
|
|
|
_thisfenlist.onCreateAfrClick(menu, event, 3);
|
|
|
|
|
}
|
|
|
|
|
}, { text: Zi.LAN.JapanAFRZF, //"直发日本AFR",
|
|
|
|
|
handler: function (menu, event) {
|
|
|
|
|
_thisfenlist.onCreateAfrZFClick(menu, event, 1);
|
|
|
|
|
}
|
|
|
|
|
}, { text: Zi.LAN.JapanAMRZF, //"直发日本AMR",
|
|
|
|
|
handler: function (menu, event) {
|
|
|
|
|
_thisfenlist.onCreateAfrZFClick(menu, event, 2);
|
|
|
|
|
}
|
|
|
|
|
}, { text: Zi.LAN.AMSZF, //"直发AMS",
|
|
|
|
|
handler: function (menu, event) {
|
|
|
|
|
_thisfenlist.onCreateAfrZFClick(menu, event, 3);
|
|
|
|
|
}
|
|
|
|
|
}, { text: Zi.LAN.JapanAFRZF + "(CargoSmart)", //"直发日本AFR",
|
|
|
|
|
handler: function (menu, event) {
|
|
|
|
|
_this.onCreateAfrCSZFClick(menu, event, 'CGAFR');
|
|
|
|
|
}
|
|
|
|
|
}],
|
|
|
|
|
scope: this
|
|
|
|
|
}, '-',
|
|
|
|
|
{
|
|
|
|
|
text: Zi.LAN.btnprint, //"打印",
|
|
|
|
|
iconCls: 'btnprint',
|
|
|
|
|
menu: [
|
|
|
|
|
{ text: Zi.LAN.Print, //"全部",
|
|
|
|
|
handler: function (menu, event) {
|
|
|
|
|
_thisfenlist.Print();
|
|
|
|
|
}
|
|
|
|
|
}, { text: Zi.LAN.PrintSelect, //"选择打印",
|
|
|
|
|
handler: function (menu, event) {
|
|
|
|
|
_thisfenlist.PrintSelect();
|
|
|
|
|
}
|
|
|
|
|
}],
|
|
|
|
|
|
|
|
|
|
scope: this
|
|
|
|
|
}, '-', {
|
|
|
|
|
text: Zi.LAN.OtherCaoZuo, //"其他操作",
|
|
|
|
|
menu: [{
|
|
|
|
|
text: Zi.LAN.winModifyShow, //"业务批量修改",
|
|
|
|
|
handler: function (menu, event) {
|
|
|
|
|
_thisfenlist.winModifyShow.show();
|
|
|
|
|
}
|
|
|
|
|
}]
|
|
|
|
|
}]
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
this.panelTop = new Ext.Panel({
|
|
|
|
|
layout: "border",
|
|
|
|
|
region: "north",
|
|
|
|
|
height: 30,
|
|
|
|
|
items: [this.panelBtn]
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
Ext.apply(this, {
|
|
|
|
|
items: [this.panelTop, this.gridList]
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
this.onRefreshClick();
|
|
|
|
|
|
|
|
|
|
this.storeList.on('beforeload', function (store) {
|
|
|
|
|
var sql = "BSNO<>'" + this.BsNo + "' and MASTERNO='" + this.BsNo + "'";
|
|
|
|
|
Ext.apply(store.proxy.extraParams, { condition: sql });
|
|
|
|
|
}, this);
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
//#region 批量修改窗体
|
|
|
|
|
//客户加载_场站
|
|
|
|
|
this.storeYARD = Ext.create('DsExt.ux.RefTableStore', {
|
|
|
|
|
model: 'DsShipping.ux.CustomRefModel',
|
|
|
|
|
proxy: { url: '/CommMng/BasicDataRef/GetCustomRefListYARD' }
|
|
|
|
|
});
|
|
|
|
|
// this.storeYARD.load({ params: { condition: "ISYARD='1'"} });
|
|
|
|
|
//船公司
|
|
|
|
|
this.comboxYARD2 = Ext.create('DsExt.ux.RefTableCombox', {
|
|
|
|
|
fieldLabel: Zi.LAN.YARD, //'场站',
|
|
|
|
|
store: this.storeYARD,
|
|
|
|
|
queryMode: 'remote',
|
|
|
|
|
minChars: 1,
|
|
|
|
|
queryParam: 'CODENAME',
|
|
|
|
|
name: 'YARD',
|
|
|
|
|
valueField: 'CustName',
|
|
|
|
|
displayField: 'CodeAndName'
|
|
|
|
|
});
|
|
|
|
|
//客户加载_船公司
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
//船公司
|
|
|
|
|
this.storeCARRIER = Ext.create('DsExt.ux.RefTableStore', {
|
|
|
|
|
model: 'DsShipping.ux.CustomRefModel',
|
|
|
|
|
proxy: { url: '/CommMng/BasicDataRef/GetCustomRefListCARRIER' }
|
|
|
|
|
});
|
|
|
|
|
// this.storeCARRIER.load({ params: { condition: "ISCARRIER='1'"} });
|
|
|
|
|
this.comboxCARRIER2 = Ext.create('DsExt.ux.RefTableCombox', {
|
|
|
|
|
fieldLabel: Zi.LAN.CARRIER, //'船公司',
|
|
|
|
|
store: this.storeCARRIER,
|
|
|
|
|
queryMode: 'remote',
|
|
|
|
|
minChars: 1,
|
|
|
|
|
queryParam: 'CODENAME',
|
|
|
|
|
name: 'CARRIER',
|
|
|
|
|
valueField: 'CustName',
|
|
|
|
|
displayField: 'CodeAndName'
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
//客户加载_订舱代理
|
|
|
|
|
this.storeFORWARDER = Ext.create('DsExt.ux.RefTableStore', {
|
|
|
|
|
model: 'DsShipping.ux.CustomRefModel',
|
|
|
|
|
proxy: { url: '/CommMng/BasicDataRef/GetCustomRefListFORWARDER' }
|
|
|
|
|
});
|
|
|
|
|
// this.storeFORWARDER.load({ params: { condition: "ISBOOKING='1'"} });
|
|
|
|
|
//船公司
|
|
|
|
|
this.comboxFORWARDER2 = Ext.create('DsExt.ux.RefTableCombox', {
|
|
|
|
|
fieldLabel: Zi.LAN.FORWARDER, //'订舱代理',
|
|
|
|
|
store: this.storeFORWARDER,
|
|
|
|
|
queryMode: 'remote',
|
|
|
|
|
minChars: 1,
|
|
|
|
|
queryParam: 'CODENAME',
|
|
|
|
|
name: 'FORWARDER',
|
|
|
|
|
valueField: 'CustName',
|
|
|
|
|
displayField: 'CodeAndName'
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
//客户加载_车队
|
|
|
|
|
this.storeTRUCKER = Ext.create('DsExt.ux.RefTableStore', {
|
|
|
|
|
model: 'DsShipping.ux.CustomRefModel',
|
|
|
|
|
proxy: { url: '/CommMng/BasicDataRef/GetCustomRefListTRUCK' }
|
|
|
|
|
});
|
|
|
|
|
// this.storeTRUCKER.load({ params: { condition: "ISTRUCK='1'"} });
|
|
|
|
|
//车队
|
|
|
|
|
this.comboxTRUCKER2 = Ext.create('DsExt.ux.RefTableCombox', {
|
|
|
|
|
fieldLabel: Zi.LAN.TRUCKER, //'车队',
|
|
|
|
|
store: this.storeTRUCKER,
|
|
|
|
|
queryMode: 'remote',
|
|
|
|
|
minChars: 1,
|
|
|
|
|
queryParam: 'CODENAME',
|
|
|
|
|
name: 'TRUCKER',
|
|
|
|
|
valueField: 'CustName',
|
|
|
|
|
displayField: 'CodeAndName'
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
//客户加载_报关报检
|
|
|
|
|
|
|
|
|
|
//报关行
|
|
|
|
|
this.storeCUSTOMSER = Ext.create('DsExt.ux.RefTableStore', {
|
|
|
|
|
model: 'DsShipping.ux.CustomRefModel',
|
|
|
|
|
proxy: { url: '/CommMng/BasicDataRef/GetCustomRefListCUSTOM' }
|
|
|
|
|
});
|
|
|
|
|
// this.storeCUSTOMSER.load({ params: { condition: "ISCUSTOM='1'"} });
|
|
|
|
|
this.comboxCUSTOMSER2 = Ext.create('DsExt.ux.RefTableCombox', {
|
|
|
|
|
fieldLabel: Zi.LAN.CUSTOMSER, //'报关行',
|
|
|
|
|
store: this.storeCUSTOMSER,
|
|
|
|
|
queryMode: 'remote',
|
|
|
|
|
minChars: 1,
|
|
|
|
|
queryParam: 'CODENAME',
|
|
|
|
|
name: 'CUSTOMSER',
|
|
|
|
|
valueField: 'CustName',
|
|
|
|
|
displayField: 'CodeAndName'
|
|
|
|
|
});
|
|
|
|
|
this.storeLANE = Ext.create('DsExt.ux.RefTableStore', {
|
|
|
|
|
model: 'DsShipping.ux.Lane',
|
|
|
|
|
proxy: { url: '/CommMng/BasicDataRef/GetCodeLaneList' }
|
|
|
|
|
});
|
|
|
|
|
this.storeLANE.load();
|
|
|
|
|
this.comboxLANE2 = Ext.create('DsExt.ux.RefTableCombox', {
|
|
|
|
|
fieldLabel: Zi.LAN.LANE, //'航线',
|
|
|
|
|
store: this.storeLANE,
|
|
|
|
|
// forceSelection: true,
|
|
|
|
|
name: 'LANE',
|
|
|
|
|
valueField: 'LANE',
|
|
|
|
|
displayField: 'LANE'
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
//客户加载_代理
|
|
|
|
|
|
|
|
|
|
// this.storeShipper.load({ params: { condition: "ISCONTROLLER='1'"} });
|
|
|
|
|
|
|
|
|
|
//收货人
|
|
|
|
|
this.storeagent = Ext.create('DsExt.ux.RefTableStore', {
|
|
|
|
|
model: 'OpSeaeShipper',
|
|
|
|
|
proxy: { url: '/MvcShipping/MsOpSeae/GetShipperList' }
|
|
|
|
|
});
|
|
|
|
|
this.storeagent.load({
|
|
|
|
|
params: { condition: "shippertype=4" },
|
|
|
|
|
callback: function (r, options, success) {
|
|
|
|
|
if (success) {
|
|
|
|
|
}
|
|
|
|
|
},
|
|
|
|
|
scope: this
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
this.comboxAgent2 = Ext.create('DsExt.ux.RefTableCombox', {
|
|
|
|
|
fieldLabel: Zi.LAN.AGENTID, //'代 理',
|
|
|
|
|
store: this.storeagent,
|
|
|
|
|
// forceSelection: true,
|
|
|
|
|
name: 'AGENTID',
|
|
|
|
|
valueField: 'SHORTNAME',
|
|
|
|
|
displayField: 'CodeAndName',
|
|
|
|
|
listeners: {
|
|
|
|
|
scope: this,
|
|
|
|
|
'select': function (combo, records, eOpts) {
|
|
|
|
|
if (records.length > 0) {
|
|
|
|
|
var selectrecords = DsStoreQueryBy(this.storeagent, 'SHORTNAME', combo.value);
|
|
|
|
|
if (selectrecords.getCount() > 0) {
|
|
|
|
|
var selectdata = selectrecords.getAt(0).data;
|
|
|
|
|
this.formModify.getForm().findField('AGENT').setValue(selectdata.SHIPPERDETAIL);
|
|
|
|
|
} else {
|
|
|
|
|
this.formModify.getForm().findField('AGENT').setValue('');
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
this.storeCodeLoadport = Ext.create('DsExt.ux.RefTableStore', {
|
|
|
|
|
model: 'DsShipping.ux.CodeLoadportModel',
|
|
|
|
|
proxy: { url: '/CommMng/BasicDataRef/GetCodeLoadportList' }
|
|
|
|
|
});
|
|
|
|
|
this.storeCodeLoadport.load();
|
|
|
|
|
this.comboxPORTLOAD2 = Ext.create('DsExt.ux.RefTableCombox', {
|
|
|
|
|
fieldLabel: Zi.LAN.PORTLOAD, //'装货港',
|
|
|
|
|
store: this.storeCodeLoadport,
|
|
|
|
|
name: 'PORTLOAD',
|
|
|
|
|
valueField: 'PORT',
|
|
|
|
|
displayField: 'CodeAndName',
|
|
|
|
|
listeners: {
|
|
|
|
|
scope: this,
|
|
|
|
|
'select': function (combo, records, eOpts) {
|
|
|
|
|
if (records.length > 0) {
|
|
|
|
|
var selectrecords = DsStoreQueryBy(this.storeCodeLoadport, 'PORT', combo.value);
|
|
|
|
|
if (selectrecords.getCount() > 0) {
|
|
|
|
|
var selectdata = selectrecords.getAt(0).data;
|
|
|
|
|
this.formModify.getForm().findField('PORTLOADID').setValue(selectdata.EDICODE);
|
|
|
|
|
} else {
|
|
|
|
|
this.formModify.getForm().findField('PORTLOADID').setValue('');
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
this.comboxPORTDISCHARGE2 = Ext.create('DsExt.ux.RefTableCombox', {
|
|
|
|
|
fieldLabel: Zi.LAN.PORTDISCHARGE, //'卸货港',
|
|
|
|
|
store: this.storeCodeDisport,
|
|
|
|
|
name: 'PORTDISCHARGE',
|
|
|
|
|
valueField: 'PORT',
|
|
|
|
|
queryMode: 'remote',
|
|
|
|
|
minChars: 1,
|
|
|
|
|
queryParam: 'PORT',
|
|
|
|
|
displayField: 'PORT',
|
|
|
|
|
listeners: {
|
|
|
|
|
scope: this,
|
|
|
|
|
'select': function (combo, records, eOpts) {
|
|
|
|
|
if (records.length > 0) {
|
|
|
|
|
var selectrecords = DsStoreQueryBy(this.storeCodeDisport, 'PORT', combo.value);
|
|
|
|
|
if (selectrecords.getCount() > 0) {
|
|
|
|
|
var selectdata = selectrecords.getAt(0).data;
|
|
|
|
|
this.formModify.getForm().findField('PORTDISCHARGEID').setValue(selectdata.EDICODE);
|
|
|
|
|
|
|
|
|
|
} else {
|
|
|
|
|
this.formModify.getForm().findField('PORTDISCHARGEID').setValue('');
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
});
|
|
|
|
|
this.storeVoyVeg = Ext.create('DsExt.ux.RefTableStore', {
|
|
|
|
|
model: 'DsShipping.ux.VesselModel',
|
|
|
|
|
proxy: { url: '/CommMng/BasicDataRef/GetVesselList' }
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
this.storeVoyVeg.load();
|
|
|
|
|
this.comboxVoyVeg2 = Ext.create('DsExt.ux.RefTableCombox', {
|
|
|
|
|
fieldLabel: Zi.LAN.VESSEL, //'船 名',
|
|
|
|
|
store: this.storeVoyVeg,
|
|
|
|
|
name: 'VESSEL',
|
|
|
|
|
valueField: 'VESSEL',
|
|
|
|
|
flex: 1.5,
|
|
|
|
|
displayField: 'VESSEL'
|
|
|
|
|
});
|
|
|
|
|
this.storeOpCode = Ext.create('DsExt.ux.RefTableStore', {
|
|
|
|
|
model: 'DsShipping.ux.UserRefModel',
|
|
|
|
|
proxy: { url: '/CommMng/BasicDataRef/GetUserLinkRefList' }
|
|
|
|
|
});
|
|
|
|
|
this.storeOpCode.load();
|
|
|
|
|
this.comboxSALE = Ext.create('DsExt.ux.RefTableCombox', {
|
|
|
|
|
fieldLabel: Zi.LAN.SALE, //'揽货人',
|
|
|
|
|
store: this.storeOpCode,
|
|
|
|
|
name: 'SALE',
|
|
|
|
|
valueField: 'UserName',
|
|
|
|
|
displayField: 'CodeAndName'
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
//业务来源
|
|
|
|
|
this.storeSource = Ext.create('DsExt.ux.RefTableStore', {
|
|
|
|
|
model: 'DsShipping.ux.SourceModel',
|
|
|
|
|
proxy: { url: '/CommMng/BasicDataRef/GetSource' }
|
|
|
|
|
});
|
|
|
|
|
this.storeSource.load();
|
|
|
|
|
this.comboxBSSOURCE = Ext.create('DsExt.ux.RefTableCombox', {
|
|
|
|
|
fieldLabel: Zi.LAN.BSSOURCE, //'业务来源',
|
|
|
|
|
store: this.storeSource,
|
|
|
|
|
// forceSelection: true,
|
|
|
|
|
name: 'BSSOURCE',
|
|
|
|
|
valueField: 'SourceName',
|
|
|
|
|
displayField: 'SourceName'
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
this.StoreBLTYPE = Ext.create('DsExt.ux.RefTableStore', {
|
|
|
|
|
model: 'DsExtEnumModel',
|
|
|
|
|
proxy: { url: '/CommMng/PubSys/GetEnumValueList' }
|
|
|
|
|
});
|
|
|
|
|
this.StoreBLTYPE.load({ params: { enumTypeId: 97042 } });
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
this.comboxBLTYPE = Ext.create('DsExt.ux.RefTableCombox', {
|
|
|
|
|
fieldLabel: Zi.LAN.BLTYPE, //'装运方式',
|
|
|
|
|
store: this.StoreBLTYPE,
|
|
|
|
|
name: 'BLTYPE',
|
|
|
|
|
valueField: 'EnumValueName',
|
|
|
|
|
displayField: 'EnumValueName'
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
this.comboxCUSTSERVICE2 = Ext.create('DsExt.ux.RefTableCombox', {
|
|
|
|
|
fieldLabel: Zi.LAN.CUSTSERVICE, //'客服',
|
|
|
|
|
store: this.storeOpCode,
|
|
|
|
|
forceSelection: true,
|
|
|
|
|
queryMode: 'remote',
|
|
|
|
|
minChars: 0,
|
|
|
|
|
queryParam: 'CODENAME',
|
|
|
|
|
name: 'CUSTSERVICE',
|
|
|
|
|
//labelWidth: 45,
|
|
|
|
|
//flex: 0.6,
|
|
|
|
|
valueField: 'UserName',
|
|
|
|
|
displayField: 'CodeAndName'
|
|
|
|
|
});
|
|
|
|
|
this.comboxDOC2 = Ext.create('DsExt.ux.RefTableCombox', {
|
|
|
|
|
fieldLabel: Zi.LAN.DOC, //'客服',
|
|
|
|
|
store: this.storeSaleCode,
|
|
|
|
|
forceSelection: true,
|
|
|
|
|
queryMode: 'remote',
|
|
|
|
|
minChars: 0,
|
|
|
|
|
queryParam: 'CODENAME',
|
|
|
|
|
name: 'DOC',
|
|
|
|
|
//labelWidth: 45,
|
|
|
|
|
//flex: 0.6,
|
|
|
|
|
valueField: 'UserName',
|
|
|
|
|
displayField: 'CodeAndName'
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
this.comboxFRCUSTSERVICE2 = Ext.create('DsExt.ux.RefTableCombox', {
|
|
|
|
|
fieldLabel: Zi.LAN.FRCUSTSERVICE, //'客服',
|
|
|
|
|
store: this.storeOpCode,
|
|
|
|
|
forceSelection: true,
|
|
|
|
|
queryMode: 'remote',
|
|
|
|
|
minChars: 0,
|
|
|
|
|
queryParam: 'CODENAME',
|
|
|
|
|
name: 'FRCUSTSERVICE',
|
|
|
|
|
//labelWidth: 45,
|
|
|
|
|
//flex: 0.6,
|
|
|
|
|
valueField: 'UserName',
|
|
|
|
|
displayField: 'CodeAndName'
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
this.storeOpCode3 = Ext.create('DsExt.ux.RefTableStore', {
|
|
|
|
|
model: 'DsShipping.ux.UserRefModel',
|
|
|
|
|
proxy: { url: '/CommMng/BasicDataRef/GetUserLinkRefListRm' }
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
//操 作
|
|
|
|
|
this.comboxOP3 = Ext.create('DsExt.ux.RefTableCombox', {
|
|
|
|
|
fieldLabel: Zi.LAN.OP, //'操 作',
|
|
|
|
|
store: this.storeOpCode3,
|
|
|
|
|
queryMode: 'remote',
|
|
|
|
|
minChars: 0,
|
|
|
|
|
queryParam: 'CODENAME',
|
|
|
|
|
// labelWidth: 30,
|
|
|
|
|
forceSelection: true,
|
|
|
|
|
name: 'OP',
|
|
|
|
|
valueField: 'UserName',
|
|
|
|
|
displayField: 'CodeAndName',
|
|
|
|
|
enableKeyEvents: true
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
//客户加载_船代
|
|
|
|
|
this.storeSHIPAGENCY = Ext.create('DsExt.ux.RefTableStore', {
|
|
|
|
|
model: 'DsShipping.ux.CustomRefModel',
|
|
|
|
|
proxy: { url: '/CommMng/BasicDataRef/GetCustomRefListSHIPAGENCY' }
|
|
|
|
|
});
|
|
|
|
|
//船代
|
|
|
|
|
this.comboxSHIPAGENCY = Ext.create('DsExt.ux.RefTableCombox', {
|
|
|
|
|
fieldLabel: Zi.LAN.SHIPAGENCY, //'船代',
|
|
|
|
|
store: this.storeSHIPAGENCY,
|
|
|
|
|
forceSelection: true,
|
|
|
|
|
queryMode: 'remote',
|
|
|
|
|
minChars: 0,
|
|
|
|
|
queryParam: 'CODENAME',
|
|
|
|
|
name: 'SHIPAGENCY',
|
|
|
|
|
valueField: 'CustName',
|
|
|
|
|
displayField: 'CodeAndName'
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
//客户加载_委托单位
|
|
|
|
|
this.storeCustCodeM = Ext.create('DsExt.ux.RefTableStore', {
|
|
|
|
|
model: 'DsShipping.ux.CustomRefModel',
|
|
|
|
|
proxy: { url: '/CommMng/BasicDataRef/GetCustomRefListController' }
|
|
|
|
|
});
|
|
|
|
|
// this.storeCustCode.load({ params: { condition: "ISCONTROLLER='1'"} });
|
|
|
|
|
// this.storeCustCode.loadData(mainWin.GetPubStore("OPSEAE_CUST_ISCONTROLLER").data.items);
|
|
|
|
|
|
|
|
|
|
//委托单位
|
|
|
|
|
|
|
|
|
|
this.comboxCustCodeM = Ext.create('DsExt.ux.RefTableCombox', {
|
|
|
|
|
fieldLabel: Zi.LAN.CUSTOMERNAME, //'委托单位',
|
|
|
|
|
store: this.storeCustCodeM,
|
|
|
|
|
queryMode: 'remote',
|
|
|
|
|
matchFieldWidth: false,
|
|
|
|
|
minChars: 1,
|
|
|
|
|
queryParam: 'CODENAME',
|
|
|
|
|
name: 'CUSTOMERNAME',
|
|
|
|
|
valueField: 'CustName',
|
|
|
|
|
displayField: 'CodeAndName',
|
|
|
|
|
enableKeyEvents: true,
|
|
|
|
|
listeners: {
|
|
|
|
|
keyup: function (field, e) {
|
|
|
|
|
if (e.getKey() == e.ENTER) {
|
|
|
|
|
_thisfenlist.onRefreshClick();
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
//,
|
|
|
|
|
//'beforequery': function (e) {
|
|
|
|
|
// return FilterCombox(e,2);//在beforequery使用此方法
|
|
|
|
|
//}
|
|
|
|
|
, specialkey: function (field, e) {
|
|
|
|
|
//if (e.getKey() == e.ENTER) {
|
|
|
|
|
// e.keyCode = 9;
|
|
|
|
|
//}
|
|
|
|
|
if (e.keyCode == 9) {
|
|
|
|
|
|
|
|
|
|
if (field.value == null) {
|
|
|
|
|
_rec = _thisfenlist.storeCustCode.getAt(0);
|
|
|
|
|
|
|
|
|
|
_thisfenlist.formModify.getForm().findField('CUSTOMERNAME').setValue(_rec.data.CustName);
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
//所属部门
|
|
|
|
|
this.storeDept = Ext.create('DsExt.ux.RefTableStore', {
|
|
|
|
|
model: 'DsShipping.ux.DeptModel',
|
|
|
|
|
proxy: { url: '/CommMng/BasicDataRef/GetDeptList' }
|
|
|
|
|
});
|
|
|
|
|
this.storeDept.load();
|
|
|
|
|
this.comboxDept = Ext.create('DsExt.ux.RefTableCombox', {
|
|
|
|
|
fieldLabel: Zi.LAN.SALEDEPT2, //'所属部门',
|
|
|
|
|
store: this.storeDept,
|
|
|
|
|
//flex: 0.5,
|
|
|
|
|
//labelWidth: 55,
|
|
|
|
|
forceSelection: true,
|
|
|
|
|
name: 'SALEDEPT',
|
|
|
|
|
valueField: 'DeptName',
|
|
|
|
|
displayField: 'DeptName'
|
|
|
|
|
//,hidden: true
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
this.storeCodeDisportM = Ext.create('DsExt.ux.RefTableStore', {
|
|
|
|
|
model: 'DsShipping.ux.CodeDisportModel',
|
|
|
|
|
proxy: { url: '/CommMng/BasicDataRef/GetCodeDisportListRm' }
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
this.comboxDESTINATIONm = Ext.create('DsExt.ux.RefTableCombox', {
|
|
|
|
|
fieldLabel: Zi.LAN.DESTINATION, //'卸货港',
|
|
|
|
|
store: this.storeCodeDisportM,
|
|
|
|
|
name: 'DESTINATION',
|
|
|
|
|
valueField: 'PORT',
|
|
|
|
|
queryMode: 'remote',
|
|
|
|
|
minChars: 1,
|
|
|
|
|
queryParam: 'PORT',
|
|
|
|
|
displayField: 'PORT',
|
|
|
|
|
listeners: {
|
|
|
|
|
scope: this,
|
|
|
|
|
'select': function (combo, records, eOpts) {
|
|
|
|
|
if (records.length > 0) {
|
|
|
|
|
var selectrecords = DsStoreQueryBy(this.storeCodeDisportM, 'PORT', combo.value);
|
|
|
|
|
if (selectrecords.getCount() > 0) {
|
|
|
|
|
var selectdata = selectrecords.getAt(0).data;
|
|
|
|
|
this.formModify.getForm().findField('DESTINATIONID').setValue(selectdata.EDICODE);
|
|
|
|
|
|
|
|
|
|
} else {
|
|
|
|
|
this.formModify.getForm().findField('DESTINATIONID').setValue('');
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
});
|
|
|
|
|
this.storeCodeDisport3 = Ext.create('DsExt.ux.RefTableStore', {
|
|
|
|
|
model: 'DsShipping.ux.CodeDisportModel',
|
|
|
|
|
proxy: { url: '/CommMng/BasicDataRef/GetCodeDisportListRm' }
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
this.comboxPLACEDELIVERY = Ext.create('DsExt.ux.RefTableCombox', {
|
|
|
|
|
fieldLabel: Zi.LAN.PLACEDELIVERY, //'卸货港',
|
|
|
|
|
store: this.storeCodeDisport3,
|
|
|
|
|
name: 'PLACEDELIVERY',
|
|
|
|
|
valueField: 'PORT',
|
|
|
|
|
queryMode: 'remote',
|
|
|
|
|
minChars: 1,
|
|
|
|
|
queryParam: 'PORT',
|
|
|
|
|
displayField: 'PORT',
|
|
|
|
|
listeners: {
|
|
|
|
|
scope: this,
|
|
|
|
|
'select': function (combo, records, eOpts) {
|
|
|
|
|
if (records.length > 0) {
|
|
|
|
|
var selectrecords = DsStoreQueryBy(this.storeCodeDisport3, 'PORT', combo.value);
|
|
|
|
|
if (selectrecords.getCount() > 0) {
|
|
|
|
|
var selectdata = selectrecords.getAt(0).data;
|
|
|
|
|
this.formModify.getForm().findField('PLACEDELIVERYID').setValue(selectdata.EDICODE);
|
|
|
|
|
|
|
|
|
|
} else {
|
|
|
|
|
this.formModify.getForm().findField('PLACEDELIVERYID').setValue('');
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
this.storeSourceDetail = Ext.create('DsExt.ux.RefTableStore', {
|
|
|
|
|
model: 'DsShipping.ux.SourceDetailModel',
|
|
|
|
|
proxy: { url: '/CommMng/BasicDataRef/GetSourceDetail2' }
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
this.storeSourceDetail.load();
|
|
|
|
|
this.comboxBSSOURCEDETAIL = Ext.create('DsExt.ux.RefTableCombox', {
|
|
|
|
|
fieldLabel: Zi.LAN.BSSOURCEDETAIL, //'来源明细',
|
|
|
|
|
store: this.storeSourceDetail,
|
|
|
|
|
// forceSelection: true,
|
|
|
|
|
name: 'BSSOURCEDETAIL',
|
|
|
|
|
valueField: 'SourceDetail',
|
|
|
|
|
displayField: 'SourceDetail'
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
this.formModify = Ext.widget('form', {
|
|
|
|
|
region: 'north',
|
|
|
|
|
frame: true,
|
|
|
|
|
bodyPadding: 5,
|
|
|
|
|
fieldDefaults: {
|
|
|
|
|
margins: '2 2 2 2',
|
|
|
|
|
labelAlign: 'right',
|
|
|
|
|
flex: 1,
|
|
|
|
|
labelWidth: 60,
|
|
|
|
|
msgTarget: 'qtip'
|
|
|
|
|
},
|
|
|
|
|
|
|
|
|
|
items: [
|
|
|
|
|
{//fieldset 1
|
|
|
|
|
xtype: 'fieldset',
|
|
|
|
|
defaultType: 'textfield',
|
|
|
|
|
layout: 'anchor',
|
|
|
|
|
defaults: {
|
|
|
|
|
anchor: '100%'
|
|
|
|
|
},
|
|
|
|
|
items: [{
|
|
|
|
|
xtype: 'container',
|
|
|
|
|
layout: 'hbox',
|
|
|
|
|
defaultType: 'textfield',
|
|
|
|
|
items: [this.comboxYARD2, this.comboxCARRIER2, this.comboxFORWARDER2, this.comboxLANE2
|
|
|
|
|
]
|
|
|
|
|
}, {
|
|
|
|
|
xtype: 'container',
|
|
|
|
|
layout: 'hbox',
|
|
|
|
|
defaultType: 'textfield',
|
|
|
|
|
items: [{
|
|
|
|
|
fieldLabel: Zi.LAN.HBLNO, //'航次',
|
|
|
|
|
flex: 1,
|
|
|
|
|
name: 'HBLNO'
|
|
|
|
|
}, this.comboxSALE, this.comboxCUSTOMSER2, this.comboxTRUCKER2
|
|
|
|
|
]
|
|
|
|
|
}, {
|
|
|
|
|
xtype: 'container',
|
|
|
|
|
layout: 'hbox',
|
|
|
|
|
defaultType: 'textfield',
|
|
|
|
|
items: [this.comboxPORTLOAD2, {
|
|
|
|
|
fieldLabel: Zi.LAN.PORTLOADID, //'装港代码',
|
|
|
|
|
name: 'PORTLOADID'
|
|
|
|
|
}, this.comboxPORTDISCHARGE2, {
|
|
|
|
|
fieldLabel: Zi.LAN.PORTDISCHARGEID, //'卸港代码',
|
|
|
|
|
name: 'PORTDISCHARGEID'
|
|
|
|
|
}
|
|
|
|
|
]
|
|
|
|
|
}, {
|
|
|
|
|
xtype: 'container',
|
|
|
|
|
layout: 'hbox',
|
|
|
|
|
defaultType: 'textfield',
|
|
|
|
|
items: [this.comboxVoyVeg2, {
|
|
|
|
|
fieldLabel: Zi.LAN.VOYNO, //'航次',
|
|
|
|
|
flex: 1,
|
|
|
|
|
name: 'VOYNO'
|
|
|
|
|
}, {
|
|
|
|
|
fieldLabel: Zi.LAN.VESSELID, //'船舶呼号',
|
|
|
|
|
flex: 0.5,
|
|
|
|
|
name: 'VESSELID'
|
|
|
|
|
}, {
|
|
|
|
|
fieldLabel: Zi.LAN.ETD2, //'开船日期',
|
|
|
|
|
format: 'Y-m-d',
|
|
|
|
|
flex: 1,
|
|
|
|
|
xtype: 'datefield',
|
|
|
|
|
name: 'ETD'
|
|
|
|
|
}]
|
|
|
|
|
}, {
|
|
|
|
|
xtype: 'container',
|
|
|
|
|
layout: 'hbox',
|
|
|
|
|
defaultType: 'textfield',
|
|
|
|
|
items: [this.comboxAgent2, this.comboxBLTYPE, this.comboxDOC2, {
|
|
|
|
|
fieldLabel: Zi.LAN.CLOSINGDATE, //'截港日期',
|
|
|
|
|
format: 'Y-m-d',
|
|
|
|
|
flex: 1,
|
|
|
|
|
xtype: 'datetimefield',
|
|
|
|
|
name: 'CLOSINGDATE',
|
|
|
|
|
listeners: {
|
|
|
|
|
scope: this,
|
|
|
|
|
'select': function (combo, mdate) {
|
|
|
|
|
var mydate = new Date(mdate);
|
|
|
|
|
var mydatestr = Ext.util.Format.date(mydate, 'Y-m-d 12:00:00');
|
|
|
|
|
combo.setValue(mydatestr);
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
]
|
|
|
|
|
}, {
|
|
|
|
|
xtype: 'container',
|
|
|
|
|
layout: 'hbox',
|
|
|
|
|
defaultType: 'textfield',
|
|
|
|
|
items: [{
|
|
|
|
|
fieldLabel: Zi.LAN.CONTRACTNO, //'航次',
|
|
|
|
|
flex: 1,
|
|
|
|
|
labelWidth: 70,
|
|
|
|
|
name: 'CONTRACTNO'
|
|
|
|
|
}, {
|
|
|
|
|
fieldLabel: Zi.LAN.SERVICECONTRACTNO, //'航次',
|
|
|
|
|
flex: 1,
|
|
|
|
|
labelWidth: 70,
|
|
|
|
|
name: 'SERVICECONTRACTNO'
|
|
|
|
|
}, this.comboxCUSTSERVICE2, {
|
|
|
|
|
fieldLabel: Zi.LAN.CLOSEDOCDATE, //'截港日期',
|
|
|
|
|
format: 'Y-m-d',
|
|
|
|
|
flex: 1,
|
|
|
|
|
xtype: 'datetimefield',
|
|
|
|
|
name: 'CLOSEDOCDATE',
|
|
|
|
|
listeners: {
|
|
|
|
|
scope: this,
|
|
|
|
|
'select': function (combo, mdate) {
|
|
|
|
|
var mydate = new Date(mdate);
|
|
|
|
|
var mydatestr = Ext.util.Format.date(mydate, 'Y-m-d 12:00:00');
|
|
|
|
|
combo.setValue(mydatestr);
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
]
|
|
|
|
|
}, {
|
|
|
|
|
xtype: 'container',
|
|
|
|
|
layout: 'hbox',
|
|
|
|
|
defaultType: 'textfield',
|
|
|
|
|
items: [this.comboxBSSOURCE, this.comboxSHIPAGENCY, this.comboxFRCUSTSERVICE2, this.comboxOP3
|
|
|
|
|
|
|
|
|
|
]
|
|
|
|
|
}, {
|
|
|
|
|
xtype: 'container',
|
|
|
|
|
layout: 'hbox',
|
|
|
|
|
defaultType: 'textfield',
|
|
|
|
|
items: [this.comboxDESTINATIONm, {
|
|
|
|
|
fieldLabel: Zi.LAN.DESTINATIONID, //'卸港代码',
|
|
|
|
|
name: 'DESTINATIONID'
|
|
|
|
|
}, {
|
|
|
|
|
fieldLabel: Zi.LAN.ATD, //'开船日期',
|
|
|
|
|
format: 'Y-m-d',
|
|
|
|
|
flex: 1,
|
|
|
|
|
xtype: 'datefield',
|
|
|
|
|
name: 'ATD'
|
|
|
|
|
}, {
|
|
|
|
|
fieldLabel: Zi.LAN.HSCODE, //'船舶呼号',
|
|
|
|
|
name: 'HSCODE'
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
]
|
|
|
|
|
}, {
|
|
|
|
|
xtype: 'container',
|
|
|
|
|
layout: 'hbox',
|
|
|
|
|
defaultType: 'textfield',
|
|
|
|
|
items: [this.comboxPLACEDELIVERY, {
|
|
|
|
|
fieldLabel: Zi.LAN.PLACEDELIVERYID, //'卸港代码',
|
|
|
|
|
labelWidth: 80,
|
|
|
|
|
name: 'PLACEDELIVERYID'
|
|
|
|
|
}, this.comboxBSSOURCEDETAIL, { xtype: 'hiddenfield' }
|
|
|
|
|
|
|
|
|
|
]
|
|
|
|
|
}, {
|
|
|
|
|
xtype: 'container',
|
|
|
|
|
layout: 'hbox',
|
|
|
|
|
defaultType: 'textfield',
|
|
|
|
|
items: [{
|
|
|
|
|
xtype: 'textareafield',
|
|
|
|
|
grow: true,
|
|
|
|
|
flex: 1,
|
|
|
|
|
fieldLabel: Zi.LAN.AGENT, //'AGENT',
|
|
|
|
|
height: 60,
|
|
|
|
|
name: 'AGENT',
|
|
|
|
|
anchor: '100%'
|
|
|
|
|
}, {//fieldset 1
|
|
|
|
|
xtype: 'fieldset',
|
|
|
|
|
defaultType: 'textfield',
|
|
|
|
|
flex: 1.5,
|
|
|
|
|
layout: 'anchor',
|
|
|
|
|
defaults: {
|
|
|
|
|
anchor: '100%'
|
|
|
|
|
},
|
|
|
|
|
items: [{
|
|
|
|
|
xtype: 'container',
|
|
|
|
|
layout: 'hbox',
|
|
|
|
|
defaultType: 'textfield',
|
|
|
|
|
items: [this.comboxCustCodeM, {
|
|
|
|
|
fieldLabel: Zi.LAN.ORDERNO, //'订舱编号',
|
|
|
|
|
name: 'ORDERNO'
|
|
|
|
|
}
|
|
|
|
|
]
|
|
|
|
|
}, {
|
|
|
|
|
xtype: 'container',
|
|
|
|
|
layout: 'hbox',
|
|
|
|
|
defaultType: 'textfield',
|
|
|
|
|
items: [{
|
|
|
|
|
fieldLabel: Zi.LAN.ACCDATE, //'会计期间',
|
|
|
|
|
xtype: 'monthfield',
|
|
|
|
|
name: 'ACCDATE'
|
|
|
|
|
}, this.comboxDept
|
|
|
|
|
]
|
|
|
|
|
}]
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
]
|
|
|
|
|
}
|
|
|
|
|
]//end items(fieldset 1)
|
|
|
|
|
}//end fieldset 1
|
|
|
|
|
]//end root items
|
|
|
|
|
}); //end this.formEdit
|
|
|
|
|
me = this;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
this.winModifyShow = Ext.create('Ext.window.Window', {
|
|
|
|
|
title: Zi.LAN.PiLianXiuGai, //"批量修改",
|
|
|
|
|
width: 820,
|
|
|
|
|
//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.formModify],
|
|
|
|
|
buttons: [{
|
|
|
|
|
text: Zi.LAN.QueRenXiuGai, //"确认修改",
|
|
|
|
|
minWidth: 70,
|
|
|
|
|
handler: function () {
|
|
|
|
|
|
|
|
|
|
me.onModifyClick()
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
}, {
|
|
|
|
|
text: Zi.LAN.btnreset, //"确认修改",
|
|
|
|
|
minWidth: 70,
|
|
|
|
|
iconCls: "btnreset",
|
|
|
|
|
handler: function () {
|
|
|
|
|
var form = me.formModify.getForm();
|
|
|
|
|
form.reset();
|
|
|
|
|
}
|
|
|
|
|
}, {
|
|
|
|
|
text: Zi.LAN.GuanBi, //"关闭",
|
|
|
|
|
minWidth: 70,
|
|
|
|
|
handler: function () {
|
|
|
|
|
me.winModifyShow.close();
|
|
|
|
|
}
|
|
|
|
|
}]
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
//签单方式
|
|
|
|
|
this.storeISSUETYPE = Ext.create('DsExt.ux.RefTableStore', {
|
|
|
|
|
model: 'CODE_BLTYPE',
|
|
|
|
|
proxy: { url: '/CommMng/BasicDataRef/GetCodeBLTYPEList' }
|
|
|
|
|
});
|
|
|
|
|
this.storeISSUETYPE.load({ params: { condition: "" } });
|
|
|
|
|
|
|
|
|
|
this.comboxISSUETYPE = Ext.create('DsExt.ux.RefTableCombox', {
|
|
|
|
|
fieldLabel: Zi.LAN.ISSUETYPE, //'签单方式',
|
|
|
|
|
store: this.storeISSUETYPE,
|
|
|
|
|
forceSelection: true,
|
|
|
|
|
name: 'ISSUETYPE',
|
|
|
|
|
valueField: 'BLTYPE',
|
|
|
|
|
displayField: 'BLTYPE'
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
this.formModifyIssue = Ext.widget('form', {
|
|
|
|
|
region: 'north',
|
|
|
|
|
frame: true,
|
|
|
|
|
bodyPadding: 5,
|
|
|
|
|
fieldDefaults: {
|
|
|
|
|
margins: '2 2 2 2',
|
|
|
|
|
labelAlign: 'right',
|
|
|
|
|
flex: 1,
|
|
|
|
|
labelWidth: 60,
|
|
|
|
|
msgTarget: 'qtip'
|
|
|
|
|
},
|
|
|
|
|
|
|
|
|
|
items: [
|
|
|
|
|
{//fieldset 1
|
|
|
|
|
xtype: 'fieldset',
|
|
|
|
|
defaultType: 'textfield',
|
|
|
|
|
layout: 'anchor',
|
|
|
|
|
defaults: {
|
|
|
|
|
anchor: '100%'
|
|
|
|
|
},
|
|
|
|
|
items: [{
|
|
|
|
|
xtype: 'container',
|
|
|
|
|
layout: 'hbox',
|
|
|
|
|
defaultType: 'textfield',
|
|
|
|
|
items: [this.comboxISSUETYPE
|
|
|
|
|
]
|
|
|
|
|
}
|
|
|
|
|
]//end items(fieldset 1)
|
|
|
|
|
}//end fieldset 1
|
|
|
|
|
]//end root items
|
|
|
|
|
}); //end this.formEdit
|
|
|
|
|
me = this;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
this.winModifyIssueShow = Ext.create('Ext.window.Window', {
|
|
|
|
|
title: Zi.LAN.winModifyIssueShow, //"批量修改",
|
|
|
|
|
width: 220,
|
|
|
|
|
//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.formModifyIssue],
|
|
|
|
|
buttons: [{
|
|
|
|
|
text: Zi.LAN.QueRenXiuGai, //"确认修改",
|
|
|
|
|
minWidth: 70,
|
|
|
|
|
handler: function () {
|
|
|
|
|
|
|
|
|
|
me.onModifyIssueClick()
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
}, {
|
|
|
|
|
text: Zi.LAN.GuanBi, //"关闭",
|
|
|
|
|
minWidth: 70,
|
|
|
|
|
handler: function () {
|
|
|
|
|
me.winModifyIssueShow.close();
|
|
|
|
|
}
|
|
|
|
|
}]
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
//#endregion
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
//#region Cargo Smart 中远(客户乾景)
|
|
|
|
|
this.CheckBillCargoSmartEDI = new Ext.form.Checkbox({
|
|
|
|
|
fieldLabel: Zi.LAN.isHuoDaiTiDan, //'货代提单',
|
|
|
|
|
checked: false
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
this.formCargoSmartEDIShow = Ext.widget('form', {
|
|
|
|
|
frame: true,
|
|
|
|
|
region: 'center',
|
|
|
|
|
bodyPadding: 5,
|
|
|
|
|
fieldDefaults: {
|
|
|
|
|
margins: '2 2 2 2',
|
|
|
|
|
labelAlign: 'right',
|
|
|
|
|
flex: 1,
|
|
|
|
|
labelWidth: 90,
|
|
|
|
|
msgTarget: 'qtip'
|
|
|
|
|
},
|
|
|
|
|
items: [{
|
|
|
|
|
xtype: 'container',
|
|
|
|
|
defaultType: 'textfield',
|
|
|
|
|
layout: 'anchor',
|
|
|
|
|
defaults: { anchor: '100%' },
|
|
|
|
|
items: [{
|
|
|
|
|
xtype: 'container',
|
|
|
|
|
layout: 'hbox',
|
|
|
|
|
defaultType: 'textfield',
|
|
|
|
|
items: [{
|
|
|
|
|
xtype: 'radiogroup',
|
|
|
|
|
fieldLabel: Zi.LAN.rFILETYPE, //'报文类型',
|
|
|
|
|
id: 'CargoSmartFILETYPE',
|
|
|
|
|
defaults: { flex: 1 },
|
|
|
|
|
layout: 'hbox',
|
|
|
|
|
items: [{
|
|
|
|
|
boxLabel: Zi.LAN.FILETYPE_B, //'订舱',
|
|
|
|
|
name: 'FILETYPE',
|
|
|
|
|
checked: true,
|
|
|
|
|
inputValue: 'B'
|
|
|
|
|
}
|
|
|
|
|
, {
|
|
|
|
|
boxLabel: Zi.LAN.FILETYPE_E, //'确认',
|
|
|
|
|
name: 'FILETYPE',
|
|
|
|
|
inputValue: 'E'
|
|
|
|
|
}
|
|
|
|
|
]
|
|
|
|
|
}]
|
|
|
|
|
}, {
|
|
|
|
|
xtype: 'container',
|
|
|
|
|
layout: 'hbox',
|
|
|
|
|
defaultType: 'textfield',
|
|
|
|
|
items: [this.CheckBillCargoSmartEDI, {
|
|
|
|
|
fieldLabel: '销售代码', //'发票号',
|
|
|
|
|
id: 'CargoSmartSALEID',
|
|
|
|
|
name: 'SALEID'
|
|
|
|
|
}]
|
|
|
|
|
}, {
|
|
|
|
|
xtype: 'container',
|
|
|
|
|
layout: 'hbox',
|
|
|
|
|
defaultType: 'textfield',
|
|
|
|
|
items: [{
|
|
|
|
|
xtype: 'radiogroup',
|
|
|
|
|
fieldLabel: Zi.LAN.rFILEROLE, //'文件功能',
|
|
|
|
|
id: 'CargoSmartFILEROLE',
|
|
|
|
|
defaults: { flex: 1 },
|
|
|
|
|
layout: 'hbox',
|
|
|
|
|
items: [{
|
|
|
|
|
boxLabel: Zi.LAN.FILEROLE_YS, //'原始',
|
|
|
|
|
name: 'FILEROLE',
|
|
|
|
|
inputValue: 'NEW',
|
|
|
|
|
checked: true
|
|
|
|
|
}, {
|
|
|
|
|
boxLabel: Zi.LAN.FILEROLE_GX, //'更新',
|
|
|
|
|
name: 'FILEROLE',
|
|
|
|
|
inputValue: 'UPD'
|
|
|
|
|
}, {
|
|
|
|
|
boxLabel: Zi.LAN.FILEROLE_SC, //'删除',
|
|
|
|
|
name: 'FILEROLE',
|
|
|
|
|
inputValue: 'CAN'
|
|
|
|
|
}]
|
|
|
|
|
}]
|
|
|
|
|
}
|
|
|
|
|
, {
|
|
|
|
|
xtype: 'container',
|
|
|
|
|
layout: 'hbox',
|
|
|
|
|
defaultType: 'textfield',
|
|
|
|
|
items: [{
|
|
|
|
|
xtype: 'radiogroup',
|
|
|
|
|
fieldLabel: Zi.LAN.CARRIER, //'船公司',
|
|
|
|
|
columns: 2,
|
|
|
|
|
vertical: true,
|
|
|
|
|
id: 'CargoSmartCARRIER',
|
|
|
|
|
items: [{
|
|
|
|
|
boxLabel: Zi.LAN.CARRIER_COSU, //'中远COSCO',
|
|
|
|
|
name: 'CARRIER',
|
|
|
|
|
inputValue: 'COSU',
|
|
|
|
|
checked: true
|
|
|
|
|
}]
|
|
|
|
|
}]
|
|
|
|
|
}
|
|
|
|
|
]//end items(fieldset 1)
|
|
|
|
|
}]//end root items
|
|
|
|
|
});
|
|
|
|
|
mefen = this;
|
|
|
|
|
this.winCargoSmartEDIShow = Ext.create('Ext.window.Window', {
|
|
|
|
|
title: Zi.LAN.winCargoSmartEDIShow, //"生成Cargo Smart报文",
|
|
|
|
|
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.formCargoSmartEDIShow],
|
|
|
|
|
buttons: [{
|
|
|
|
|
text: Zi.LAN.ShangChuanEdi, //"上传EDI",
|
|
|
|
|
minWidth: 70,
|
|
|
|
|
handler: function () {
|
|
|
|
|
var cgFILETYPE = Ext.getCmp('CargoSmartFILETYPE');
|
|
|
|
|
var FILETYPE = cgFILETYPE.getValue();
|
|
|
|
|
var cgFILEROLE = Ext.getCmp('CargoSmartFILEROLE');
|
|
|
|
|
var FILEROLE = cgFILEROLE.getValue();
|
|
|
|
|
var CARRIER = Ext.getCmp('CargoSmartCARRIER').getValue();
|
|
|
|
|
var SALEID = Ext.getCmp('CargoSmartSALEID').getValue();
|
|
|
|
|
var IsBill = 0;
|
|
|
|
|
if (mefen.CheckBillCargoSmartEDI.checked)
|
|
|
|
|
IsBill = 1;
|
|
|
|
|
mefen.onSendCargoSmartEDI(FILETYPE.FILETYPE, FILEROLE.FILEROLE, IsBill, CARRIER.CARRIER, SALEID);
|
|
|
|
|
saveQuerySetting(mefen.formname + 'CargoSmartEDI', mefen.formCargoSmartEDIShow, false, true);
|
|
|
|
|
}
|
|
|
|
|
}, {
|
|
|
|
|
text: Zi.LAN.BaoCunEdiWenJian, //"保存EDI文件",
|
|
|
|
|
minWidth: 70,
|
|
|
|
|
handler: function () {
|
|
|
|
|
var cgFILETYPE = Ext.getCmp('CargoSmartFILETYPE');
|
|
|
|
|
var FILETYPE = cgFILETYPE.getValue();
|
|
|
|
|
var cgFILEROLE = Ext.getCmp('CargoSmartFILEROLE');
|
|
|
|
|
var FILEROLE = cgFILEROLE.getValue();
|
|
|
|
|
var CARRIER = Ext.getCmp('CargoSmartCARRIER').getValue();
|
|
|
|
|
var SALEID = Ext.getCmp('CargoSmartSALEID').getValue();
|
|
|
|
|
var IsBill = 0;
|
|
|
|
|
if (mefen.CheckBillCargoSmartEDI.checked)
|
|
|
|
|
IsBill = 1;
|
|
|
|
|
mefen.onSaveCargoSmartEDI(FILETYPE.FILETYPE, FILEROLE.FILEROLE, IsBill, CARRIER.CARRIER, SALEID);
|
|
|
|
|
saveQuerySetting(mefen.formname + 'CargoSmartEDI', mefen.formCargoSmartEDIShow, false, true);
|
|
|
|
|
}
|
|
|
|
|
}, {
|
|
|
|
|
text: Zi.LAN.GuanBi, //"关闭",
|
|
|
|
|
minWidth: 70,
|
|
|
|
|
handler: function () {
|
|
|
|
|
mefen.winCargoSmartEDIShow.close();
|
|
|
|
|
}
|
|
|
|
|
}]
|
|
|
|
|
});
|
|
|
|
|
//#endregion
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
}, //end initUIComponents
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
onRefreshClick: function (button, event) {
|
|
|
|
|
//var girdcolums = this.gridList.getColumnMode();
|
|
|
|
|
var sql = "BSNO<>'" + this.BsNo + "' and MASTERNO='" + this.BsNo + "'";
|
|
|
|
|
this.PageSize = this.Pagenum.getValue();
|
|
|
|
|
this.storeList.pageSize = this.PageSize;
|
|
|
|
|
this.storeList.currentPage = 1;
|
|
|
|
|
this.storeList.load({
|
|
|
|
|
params: { start: 0, limit: this.PageSize, sort: '', condition: sql },
|
|
|
|
|
waitMsg: "正在查询数据...",
|
|
|
|
|
scope: this
|
|
|
|
|
});
|
|
|
|
|
},
|
|
|
|
|
|
|
|
|
|
onDeleteClick: function (button, event) {
|
|
|
|
|
var selections = this.gridList.getSelectionModel().getSelection();
|
|
|
|
|
if (selections.length == 0) {
|
|
|
|
|
Ext.Msg.show({ title: '提示', msg: '请先选择业务!', icon: Ext.Msg.INFO, buttons: Ext.Msg.OK });
|
|
|
|
|
return;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
var record = selections[0];
|
|
|
|
|
if (record.data.BSSTATUS == 'true') {
|
|
|
|
|
Ext.Msg.show({ title: '警告', msg: '业务已锁定,不允许删除!', icon: Ext.Msg.WARNING, buttons: Ext.Msg.OK });
|
|
|
|
|
return;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
if (record.data.FEESTATUS == 'true') {
|
|
|
|
|
Ext.Msg.show({ title: '警告', msg: '费用已锁定,不允许删除!', icon: Ext.Msg.WARNING, buttons: Ext.Msg.OK });
|
|
|
|
|
return;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
if (this.StoreOpRange.getCount() == 0) {
|
|
|
|
|
Ext.Msg.show({ title: '警告', msg: '权限不足,不允许删除!', 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: '警告', msg: '权限不足,不允许删除!', icon: Ext.Msg.WARNING, buttons: Ext.Msg.OK });
|
|
|
|
|
return;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
Ext.MessageBox.confirm('提示', '确定删除该记录吗?', function (btn) {
|
|
|
|
|
if (btn == 'yes') {
|
|
|
|
|
Ext.Msg.wait('正在删除数据...');
|
|
|
|
|
Ext.Ajax.request({
|
|
|
|
|
waitMsg: '正在删除数据...',
|
|
|
|
|
url: '/MvcShipping/MsOpSeae/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: '提示', msg: jsonresult.Message, icon: Ext.Msg.INFO, buttons: Ext.Msg.OK });
|
|
|
|
|
}
|
|
|
|
|
else {
|
|
|
|
|
Ext.Msg.show({ title: '错误', msg: jsonresult.Message, icon: Ext.Msg.ERROR, buttons: Ext.Msg.OK });
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
},
|
|
|
|
|
failure: function (response, options) {
|
|
|
|
|
Ext.Msg.show({ title: '警告', msg: '服务器响应出错,请重试', icon: Ext.Msg.INFO, buttons: Ext.Msg.OK });
|
|
|
|
|
},
|
|
|
|
|
success: function (response, options) { },
|
|
|
|
|
scope: this
|
|
|
|
|
}); //end Ext.Ajax.request
|
|
|
|
|
}
|
|
|
|
|
}, this);
|
|
|
|
|
},
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
OprationSwap: function () {
|
|
|
|
|
var ret = new Array();
|
|
|
|
|
ret[0] = this.OprationStatus;
|
|
|
|
|
ret[1] = this.storeList;
|
|
|
|
|
ret[2] = this.SelectedRecord;
|
|
|
|
|
ret[3] = this.EditRecord;
|
|
|
|
|
ret[4] = this.mainWin;
|
|
|
|
|
return ret;
|
|
|
|
|
},
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
//#region 批量修改窗体
|
|
|
|
|
onModifyClick: function (menu, event) {
|
|
|
|
|
|
|
|
|
|
var GidStr = '';
|
|
|
|
|
var records = this.GridCheckBoxFenModel.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 bodyAddDatas = [];
|
|
|
|
|
for (var i = 0; i < records.length; i++) {
|
|
|
|
|
var rec = records[i];
|
|
|
|
|
if (rec.data.BSSTATUS == 'true') {
|
|
|
|
|
Ext.Msg.show({ title: Zi.LAN.JingGao, msg: Zi.LAN.YeWuYiSuoDingBuYunXuShanChu, icon: Ext.Msg.WARNING, buttons: Ext.Msg.OK });
|
|
|
|
|
} else {
|
|
|
|
|
var op = rec.data.OP;
|
|
|
|
|
var inputby = rec.data.INPUTBY;
|
|
|
|
|
|
|
|
|
|
//var rangeUser = [op, inputby, doc, orderop, custservice]
|
|
|
|
|
//canedit = DsStoreExistsList(_this.StoreOpRange, 'OPID', rangeUser)
|
|
|
|
|
|
|
|
|
|
var mrecords = DsStoreQueryBy(this.StoreOpRange, 'OPID', op);
|
|
|
|
|
|
|
|
|
|
if (mrecords.getCount() > 0) {
|
|
|
|
|
rec.data.SHIPPER = '';
|
|
|
|
|
rec.data.CONSIGNEE = '';
|
|
|
|
|
rec.data.NOTIFYPARTY = '';
|
|
|
|
|
rec.data.MARKS = '';
|
|
|
|
|
rec.data.DESCRIPTION = '';
|
|
|
|
|
bodyAddDatas.push(rec);
|
|
|
|
|
} else {
|
|
|
|
|
var recordins = DsStoreQueryBy(this.StoreOpRange, 'OPID', inputby);
|
|
|
|
|
if (recordins.getCount() > 0) {
|
|
|
|
|
rec.data.SHIPPER = '';
|
|
|
|
|
rec.data.CONSIGNEE = '';
|
|
|
|
|
rec.data.NOTIFYPARTY = '';
|
|
|
|
|
rec.data.MARKS = '';
|
|
|
|
|
rec.data.DESCRIPTION = '';
|
|
|
|
|
bodyAddDatas.push(rec);
|
|
|
|
|
} else {
|
|
|
|
|
canedit = false;
|
|
|
|
|
Ext.Msg.show({ title: Zi.LAN.JingGao, msg: Zi.LAN.QuanXianBuZuBuYunXuShanChu, icon: Ext.Msg.WARNING, buttons: Ext.Msg.OK });
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
var data = this.formModify.getForm().getValues();
|
|
|
|
|
|
|
|
|
|
_thisfenlist = this;
|
|
|
|
|
if (bodyAddDatas.length == 0) {
|
|
|
|
|
Ext.Msg.show({ title: Zi.LAN.TiShi, msg: Zi.LAN.MeiYouYaoXiuGaiDeYeWu, icon: Ext.Msg.INFO, buttons: Ext.Msg.OK });
|
|
|
|
|
return;
|
|
|
|
|
|
|
|
|
|
} else {
|
|
|
|
|
|
|
|
|
|
var jsonbodyAddDatas = ConvertRecordsToJsonAll(bodyAddDatas);
|
|
|
|
|
Ext.Ajax.request({
|
|
|
|
|
waitMsg: Zi.LAN.ZhengZaiCaoZuoShuJu,
|
|
|
|
|
url: '/MvcShipping/MsOpSeae/modify',
|
|
|
|
|
params: {
|
|
|
|
|
data: jsonbodyAddDatas,
|
|
|
|
|
modifydata: Ext.JSON.encode(data)
|
|
|
|
|
},
|
|
|
|
|
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 });
|
|
|
|
|
_thisfenlist.storeList.reload();
|
|
|
|
|
_thisfenlist.winModifyShow.close();
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
} else {
|
|
|
|
|
Ext.MessageBox.alert('请求出现错误,请重试', response.responseText);
|
|
|
|
|
}
|
|
|
|
|
},
|
|
|
|
|
scope: this
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
},
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
//#endregion
|
|
|
|
|
|
|
|
|
|
//#region 舱单 AFR
|
|
|
|
|
onCreateAfrClick: function (menu, event, type) {
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
var GidStr = '';
|
|
|
|
|
var selections = this.GridCheckBoxFenModel.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/MsOpSeae/CreateAfrList',
|
|
|
|
|
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
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
},
|
|
|
|
|
onCreateAfrZFClick: function (menu, event, type) {
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
var GidStr = '';
|
|
|
|
|
var selections = this.GridCheckBoxFenModel.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/MsOpSeaeEdi/AFREditSend',
|
|
|
|
|
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
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
},
|
|
|
|
|
|
|
|
|
|
onCreateAfrCSZFClick: function (menu, event, type) {
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
var GidStr = '';
|
|
|
|
|
var selections = this.GridCheckBoxFenModel.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 {
|
|
|
|
|
|
|
|
|
|
var formCargosmartAFRShow = 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.rFILEROLE, //'文件功能',
|
|
|
|
|
id: 'cmAFRFILEROLE',
|
|
|
|
|
defaults: {
|
|
|
|
|
flex: 1
|
|
|
|
|
},
|
|
|
|
|
layout: 'hbox',
|
|
|
|
|
items: [
|
|
|
|
|
{
|
|
|
|
|
boxLabel: Zi.LAN.FILEROLE_YS, //'原始',
|
|
|
|
|
name: 'FILEROLE',
|
|
|
|
|
inputValue: '9',
|
|
|
|
|
checked: true
|
|
|
|
|
//,id: 'radio3'
|
|
|
|
|
}, {
|
|
|
|
|
boxLabel: Zi.LAN.FILEROLE_GX, //'更新',
|
|
|
|
|
name: 'FILEROLE',
|
|
|
|
|
inputValue: '4'
|
|
|
|
|
//,id: 'radio6'
|
|
|
|
|
}
|
|
|
|
|
]
|
|
|
|
|
}
|
|
|
|
|
]
|
|
|
|
|
}
|
|
|
|
|
]//end items(fieldset 1)
|
|
|
|
|
}//end fieldset 1
|
|
|
|
|
]//end root items
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
var winCargosmartAFREDIShow = 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: [formCargosmartAFRShow],
|
|
|
|
|
buttons: [{
|
|
|
|
|
text: Zi.LAN.ShangChuanEdi, //"上传EDI",
|
|
|
|
|
minWidth: 70,
|
|
|
|
|
handler: function () {
|
|
|
|
|
var cmAFRFILEROLE = Ext.getCmp('cmAFRFILEROLE');
|
|
|
|
|
var FILEROLE = cmAFRFILEROLE.getValue();
|
|
|
|
|
Ext.Ajax.request({
|
|
|
|
|
waitMsg: Zi.LAN.ZhengZaiCaoZuoShuJu,
|
|
|
|
|
url: '/MvcShipping/MsOpSeaeEdi/AFREditSend',
|
|
|
|
|
params: {
|
|
|
|
|
BSNOS: BSNOStr,
|
|
|
|
|
type: type,
|
|
|
|
|
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('请求出现错误,请重试', response.responseText);
|
|
|
|
|
}
|
|
|
|
|
},
|
|
|
|
|
scope: this
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
}, {
|
|
|
|
|
text: Zi.LAN.BaoCunEdiWenJian, //"保存EDI文件",
|
|
|
|
|
minWidth: 70,
|
|
|
|
|
handler: function () {
|
|
|
|
|
var cmAFRFILEROLE = Ext.getCmp('cmAFRFILEROLE');
|
|
|
|
|
var FILEROLE = cmAFRFILEROLE.getValue();
|
|
|
|
|
Ext.Ajax.request({
|
|
|
|
|
waitMsg: Zi.LAN.ZhengZaiCaoZuoShuJu,
|
|
|
|
|
url: '/MvcShipping/MsOpSeaeEdi/AFREditSaveFile',
|
|
|
|
|
params: {
|
|
|
|
|
BSNOS: BSNOStr,
|
|
|
|
|
type: type,
|
|
|
|
|
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);
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
// downloadfile.doLayout();
|
|
|
|
|
// // var downloadfile = Ext.getCmp('downloadfile');
|
|
|
|
|
// var filehtml = '<a href="' + result.Data + '" style=' + '"text-decoration:none"' + '>' + result.Message + '</a>'
|
|
|
|
|
// downloadfile.html = filehtml;
|
|
|
|
|
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('请求出现错误,请重试', response.responseText);
|
|
|
|
|
}
|
|
|
|
|
},
|
|
|
|
|
scope: this
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
}, {
|
|
|
|
|
text: Zi.LAN.GuanBi, //"关闭",
|
|
|
|
|
minWidth: 70,
|
|
|
|
|
handler: function () {
|
|
|
|
|
winCargosmartAFREDIShow.close();
|
|
|
|
|
}
|
|
|
|
|
}]
|
|
|
|
|
});
|
|
|
|
|
winCargosmartAFREDIShow.show();
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
},
|
|
|
|
|
|
|
|
|
|
onCreateCustomClick: function (menu, event, type) {
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
var GidStr = '';
|
|
|
|
|
var selections = this.GridCheckBoxFenModel.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/MsOpSeae/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
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
},
|
|
|
|
|
//#endregion
|
|
|
|
|
|
|
|
|
|
//#region Cargo Smart 中远(客户乾景)
|
|
|
|
|
onCreateCargoSmartEDIClick: function (menu, event) {
|
|
|
|
|
this.winCargoSmartEDIShow.show();
|
|
|
|
|
},
|
|
|
|
|
|
|
|
|
|
onSendCargoSmartEDI: function (filetype, filerole, isbill, carrier, saleid) {
|
|
|
|
|
var GidStr = '';
|
|
|
|
|
var selections = this.GridCheckBoxFenModel.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.MeiYouYaoCaoZuoDeYeWu, 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/CreateCargoSmartEDIList',
|
|
|
|
|
params: {
|
|
|
|
|
bsnos: BSNOStr,
|
|
|
|
|
mblno: Mblno,
|
|
|
|
|
filetype: filetype,
|
|
|
|
|
filerole: filerole,
|
|
|
|
|
isbill: isbill,
|
|
|
|
|
carrier: carrier,
|
|
|
|
|
saleid: saleid
|
|
|
|
|
},
|
|
|
|
|
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
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
},
|
|
|
|
|
onSaveCargoSmartEDI: function (filetype, filerole, isbill, carrier, saleid) {
|
|
|
|
|
var GidStr = '';
|
|
|
|
|
var selections = this.GridCheckBoxFenModel.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.MeiYouYaoCaoZuoDeYeWu, icon: Ext.Msg.INFO, buttons: Ext.Msg.OK });
|
|
|
|
|
return;
|
|
|
|
|
} else {
|
|
|
|
|
Ext.Ajax.request({
|
|
|
|
|
waitMsg: Zi.LAN.Changing,
|
|
|
|
|
url: '/MvcShipping/MsOpSeae/SaveCargoSmartEDIList',
|
|
|
|
|
params: {
|
|
|
|
|
bsnos: BSNOStr,
|
|
|
|
|
mblno: Mblno,
|
|
|
|
|
filetype: filetype,
|
|
|
|
|
filerole: filerole,
|
|
|
|
|
isbill: isbill,
|
|
|
|
|
carrier: carrier,
|
|
|
|
|
saleid: saleid
|
|
|
|
|
},
|
|
|
|
|
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 打印
|
|
|
|
|
Print: function () {
|
|
|
|
|
|
|
|
|
|
_thisfenlist = this;
|
|
|
|
|
if (this.storeList.getCount() == 0) {
|
|
|
|
|
return;
|
|
|
|
|
}
|
|
|
|
|
var sql = "BSNO<>'" + this.BsNo + "' and MASTERNO='" + this.BsNo + "'";
|
|
|
|
|
var bsno = '11111';
|
|
|
|
|
var selections = this.gridList.getSelectionModel().getSelection();
|
|
|
|
|
if (selections.length != 0) {
|
|
|
|
|
var record = selections[0];
|
|
|
|
|
bsno = record.data.BSNO;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
var sortstr = 'ETD,MBLNO ';
|
|
|
|
|
|
|
|
|
|
if (this.sortfield != '' && this.sortdire != '') {
|
|
|
|
|
|
|
|
|
|
sortstr = this.sortfield + ' ' + this.sortdire;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
Ext.Msg.wait(Zi.LAN.ZhengZaiCaoZuoShuJu);
|
|
|
|
|
Ext.Ajax.request({
|
|
|
|
|
waitMsg: Zi.LAN.ZhengZaiCaoZuoShuJu,
|
|
|
|
|
url: '/MvcShipping/MsOpSeae/GetFenListStr',
|
|
|
|
|
scope: this,
|
|
|
|
|
params: {
|
|
|
|
|
condition: sql,
|
|
|
|
|
printstr: 'true',
|
|
|
|
|
sort: sortstr
|
|
|
|
|
},
|
|
|
|
|
callback: function (options, success, response) {
|
|
|
|
|
if (success) {
|
|
|
|
|
Ext.MessageBox.hide();
|
|
|
|
|
var jsonresult = Ext.JSON.decode(response.responseText);
|
|
|
|
|
if (jsonresult.Success) {
|
|
|
|
|
var returnstr = jsonresult.data;
|
|
|
|
|
var condition = sql;
|
|
|
|
|
if (condition != '') condition = ' where ' + condition;
|
|
|
|
|
|
|
|
|
|
var printType = 'MSOPSEAELIST';
|
|
|
|
|
var sql1 = returnstr;
|
|
|
|
|
var sql2 = "select * from op_seae where BSNO='" + bsno + "'";
|
|
|
|
|
var sql3 = "select CUSTOMERNAME,COUNT(BSNO) BLCOUNT,SUM(TEU) TEU from op_seae B " + condition + " group by CUSTOMERNAME";
|
|
|
|
|
var sql4 = "select CARRIER,COUNT(BSNO) BLCOUNT,SUM(TEU) TEU from op_seae B " + condition + " group by CARRIER";
|
|
|
|
|
var sql5 = "select OP,COUNT(BSNO) BLCOUNT,SUM(TEU) TEU from op_seae B " + condition + " group by OP";
|
|
|
|
|
var sql6 = "select COUNT(BSNO) BLCOUNT,SUM(TEU) TEU from op_seae B " + condition;
|
|
|
|
|
|
|
|
|
|
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.JingGao, msg: Zi.LAN.FuWuQiXiangYingChuCuo, icon: Ext.Msg.ERROR, buttons: Ext.Msg.OK });
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
});
|
|
|
|
|
},
|
|
|
|
|
|
|
|
|
|
PrintSelect: function () {
|
|
|
|
|
|
|
|
|
|
_thisfenlist = this;
|
|
|
|
|
if (this.storeList.getCount() == 0) {
|
|
|
|
|
return;
|
|
|
|
|
}
|
|
|
|
|
var selectedRecords = [];
|
|
|
|
|
var storeadd = null;
|
|
|
|
|
selectedRecords = this.GridCheckBoxFenModel.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 mblno = '';
|
|
|
|
|
var selections = this.gridList.getSelectionModel().getSelection();
|
|
|
|
|
if (selections.length != 0) {
|
|
|
|
|
var record = selections[0];
|
|
|
|
|
bsno = record.data.BSNO;
|
|
|
|
|
mblno = record.data.MBLNO;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
var printType = 'MSOPSEAELISTSELECT';
|
|
|
|
|
var sql1 = "select *,(SELECT TOP 1 STATUS FROM OP_STATUS WHERE BSNO=op_seae.BSNO ORDER BY COMPTIME DESC,INPUTTIME DESC) as OPSTATUS from op_seae WHERE BSNO IN (" + feeGidSql + ") order by " + sortstr;
|
|
|
|
|
var sql2 = "select *,(SELECT TOP 1 STATUS FROM OP_STATUS WHERE BSNO=op_seae.BSNO ORDER BY COMPTIME DESC,INPUTTIME DESC) as OPSTATUS from op_seae where BSNO='" + bsno + "'";
|
|
|
|
|
var sql3 = "";
|
|
|
|
|
var sql4 = "";
|
|
|
|
|
var sql5 = "";
|
|
|
|
|
var sql6 = "";
|
|
|
|
|
|
|
|
|
|
PrintComm(printType, sql1, sql2, sql3, sql4, sql5, sql6, mblno);
|
|
|
|
|
}
|
|
|
|
|
//#endregion
|
|
|
|
|
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
|