Ext.namespace('Shipping'); Shipping.MsOpAirnIndex = function (config) { Ext.applyIf(this, config); this.initUIComponents(); window.Shipping.MsOpAirnIndex.superclass.constructor.call(this); }; Ext.extend(Shipping.MsOpAirnIndex, Ext.Panel, { PageSize: 100, OprationStatus: null, //仅当弹出界面时使用 SelectedRecord: null, isShowAdvancedQuery: 0, //是否显示高级查询面板 sqlcontext: '', editype: '', selectbsno: '', sortfield: '', sortdire: '', initUIComponents: function () { this.formname = "formMsOpAirnIndex"; //页面名称 //定义数据集 this.storePLList = Ext.create('Ext.data.Store', { model: 'MsOpAirnModel' }); 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/GetDataList' } }); this.storeList = Ext.create('Ext.data.Store', { pageSize: this.PageSize, model: 'MsOpAirnModel', remoteSort: true, //groupField: 'CREATETIME', proxy: { type: 'ajax', url: '/MvcShipping/MsOpAirn/GetDataList', reader: { id: 'BSNO', root: 'data', totalProperty: 'totalCount' } } }); //#region List列表显示信息 this.Pagenum = Ext.create('Ext.form.field.Number', { name: 'bottles', fieldLabel: '每页记录数', labelAlign: 'right', value: this.PageSize, maxValue: 100000, width: 180, minValue: 0, listeners: { specialkey: function (field, e) { if (e.getKey() == e.ENTER) { _this.onRefreshClick(); } } } }); Ext.define('Ext.grid.column.Actiontextcolumn', { extend: 'Ext.grid.column.Column', alias: ['widget.actiontextcolumn'], defaultRenderer: function (value) { var me = this; prefix = Ext.baseCSSPrefix; scope = me.origScope || me; // if (value == "") { // } // else value = value + ''; // value = ''; return value; }, processEvent: function (type, view, cell, recordIndex, cellIndex, e, record, row) { var me = this; if (type == 'click') { me.handler.call(me.scope || me.origScope || me, view, recordIndex, cellIndex, e, record, row); } } }); Ext.grid.RowNumberer = Ext.extend(Ext.grid.RowNumberer, { width: 30 }); _this = this; this.initgirdcolums = [ { sortable: true, dataIndex: 'MBLNO', header: '主单号', width: 120 }, { sortable: true, dataIndex: 'HBLNO', header: '分单号', width: 120, summaryRenderer: function (value, cellmeta, record, rowIndex, columnIndex, store) { //value = usMoney(value, 2, '', true); return "合计"; } }, { sortable: true, hidden: true, dataIndex: 'BSNO', header: '业务编号', width: 0 }, { sortable: true, hidden: true, dataIndex: 'CUSTNO', header: '委托编号', width: 120 }, { sortable: true, hidden: true, dataIndex: 'ORDERNO', header: '订舱编号', width: 120 }, { sortable: true, hidden: true, dataIndex: 'ORDERTYPE', header: '订舱方式', width: 120 }, { sortable: true, dataIndex: 'BSSTATUSREF', header: '业务锁定', align: 'center', width: 60, renderer: function (value, cellmeta) { if (value == '锁定') { return ""; } } }, { sortable: true, dataIndex: 'FEESTATUSREF', header: '费用锁定', align: 'center', width: 60, renderer: function (value, cellmeta) { if (value == '锁定') { return ""; } } }, { sortable: true, dataIndex: 'DRFEESTATUS', header: '应收费用', 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'; } return value; } }, { sortable: true, dataIndex: 'CRFEESTATUS', header: '应付费用', 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'; } return value; } } , { sortable: true, dataIndex: 'OPSTATUS', header: '业务状态', width: 60 }, { sortable: true, dataIndex: 'BLTYPE', header: '装运方式', width: 60 }, { sortable: true, dataIndex: 'SHIPPER', header: '发货人', width: 80 }, { sortable: true, dataIndex: 'CONSIGNEE', header: '收货人', width: 80 }, { sortable: true, dataIndex: 'ETD', header: '开航日期', width: 80 }, { 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, summaryType: 'sum', align: 'right', summaryRenderer: Ext.util.Format.numberRenderer('0000'), renderer: Ext.util.Format.numberRenderer('0000') }, { sortable: true, dataIndex: 'M_WEIGHT', header: '实际重', width: 80, summaryType: 'sum', align: 'right', summaryRenderer: function (value, cellmeta, record, rowIndex, columnIndex, store) { value = usMoney(value, 2, '', true); return value; }, renderer: function (value, cellmeta, record, rowIndex, columnIndex, store) { value = usMoney(value, 2, '', true); return value; } }, { sortable: true, dataIndex: 'KGS', header: '计费重', width: 80, summaryType: 'sum', align: 'right', summaryRenderer: function (value, cellmeta, record, rowIndex, columnIndex, store) { value = usMoney(value, 2, '', true); return value; }, renderer: function (value, cellmeta, record, rowIndex, columnIndex, store) { value = usMoney(value, 2, '', true); return value; } }, { sortable: true, dataIndex: 'PRICE', header: '运价', width: 80, summaryType: 'sum', align: 'right', summaryRenderer: function (value, cellmeta, record, rowIndex, columnIndex, store) { value = usMoney(value, 2, '', true); return value; }, renderer: function (value, cellmeta, record, rowIndex, columnIndex, store) { value = usMoney(value, 2, '', true); return value; } }, { sortable: true, dataIndex: 'CBM', header: '体积', width: 80, summaryType: 'sum', align: 'right', summaryRenderer: function (value, cellmeta, record, rowIndex, columnIndex, store) { value = usMoney(value, 2, '', true); return value; }, renderer: function (value, cellmeta, record, rowIndex, columnIndex, store) { value = usMoney(value, 2, '', true); return value; } }, { 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: '创建日期', renderer: Ext.util.Format.dateRenderer('Y-m-d'), width: 120 }, { sortable: true, dataIndex: 'OP', header: '操作员', width: 80 }, { sortable: true, dataIndex: 'SALE', header: '揽货人', width: 80 }, { sortable: true, hidden: true, dataIndex: 'VESSEL', header: '航班', width: 100 }, { sortable: true, hidden: true, dataIndex: 'VESSELHEAD', header: '航司前缀', width: 100 }, { sortable: true, //hidden: true, dataIndex: 'VESSEL_REF', header: '航班号', width: 100 }, { 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, summaryType: 'sum', align: 'right', summaryRenderer: function (value, cellmeta, record, rowIndex, columnIndex, store) { value = usMoney(value, 2, '', true); return value; }, renderer: function (value, cellmeta, record, rowIndex, columnIndex, store) { value = usMoney(value, 2, '', true); return value; } }, { sortable: true, dataIndex: 'AIRLINES', header: '航空公司', width: 100 }, { sortable: true, dataIndex: 'TRUCKER', header: '承运车队', width: 100 }, { sortable: true, dataIndex: 'AGENTID', header: '代理', width: 100 }, { sortable: true, dataIndex: 'FORWARDER', header: '订舱代理', width: 100 }, { sortable: true, hidden: true, dataIndex: 'FEEKGS', header: '计费重量', width: 60, summaryType: 'sum', align: 'right', summaryRenderer: function (value, cellmeta, record, rowIndex, columnIndex, store) { value = usMoney(value, 0, '', true); return value; }, renderer: function (value, cellmeta, record, rowIndex, columnIndex, store) { value = usMoney(value, 0, '', true); return value; } }, { sortable: true, dataIndex: 'VOUNO', header: '凭证号', width: 60 }, { sortable: true, dataIndex: 'ISPRINTPR', header: '打印核算单', width: 100, renderer: function (value, meta, record) { if (value == '1') return '√'; else return ''; } }, { sortable: true, dataIndex: 'IsSERVICE1', header: '服务项目1', hidden: true, width: 100, renderer: function (value, meta, record) { if (value == true || value == '1') return '√'; else return ''; } }, { sortable: true, dataIndex: 'IsSERVICE2', header: '服务项目2', hidden: true, width: 100, renderer: function (value, meta, record) { if (value == true || value == '1') return '√'; else return ''; } }, { sortable: true, dataIndex: 'IsSERVICE3', header: '服务项目3', hidden: true, width: 100, renderer: function (value, meta, record) { if (value == true || value == '1') return '√'; else return ''; } }, { sortable: true, dataIndex: 'IsSERVICE4', header: '服务项目4', hidden: true, width: 100, renderer: function (value, meta, record) { if (value == true || value == '1') return '√'; else return ''; } }, { sortable: true, dataIndex: 'IsSERVICE5', header: '服务项目5', hidden: true, width: 100, renderer: function (value, meta, record) { if (value == true || value == '1') return '√'; else return ''; } }, { sortable: true, dataIndex: 'IsSERVICE6', header: '服务项目6', hidden: true, width: 100, renderer: function (value, meta, record) { if (value == true || value == '1') return '√'; else return ''; } }, { sortable: true, dataIndex: 'IsSERVICE7', header: '服务项目7', hidden: true, width: 100, renderer: function (value, meta, record) { if (value == true || value == '1') return '√'; else return ''; } }, { sortable: true, dataIndex: 'IsSERVICE8', header: '服务项目8', hidden: true, width: 100, renderer: function (value, meta, record) { if (value == true || value == '1') return '√'; else return ''; } }, { sortable: true, dataIndex: 'IsSERVICE9', header: '服务项目9', hidden: true, width: 100, renderer: function (value, meta, record) { if (value == true || value == '1') return '√'; else return ''; } }, { sortable: true, dataIndex: 'IsSERVICE10', header: '服务项目10', hidden: true, width: 100, renderer: function (value, meta, record) { if (value == true || value == '1') return '√'; else return ''; } }, { sortable: true, dataIndex: 'STREMARK', header: '结算注意事项', width: 200 }, { sortable: true, dataIndex: 'TRANSREMARK', header: '运输注意事项', width: 200 }, { sortable: true, dataIndex: 'ISSUEDATE', header: '填开日期', renderer: Ext.util.Format.dateRenderer('Y-m-d H:i:s'), width: 140 }, { sortable: true, dataIndex: 'ISVOID', header: '是否已作废', align: 'center', width: 100, renderer: function (value, meta) { if (value == '0') { return ""; } else if (value == '1') { meta.tdCls = 'feestatus_nopass'; return "已作废" } } }, { sortable: true, dataIndex: 'PTOTAL', header: '合计金额', align: 'center', width: 100, summaryType: 'sum', align: 'right', summaryRenderer: function (value, cellmeta, record, rowIndex, columnIndex, store) { value = usMoney(value, 2, '', true); return value; }, renderer: function (value, cellmeta, record, rowIndex, columnIndex, store) { value = usMoney(value, 2, '', true); return value; } }, { sortable: true, dataIndex: 'STLNAME', header: '结算方式', width: 80 }, { sortable: true, dataIndex: 'STLDATE', header: '结算日期', width: 120 }]; 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: "数据加载中,请稍等..." }, trackMouseOver: true, disableSelection: false, selModel: this.GridCheckBoxModel, columns: this.girdcolums, /* features: [{ id: 'group', ftype: 'groupingsummary', groupHeaderTpl: '{name}', hideGroupedHeader: false, enableGroupingMenu: true }],*/ features: [{ ftype: 'summary'//Ext.grid.feature.Summary表格汇总特性 }], bbar: [Ext.create('Ext.PagingToolbar', { id: "bbar_ALL", store: this.storeList, displayInfo: true, displayMsg: '当前显示 {0} - {1}条记录 /共 {2}条记录', emptyMsg: "没有数据" }), this.Pagenum] }); /////////////以下部分为获取存储的gridpanel显示样式 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'; if (BLTYPE == "国内分单") DsOpenEditWin('/MvcShipping/MsOpAirn/Edit', record.data.BSNO); if (BLTYPE == "国内主单") DsOpenEditWin('/MvcShipping/MsOpAirn_Main/Edit', record.data.BSNO); }, this); this.gridList.addListener('sortchange', function (ct, column, direction, eOpts) { this.sortfield = column.dataIndex; this.sortdire = direction; }, this); //#region formSearch 下拉框信息加载 //权限范围 this.StoreOpRange = Ext.create('DsExt.ux.RefTableStore', { model: 'MsOP', proxy: { url: '/MvcShipping/MsBaseInfo/GetOpRang' } }); this.StoreOpRange.load({ params: { optype: "modOpAirnList"} }); //客户加载_委托单位 this.storeCustCode = Ext.create('DsExt.ux.RefTableStore', { model: 'DsShipping.ux.CustomRefModel', proxy: { url: '/CommMng/BasicDataRef/GetCustomRefList' } }); this.storeCustCode.load({ params: { condition: "ISCONTROLLER='1'"} }); //委托单位 _this = this; this.comboxCustCode = Ext.create('DsExt.ux.RefTableCombox', { fieldLabel: '委托单位', store: this.storeCustCode, forceSelection: true, name: 'CUSTOMERNAME', valueField: 'CustName', displayField: 'CodeAndName', enableKeyEvents: true, listeners: { keyup: function (field, e) { if (e.getKey() == e.ENTER) { _this.onRefreshClick(); } } } }); this.storeCodeDisport2 = Ext.create('DsExt.ux.RefTableStore', { model: 'MsCodeAirPort', proxy: { url: '/MvcShipping/MsCodeAirPort/GetDataList' } }); this.storeCodeDisport2.load(); this.comboxPORTDISCHARGEID = Ext.create('DsExt.ux.RefTableCombox', { fieldLabel: '目的站', store: this.storeCodeDisport2, name: 'PORTDISCHARGEID', valueField: 'PORTID', displayField: 'CODEANDCNAME', listeners: { specialkey: function (field, e) { if (e.getKey() == e.ENTER) { _this.onRefreshClick(); } } } }); this.storeAIRLINES = Ext.create('DsExt.ux.RefTableStore', { model: 'DsShipping.ux.AirLinesModel', proxy: { url: '/CommMng/BasicDataRef/GetAirLinesList' } }); this.storeAIRLINES.load({ params: { condition: "ISAIRLINES='1'" }, scope: this }); //船公司 this.comboxAIRLINES = Ext.create('DsExt.ux.RefTableCombox', { fieldLabel: '航空公司', store: this.storeAIRLINES, forceSelection: true, name: 'AIRLINES', valueField: 'CustName', displayField: 'CodeAndName', listeners: { specialkey: function (field, e) { if (e.getKey() == e.ENTER) { _this.onRefreshClick(); } } } }); //#endregion //#region formSearch 查询面板 _this = this; 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: [{ xtype: 'button', width: 90, text: "执行查询", iconCls: "btnrefresh", handler: function (button, event) { this.onRefreshClick(button, event); }, scope: this }, { fieldLabel: '编号', name: 'MblNo', enableKeyEvents: true, listeners: { specialkey: function (field, e) { if (e.getKey() == e.ENTER) { _this.onRefreshClick(); } } } }, this.comboxCustCode, { fieldLabel: '收货人', name: 'CONSIGNEE', enableKeyEvents: true, listeners: { specialkey: function (field, e) { if (e.getKey() == e.ENTER) { _this.onRefreshClick(); } } } }, , this.comboxPORTDISCHARGEID , { fieldLabel: '航班日期', format: 'Y-m-d', xtype: 'datefield', name: 'ETDbgn', enableKeyEvents: true, listeners: { specialkey: function (field, e) { if (e.getKey() == e.ENTER) { _this.onRefreshClick(); } } } }, { fieldLabel: '到', format: 'Y-m-d', xtype: 'datefield', name: 'ETDend', enableKeyEvents: true, listeners: { specialkey: function (field, e) { if (e.getKey() == e.ENTER) { _this.onRefreshClick(); } } } }] } , { xtype: 'container', layout: 'hbox', defaultType: 'textfield', items: [{ xtype: 'button', width: 90, text: "高级查询", iconCls: "btnmore", handler: function (button, event) { var sql = this.getCondition(); var winAccess = new Shipping.DsQuery({ }); winAccess.StoreList = this.storeList; winAccess.formname = this.formname; winAccess.condition = sql; winAccess.show(); return; }, scope: this }, this.comboxAIRLINES , this.comboxPORTDISCHARGEID , { fieldLabel: '发货人', name: 'SHIPPER', enableKeyEvents: true, listeners: { specialkey: function (field, e) { if (e.getKey() == e.ENTER) { _this.onRefreshClick(); } } } } , { fieldLabel: '品名', name: 'GOODSNAME', enableKeyEvents: true, listeners: { specialkey: function (field, e) { if (e.getKey() == e.ENTER) { _this.onRefreshClick(); } } } }, { fieldLabel: '航班号', name: 'VESSEL_REF', enableKeyEvents: true, listeners: { specialkey: function (field, e) { if (e.getKey() == e.ENTER) { _this.onRefreshClick(); } } } } ] } ]//end items(fieldset 1) }]//end root items }); //#endregion formSearch _this = this; //按钮工具条_ this.panelBtn = new Ext.Panel({ region: "north", tbar: [{ text: "新建", iconCls: "btnadd", handler: function (button, event) { this.OprationStatus = 'add'; if (BLTYPE == "国内主单") DsOpenEditWin('/MvcShipping/MsOpAirn_Main/Edit'); if (BLTYPE == "国内分单") DsOpenEditWin('/MvcShipping/MsOpAirn/Edit'); }, scope: this }, { text: "复制新建", iconCls: "btnadd", handler: 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]; this.SelectedRecord = record; this.OprationStatus = 'copyadd'; if (BLTYPE == "国内主单") DsOpenEditWin('/MvcShipping/MsOpAirn_Main/Edit', record.data.BSNO); if (BLTYPE == "国内分单") DsOpenEditWin('/MvcShipping/MsOpAirn/Edit', record.data.BSNO); }, scope: this }, { text: "删除", iconCls: "btndelete", id: "btndelete", handler: function (button, event) { this.onDeleteClick(button, event); }, scope: this }, { text: "重置条件", iconCls: "btnreset", handler: function (button, event) { this.onClearSql(button, event); }, scope: this }, , '-', { text: "保存列表样式", id: "btntest", menu: [ { text: "保存", handler: function (button, event) { this.girdcolums = DsTruck.SaveGridPanel(USERID, _this.formname, _this.gridList.columns, _this.girdcolums, 1, true); } }, { text: "初始化", handler: function (menu, event) { _this.InitGrid(_this.initgirdcolums); _this.girdcolums = DsTruck.SaveGridPanel(USERID, _this.formname, _this.gridList.columns, _this.initgirdcolums, 1, true); } }], scope: this }, '-', { text: "打印", iconCls: 'btnprint', menu: [ { text: "全部", handler: function (menu, event) { _this.Print(); } }, { text: "选择打印", handler: function (menu, event) { _this.PrintSelect(); } }], scope: this }, '-', { text: "其他操作", menu: [ { text: "提单信息", handler: function (menu, event) { _this.onBillEditClick(menu, event); } }, { text: "生成分部订舱", handler: function (menu, event) { _this.onCreateSubOrderClick(menu, event, 1); } }, { text: "批量状态更新", handler: function (menu, event) { _this.onUpOpStatusClick(menu, event, 1); } }, { text: "费用编辑", handler: function (menu, event) { _this.onFeeEditClick(menu, event); } }, { text: "批量费用提交", handler: function (menu, event) { _this.onPiLiangSubmitClick(menu, event, 1); } }, { text: "业务批量修改", handler: function (menu, event) { _this.winModifyShow.show(); } }], scope: this }, { text: "作废主单", id: "btnISVOID", hidden: true, iconCls: "", handler: function (button, event) { //this.OprationStatus = 'add'; if (BLTYPE == "国内主单") { this.onVOIDClick(); } }, scope: this }, '-' , { text: "导出Excel", id: "btnExportExcel", iconCls: 'btnexportexcel', handler: function (button, event) { this.onExportClick(button, event); }, scope: this }] }); this.panelTop = new Ext.Panel({ layout: "border", region: "north", height: 100, items: [this.panelBtn, this.formSearch] }); Ext.apply(this, { items: [this.panelTop, this.gridList] }); this.InitGrid(this.girdcolums); this.storeList.on('beforeload', function (store) { // var sql = this.getCondition(); Ext.apply(store.proxy.extraParams, { condition: _this.sqlcontext,bltype:BLTYPE }); }, this); //#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 fieldset 1 ]//end root items }); me = this; this.winDownloadShow = Ext.create('Ext.window.Window', { title: "下载文件", 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: "关闭", minWidth: 70, handler: function () { me.winDownloadShow.close(); } }] }); //#endregion //#region 批量修改窗体 //客户加载_代理 // this.storeShipper.load({ params: { condition: "ISCONTROLLER='1'"} }); //收货人 this.comboxAgent2 = Ext.create('DsExt.ux.RefTableCombox', { fieldLabel: '代 理', 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.comboxPORTLOAD2 = Ext.create('DsExt.ux.RefTableCombox', { fieldLabel: '装货港', 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: '卸货港', store: this.storeCodeDisport, name: 'PORTDISCHARGE', valueField: 'PORT', queryMode: 'local', 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.formModify = Ext.widget('form', { region: 'north', frame: true, bodyPadding: 5, fieldDefaults: { margins: '2 2 2 2', labelAlign: 'right', flex: 1, labelWidth: 70, 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: [this.comboxAgent2, this.comboxCUSTOMSER2, this.comboxTRUCKER2, { xtype: 'hiddenfield' } ] }, { xtype: 'container', layout: 'hbox', defaultType: 'textfield', items: [this.comboxPORTLOAD2, { fieldLabel: '装港代码', name: 'PORTLOADID' } //, this.comboxPORTDISCHARGE2 , { fieldLabel: '卸港代码', name: 'PORTDISCHARGEID' } ] }, { xtype: 'container', layout: 'hbox', defaultType: 'textfield', items: [{ xtype: 'textareafield', grow: true, fieldLabel: 'AGENT', height: 70, name: 'AGENT', anchor: '100%' } ] } ]//end items(fieldset 1) }//end fieldset 1 ]//end root items }); //end this.formEdit me = this; this.winModifyShow = Ext.create('Ext.window.Window', { title: "批量修改", 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: "确认修改", minWidth: 70, handler: function () { me.onModifyClick() } }, { text: "关闭", minWidth: 70, handler: function () { me.winModifyShow.close(); } }] }); //#endregion //#region 打开时载入当天业务 var myDate = new Date(); var mydatestr = Ext.util.Format.date(myDate, 'Y-m-d'); this.sqlcontext = " BLTYPE='" + BLTYPE + "' and dbo.trimdate(B.BSDATE)='" + mydatestr + "' "; this.storeList.load({ params: { start: 0, limit: this.PageSize, sort: '', condition: _this.sqlcontext, load: 'true',bltype:BLTYPE }, waitMsg: "正在查询数据...", scope: this }); //#endregion //如果是国内主单则显示作废按钮 if (BLTYPE == "国内主单") { Ext.getCmp("btnISVOID").show(); } Ext.Ajax.request({ waitMsg: '正在添加数据...', url: '/MvcShipping/MsBaseInfo/GetUserModuleEnable', params: { modulename: 'modAirn_Del' }, callback: function (options, success, response) { if (success) { var result = Ext.JSON.decode(response.responseText); if (!result.Success) { Ext.getCmp("btndelete").disable(); } else { Ext.getCmp("btndelete").enable(); } } else { } }, scope: this }); }, //end initUIComponents InitGrid: function (grid) { //var agirdcolums = Ext.clone(this.gridList.columns); var agirdcolums = grid; this.storecodeservice.load({ params: { condition: "OPTYPE='3'" }, 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 == 'Is' + 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); }, 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,bltype:BLTYPE }, waitMsg: "正在查询数据...", scope: this }); }, onDsQuery: function () { //var girdcolums = this.gridList.getColumnMode(); var sql = this.sqlcontext; this.PageSize = this.Pagenum.getValue(); this.storeList.pageSize = this.PageSize; this.storeList.load({ params: { start: 0, limit: this.PageSize, sort: '', condition: sql,bltype:BLTYPE }, 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; if (op == "") { } else { 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/MsOpAirn/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); }, onVOIDClick: 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; } Ext.MessageBox.confirm('提示', '确定作废该记录吗?', function (btn) { if (btn == 'yes') { Ext.Msg.wait('正在删除数据...'); Ext.Ajax.request({ waitMsg: '正在删除数据...', url: '/MvcShipping/MsOpAirn/VoidMain', 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); }, onExportClick: function (button, event) { GridExportExcelPage(this.gridList); } , //#region 状态更新和批量修改 onUpOpStatusClick: function (menu, event, type) { var selections = this.GridCheckBoxModel.selected.items; if (selections.length == 0) { Ext.Msg.show({ title: '提示', msg: '请先选择要更新的业务!', 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: '提示', msg: '没有要更新的业务!', 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: '提示', msg: '请先选择要更新的业务!', 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: '提示', msg: '没有要更新的业务!', icon: Ext.Msg.INFO, buttons: Ext.Msg.OK }); return; } else { this.selectbsno = " BSNO 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'); } }, //#endregion //#region 拼箱操作 onFeeEditClick: function (menu, 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]; this.SelectedRecord = record; this.OprationStatus = 'edit'; DsOpenEditWin('/MvcShipping/MsOpAirn/PiLiangFeeEdit'); }, onBillEditClick: function (menu, 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]; this.SelectedRecord = record; this.OprationStatus = 'edit'; DsOpenEditWin('/MvcShipping/MsOpAirn/PiLiangOpBill'); }, onFenBillListClick: function (menu, 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.BLTYPE != '拼箱主票') { Ext.Msg.show({ title: '提示', msg: '只有拼箱主票才能拼箱预配!', icon: Ext.Msg.INFO, buttons: Ext.Msg.OK }); return; } this.SelectedRecord = record; this.OprationStatus = 'edit'; DsOpenEditWin('/MvcShipping/MsOpAirn/FenBillList'); }, //#endregion onImportEdiClick: function (button, event) { var winAccess = new Shipping.EDIImport({ }); winAccess.StoreList = this.storeList; winAccess.show(); return; }, onModifyClick: function (menu, event) { var GidStr = ''; var records = this.GridCheckBoxModel.selected.items; if (records.length == 0) { Ext.Msg.show({ title: '提示', msg: '请先选择要修改的业务!', 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: '警告', msg: '业务已锁定,不允许删除!', icon: Ext.Msg.WARNING, buttons: Ext.Msg.OK }); } else { var op = rec.data.OP; var inputby = rec.data.INPUTBY; var mrecords = DsStoreQueryBy(this.StoreOpRange, 'OPID', op); if (mrecords.getCount() > 0) { bodyAddDatas.push(rec); } else { var recordins = DsStoreQueryBy(this.StoreOpRange, 'OPID', inputby); if (recordins.getCount() > 0) { bodyAddDatas.push(rec); } else { canedit = false; Ext.Msg.show({ title: '警告', msg: '权限不足,不允许删除!', icon: Ext.Msg.WARNING, buttons: Ext.Msg.OK }); } } } } var data = this.formModify.getForm().getValues(); _this = this; if (bodyAddDatas.length == 0) { Ext.Msg.show({ title: '提示', msg: '没有要修改的业务!', icon: Ext.Msg.INFO, buttons: Ext.Msg.OK }); return; } else { var jsonbodyAddDatas = ConvertRecordsToJsonAll(bodyAddDatas); Ext.Ajax.request({ waitMsg: '正在锁定...', url: '/MvcShipping/MsOpAirn/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: '提示', msg: result.Message, icon: Ext.MessageBox.ERROR, buttons: Ext.Msg.OK }); return; } else { Ext.Msg.show({ title: '提示', msg: result.Message, icon: Ext.Msg.INFO, buttons: Ext.Msg.OK }); _this.onRefreshClick(); _this.winModifyShow.close(); } } else { Ext.MessageBox.alert('请求出现错误,请重试', response.responseText); } }, scope: this }); } }, 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 = " BLTYPE='" + BLTYPE + "' "; //#region formSearch 查询面板 //编号包括(主提单号) var MblNo = form.findField('MblNo').getValue(); sql = sql + getAndConSql(sql, MblNo, "(B.MblNo like '%" + MblNo + "%' or B.CONTRACTNO like '%" + MblNo + "%' or B.CUSTNO like '%" + MblNo + "%' or B.HBLNO like '%" + MblNo + "%' or B.ORDERNO like '%" + MblNo + "%')"); //客户名称 var CUSTOMERNAME = form.findField('CUSTOMERNAME').getValue(); sql = sql + getAndConSql(sql, CUSTOMERNAME, "B.CUSTOMERNAME='" + CUSTOMERNAME + "'"); //到港日期 var ETDbgn = form.findField('ETDbgn').getRawValue(); sql = sql + getAndConSql(sql, ETDbgn, "B.ETD >='" + ETDbgn + "'"); var ETDend = form.findField('ETDend').getRawValue(); sql = sql + getAndConSql(sql, ETDend, "B.ETD <='" + ETDend + "'"); var AIRLINES = form.findField('AIRLINES').getValue(); sql = sql + getAndConSql(sql, AIRLINES, "B.AIRLINES='" + AIRLINES + "'"); var GOODSNAME = form.findField('GOODSNAME').getValue(); //if (BLTYPE == "国内分单") { sql = sql + getAndConSql(sql, GOODSNAME, " exists (select 1 from OP_AIRN_CARGO where CARGONAME like '%" + GOODSNAME + "%' and bsno in (select bsno from op_airn where hblno=B.hblno)) "); //} //if (BLTYPE == "国内主单") { // sql = sql + getAndConSql(sql, GOODSNAME, " exists (select 1 from OP_AIRN_CARGO where CARGONAME like '%" + GOODSNAME + "%' and bsno=B.BSNO ) "); //} var PORTDISCHARGEID = form.findField('PORTDISCHARGEID').getValue(); sql = sql + getAndConSql(sql, PORTDISCHARGEID, "B.PORTDISCHARGEID = '" + PORTDISCHARGEID + "' "); var CONSIGNEE = form.findField('CONSIGNEE').getValue(); //if (BLTYPE == "国内分单") { sql = sql + getAndConSql(sql, CONSIGNEE, " B.CONSIGNEE like '%" + CONSIGNEE + "%' "); var SHIPPER = form.findField('SHIPPER').getValue(); //if (BLTYPE == "国内分单") { sql = sql + getAndConSql(sql, SHIPPER, " B.SHIPPER like '%" + SHIPPER + "%' "); var VESSEL_REF = form.findField('VESSEL_REF').getValue(); //if (BLTYPE == "国内分单") { sql = sql + getAndConSql(sql, VESSEL_REF, " B.VESSEL like '%" + VESSEL_REF + "%' "); //#endregion formSearch return sql; }, 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_AIRN'; ret[5] = this.storePLList; return ret; }, Print: function () { _this = this; if (this.storeList.getCount() == 0) { return; } var bsno = '11111'; var selections = this.gridList.getSelectionModel().getSelection(); if (selections.length != 0) { var record = selections[0]; bsno = record.data.BSNO; } let _printType = 'MsOpAirnLIST'; if (BLTYPE == "国内主单") { _printType = 'MsOpAirnLIST_Main'; } var sortstr = 'ETD,MBLNO '; if (this.sortfield != '' && this.sortdire != '') { sortstr = this.sortfield + ' ' + this.sortdire; } Ext.Msg.wait('正在组织数据, 请稍侯..'); Ext.Ajax.request({ waitMsg: '正在组织数据...', url: '/MvcShipping/MsOpAirn/GetDataListStr', scope: this, params: { condition: _this.sqlcontext, 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 printType = _printType; var sql1 = returnstr; var sql2 = "select * from op_Airn where BSNO='" + bsno + "'"; var sql3 = ""; var sql4 = ""; var sql5 = ""; var sql6 = ""; PrintComm(printType, sql1, sql2, sql3, sql4, sql5, sql6); } else { Ext.Msg.show({ title: '错误', msg: jsonresult.Message, icon: Ext.Msg.ERROR, buttons: Ext.Msg.OK }); } } else { Ext.Msg.show({ title: '请重试', msg: '服务器响应出错', icon: Ext.Msg.ERROR, buttons: Ext.Msg.OK }); } } }); }, 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: '提示', msg: '请先选择要打印的业务!', 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; } let _printType = 'MsOpAirnLISTSELECT'; if (BLTYPE == "国内主单") { _printType = 'MsOpAirnLISTSELECT_Main'; } var printType = _printType; var sql1 = "select * from op_Airn WHERE BSNO IN (" + feeGidSql + ") order by " + sortstr; var sql2 = "select * from op_Airn where BSNO='" + bsno + "'"; var sql3 = ""; var sql4 = ""; var sql5 = ""; var sql6 = ""; PrintComm(printType, sql1, sql2, sql3, sql4, sql5, sql6); } });