From 3417a4c74571299f4dd8fe3d6c1e4a0f1c4c75e8 Mon Sep 17 00:00:00 2001 From: hanxuntao <641739520@qq.com> Date: Wed, 1 Feb 2023 15:48:35 +0800 Subject: [PATCH] 1 --- .../Controllers/MsInfoClientController.cs | 5 +- .../MvcShipping/DAL/MsOpSeae/MsOpSeaeDAL.cs | 5 +- .../Views/MsInfoClient/MinIndex.aspx | 63 ++++ .../Viewsjs/MsChFee/FeeDrCrGrid.js | 16 +- .../Viewsjs/MsInfoClient/MinIndex.js | 31 ++ .../MsInfoClient/MsInfoClientMinIndex.js | 356 ++++++++++++++++++ .../Viewsjs/MsOpSeae/MsOpSeaeEdit.js | 16 +- .../Viewsjs/MsOpSeae/MsOpSeaeIndex.js | 9 +- DSWeb/DSWeb.csproj | 3 + 9 files changed, 490 insertions(+), 14 deletions(-) create mode 100644 DSWeb/Areas/MvcShipping/Views/MsInfoClient/MinIndex.aspx create mode 100644 DSWeb/Areas/MvcShipping/Viewsjs/MsInfoClient/MinIndex.js create mode 100644 DSWeb/Areas/MvcShipping/Viewsjs/MsInfoClient/MsInfoClientMinIndex.js diff --git a/DSWeb/Areas/MvcShipping/Controllers/MsInfoClientController.cs b/DSWeb/Areas/MvcShipping/Controllers/MsInfoClientController.cs index 67211681..8d581783 100644 --- a/DSWeb/Areas/MvcShipping/Controllers/MsInfoClientController.cs +++ b/DSWeb/Areas/MvcShipping/Controllers/MsInfoClientController.cs @@ -149,7 +149,10 @@ namespace DSWeb.MvcShipping.Controllers { return View(); } - + public ActionResult MinIndex() + { + return View(); + } //[SqlKeyWordsFilter(Type = "Action")]//sql 防注入过滤器 public ContentResult GetDataList ( int start, int limit, string condition, string sort ) diff --git a/DSWeb/Areas/MvcShipping/DAL/MsOpSeae/MsOpSeaeDAL.cs b/DSWeb/Areas/MvcShipping/DAL/MsOpSeae/MsOpSeaeDAL.cs index 93e28472..1ce0c664 100644 --- a/DSWeb/Areas/MvcShipping/DAL/MsOpSeae/MsOpSeaeDAL.cs +++ b/DSWeb/Areas/MvcShipping/DAL/MsOpSeae/MsOpSeaeDAL.cs @@ -842,8 +842,9 @@ namespace DSWeb.MvcShipping.DAL.MsOpSeaeDAL strSql.Append(",'' as OPSTATUS "); strSql.Append(",(select EnumValueName from tSysEnumValue where LangId=0 and EnumTypeID=97018 and EnumValueID=B.MANIFESTSTATUS) as MANIFESTSTATUSREF"); strSql.Append(",CUSTOMNO,ENTERPID,ENTERP,INSPECTIONNO,INSPECTIONDATE,CUSTOMDATE,CLEARCUSTOMDATE,ISMOREGOOD,TERMSDELIVERY,INSPECTSERVICE,TRADETERM,0 FENPIAO,ISGAIQIAN,WARNCOUNT"); - strSql.Append(",'' DRFEESTATUS"); - strSql.Append(",'' CRFEESTATUS"); + + strSql.Append(",dbo.F_GetBillDrFeeStatus(B.BSNO) DRFEESTATUS"); + strSql.Append(",dbo.F_GetBillCrFeeStatus(B.BSNO) CRFEESTATUS"); strSql.Append(",SHIPAGENCY,ISPRINTPR,MAILPROJECT,0 AMENDCOUNT,0 as APPLYCOUNT,0 TTLDR,0 TTLINVDR,0 TTLDUIDR,0 TTLCR,0 TTLINVCR,0 TTLDUICR,0 YJCR,0 HYFDR,0 HYFCR,0 BGFDR,0 TTLPROFIT,0 PROFITRATE,0 NODAY,ISCANCEL,ISTUI,''TRANSREMARK,PRERECORD "); strSql.Append(",MSHIPPERID,MCONSIGNEEID,MNOTIFYPARTYID,MSHIPPER,MCONSIGNEE,MNOTIFYPARTY,ATD,DELIVERYDATE,YARDATTN,YARDTEL "); diff --git a/DSWeb/Areas/MvcShipping/Views/MsInfoClient/MinIndex.aspx b/DSWeb/Areas/MvcShipping/Views/MsInfoClient/MinIndex.aspx new file mode 100644 index 00000000..9e5d3eff --- /dev/null +++ b/DSWeb/Areas/MvcShipping/Views/MsInfoClient/MinIndex.aspx @@ -0,0 +1,63 @@ +<%@ Page Title="" Language="C#" MasterPageFile="~/Areas/MvcShipping/Views/Shared/Site.Master" Inherits="System.Web.Mvc.ViewPage" %> + + + + + + + + + + + + + + + + +
+
diff --git a/DSWeb/Areas/MvcShipping/Viewsjs/MsChFee/FeeDrCrGrid.js b/DSWeb/Areas/MvcShipping/Viewsjs/MsChFee/FeeDrCrGrid.js index 4f71f71b..79919bc1 100644 --- a/DSWeb/Areas/MvcShipping/Viewsjs/MsChFee/FeeDrCrGrid.js +++ b/DSWeb/Areas/MvcShipping/Viewsjs/MsChFee/FeeDrCrGrid.js @@ -1706,8 +1706,8 @@ Ext.extend(Shipping.FeeEditGrid, Ext.Panel, { }], scope: this }, '-', { - text: Zi.LAN.FEE.TruckDetail, //'查看信息', - tooltip: Zi.LAN.FEE.TruckDetail, //查看信息', + text: '查看客户', //'查看信息', + tooltip: '查看客户', //查看信息', handler: function (button, event) { this.onTruckDetailClick(button, event, 1); }, @@ -2808,8 +2808,8 @@ Ext.extend(Shipping.FeeEditGrid, Ext.Panel, { }], scope: this }, '-', { - text: Zi.LAN.FEE.TruckDetail, //'查看信息', - tooltip: Zi.LAN.FEE.TruckDetail, //查看信息', + text: '查看客户', //'查看信息', + tooltip: '查看客户', //查看信息', handler: function (button, event) { this.onTruckDetailClick(button, event, 2); }, @@ -8940,11 +8940,11 @@ Ext.extend(Shipping.FeeEditGrid, Ext.Panel, { onTruckDetailClick: function (button, event, type) { - var openSet = "height=740, width=890, toolbar=no, menubar=no,scrollbars=no, resizable=no,location=no, status=no,Top= " + (screen.height - 540) / 2 + ",Left= " + (screen.width - 890) / 2 + var openSet = "height=440, width=890, toolbar=no, menubar=no,scrollbars=no, resizable=no,location=no, status=no,Top= " + (screen.height - 440) / 2 + ",Left= " + (screen.width - 890) / 2 var openType = "_blank"; - //打开费用“历史信息查询”页面 - // var openUrl = "../../Shipping/FeeHistory.aspx?bsno=" + this.strBSNO + "&oplb=" + this.stroplb + "&type=" + type; - var openUrl = "../../MvcShipping/MsOpLetter/TruckFeeIndex?bsno=" + this.strBSNO + "&oplb=" + this.stroplb + "&type=" + type; +// var openUrl = "../../MvcShipping/MsOpLetter/TruckFeeIndex?bsno=" + this.strBSNO + "&oplb=" + this.stroplb + "&type=" + type; + var openUrl = "../../MvcShipping/MsInfoClient/MinIndex"; + window.open(openUrl, openType, openSet); }, diff --git a/DSWeb/Areas/MvcShipping/Viewsjs/MsInfoClient/MinIndex.js b/DSWeb/Areas/MvcShipping/Viewsjs/MsInfoClient/MinIndex.js new file mode 100644 index 00000000..c01aae1b --- /dev/null +++ b/DSWeb/Areas/MvcShipping/Viewsjs/MsInfoClient/MinIndex.js @@ -0,0 +1,31 @@ +Ext.BLANK_IMAGE_URL = '../../TruckMng/Content/Images/s.gif'; +var panelIndex = null; +Ext.onReady(function () { + Ext.QuickTips.init(); + Ext.form.Field.prototype.msgTarget = 'side'; + + panelIndex = new window.Shipping.MsInfoClientMinIndex({ + layout: 'border' + }); + + var view = new Ext.Viewport({ + layout: 'border', + renderTo: 'viewport', + border: false, + items: [{ + region: 'center', + layout: 'fit', + items: [panelIndex] + }] + }); + + +}); + +function OprationSwap() { + return panelIndex.OprationSwap(); +} + +function AddNewRecord(record) { + panelIndex.AddNewRecord(record); +} diff --git a/DSWeb/Areas/MvcShipping/Viewsjs/MsInfoClient/MsInfoClientMinIndex.js b/DSWeb/Areas/MvcShipping/Viewsjs/MsInfoClient/MsInfoClientMinIndex.js new file mode 100644 index 00000000..24e3f3d9 --- /dev/null +++ b/DSWeb/Areas/MvcShipping/Viewsjs/MsInfoClient/MsInfoClientMinIndex.js @@ -0,0 +1,356 @@ +Ext.namespace('Shipping'); + +Shipping.MsInfoClientMinIndex = function (config) { + Ext.applyIf(this, config); + this.initUIComponents(); + window.Shipping.MsInfoClientMinIndex.superclass.constructor.call(this); +}; + +Ext.extend(Shipping.MsInfoClientMinIndex, Ext.Panel, { + PageSize: 20, + OprationStatus: null, //仅当弹出界面时使用 + SelectedRecord: null, + isShowAdvancedQuery: 0, //是否显示高级查询面板 + sqlcontext: '', + editype: '', + selectbsno: '', + sortfield: '', + sortdire: '', + + //需求编号:SR2017061200005-1 + initUIComponents: function () { + this.formname = "formInfoClientMinIndex"; //页面名称 + //定义数据集 + this.storectndisp = Ext.create('DsExt.ux.RefTableStore', { + model: 'DsShipping.ux.CtnDispModel', + proxy: { url: '/CommMng/BasicDataRef/GetCtnDisp' } + }); + + this.storeList = Ext.create('Ext.data.Store', { + pageSize: this.PageSize, + model: 'MsInfoClientModel', + remoteSort: true, + proxy: { + type: 'ajax', + url: '/MvcShipping/MsInfoClient/GetDataList', + reader: { + id: 'GID', + root: 'data', + totalProperty: 'totalCount' + } + } + }); + + 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(); + } + } + } + }); + + + //#region List列表显示信息 + + + + Ext.grid.RowNumberer = Ext.extend(Ext.grid.RowNumberer, { + width: 30 + }); + + _this = this; + + this.initgirdcolums = [{ + sortable: true, + id: '', + dataIndex: '', + header: '', + width: 0 + }, { + sortable: true, + id: '', + dataIndex: 'GID', + header: Zi.LAN.GID, //'编号', + hidden: true, + width: 0 + }, { + sortable: true, + id: '', + dataIndex: 'CODENAME', + header: Zi.LAN.CODENAME, //'客户代码', + width: 120 + }, { + sortable: true, + id: '', + dataIndex: 'SHORTNAME', + header: Zi.LAN.SHORTNAME, //'客户简称', + width: 120 + }, { + sortable: true, + id: '', + dataIndex: 'DESCRIPTION', + header: Zi.LAN.DESCRIPTION, //'客户全称', + width: 200 + }, + { + sortable: true, + id: '', + dataIndex: 'ADDR', + header: Zi.LAN.ADDR, //'业务锁定', + align: 'center', + width: 80 + }, + { + sortable: true, + id: '', + dataIndex: 'TEL', + header: Zi.LAN.TEL, //'电话', + width: 120 + }, + { + sortable: true, + id: '', + dataIndex: 'FAX', + header: Zi.LAN.FAX, //'传真', + width: 80 + } + + + ]; + + + this.girdcolums = this.initgirdcolums; + + this.GridCheckBoxModel = Ext.create('Ext.selection.CheckboxModel'); + + + //定义Grid + this.gridList = new Ext.grid.GridPanel({ + store: this.storeList, + enableHdMenu: false, + region: 'center', + loadMask: { msg: Zi.LAN.ShuJuJiaZaiZhong }, //"数据加载中,请稍等..." + trackMouseOver: true, + disableSelection: false, + selModel: this.GridCheckBoxModel, + viewConfig: { + enableTextSelection: true, //允许复制数据 + autoFill: true + }, + + listeners: { + cellclick: function (thisTab, record, item, index, e, eOpts) { + if (index == 10) {//设置按钮列 + // alert('用户编号=' + this.getStore().getAt(rowIndex).data.usercode); + + } + } + }, + columns: this.girdcolums, + // paging bar on the bottom + bbar: [Ext.create('Ext.PagingToolbar', { + store: this.storeList, + displayMsg: Zi.LAN.displayMsg, //'当前显示 {0} - {1}条记录 /共 {2}条记录', + emptyMsg: Zi.LAN.emptyMsg, //"没有数据" + displayInfo: true + }), this.Pagenum] + }); + + /////////////以下部分为获取存储的gridpanel显示样式 + this.girdcolums = DsTruck.GetGridPanel(USERID, this.formname, this.girdcolums, 1); //使用者id,表名,中间column数组,跳过一开始的几列 + this.gridList.columns[0] = new Ext.grid.RowNumberer(); + this.gridList.reconfigure(this.storeList, this.girdcolums); + //////////////////////////////////////////////// + + this.gridList.addListener('itemdblclick', function (dataview, record, item, index, e, b) { + //this.SelectedRecord = record; + //this.OprationStatus = 'edit'; + //var openSet = "height=700, width=1200, toolbar=no, menubar=no,scrollbars=1, resizable=1,location=no, status=no,Top= " + (screen.height - 750) / 2 + ",Left= " + (screen.width - 1100) / 2 + //var openType = "_blank"; + //var openUrl = "/MvcShipping/MsInfoClient/Edit"; + //window.open(openUrl, openType, openSet); + }, this); + + this.gridList.addListener('sortchange', function (ct, column, direction, eOpts) { + this.sortfield = column.dataIndex; + this.sortdire = direction; + }, this); + + //#region formSearch 下拉框信息加载 + //权限范围 + + //#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: 90, + msgTarget: 'qtip' + }, + + + items: [{//fieldset 1 + xtype: 'container', + defaultType: 'textfield', + layout: 'anchor', + defaults: { + anchor: '100%' + }, + items: [{ + xtype: 'container', + layout: 'hbox', + defaultType: 'textfield', + items: [{ + fieldLabel: '代码或简称、全称', //'代码或简称', + labelWidth: 120, name: 'MblNo', + enableKeyEvents: true, + listeners: { + specialkey: function (field, e) { + if (e.getKey() == e.ENTER) { + _this.onRefreshClick(); + } + } + } + } + , { + xtype: 'button', + width: 90, + text: Zi.LAN.btnRefresh, //"执行查询", + iconCls: "btnrefresh", + handler: function (button, event) { + this.onRefreshClick(button, event); + }, + scope: this + }, { + xtype: 'button', + width: 45, + // text: Zi.LAN.btnMore, //"高级查询", + iconCls: "btnmore", + handler: function (button, event) { + var sql = this.getCondition(); + var winAccess = new Shipping.DsQuery({ + + }); + winAccess.StoreList = this.storeList; + winAccess.formname = this.formname; + winAccess.condition = sql; + winAccess.show(); + return; + }, + scope: this + }] + } + + ]//end items(fieldset 1) + }]//end root items + }); + //#endregion formSearch + + _this = this; + //按钮工具条_ + + this.panelTop = new Ext.Panel({ + layout: "border", + region: "north", + height: 60, + items: [this.formSearch] + }); + + Ext.apply(this, { + items: [this.panelTop, this.gridList] + }); + + //this.storeList.load({ + // params: { start: 0, limit: this.PageSize, sort: '', condition: '', load: 'true' }, + // waitMsg: Zi.LAN.ZhengZaiChaXunShuJu, + // scope: this + //}); + + this.storeList.on('beforeload', function (store) { + // var sql = this.getCondition(); + Ext.apply(store.proxy.extraParams, { condition: _this.sqlcontext }); + }, this); + + + + }, //end initUIComponents + + onRefreshClick: function (button, event) { + //var girdcolums = this.gridList.getColumnMode(); + var sql = this.getCondition(); + this.sqlcontext = sql; + this.PageSize = this.Pagenum.getValue(); + + this.storeList.pageSize = this.PageSize; + this.storeList.load({ + params: { start: 0, limit: this.PageSize, sort: '', condition: sql }, + waitMsg: Zi.LAN.ZhengZaiChaXunShuJu, + scope: this + }); + + }, + + onDsQuery: function () { + //var girdcolums = this.gridList.getColumnMode(); + var sql = this.sqlcontext; + this.storeList.load({ + params: { start: 0, limit: this.PageSize, sort: '', condition: sql }, + waitMsg: Zi.LAN.ZhengZaiChaXunShuJu, + scope: this + }); + }, + + //end initUIComponents + + 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(Zi.LAN.TiShi, Zi.LAN.ChaXunTiaoJianFuZhiCuoWu); //'查询条件赋值错误,请检查。' + return ''; + } + this.isShowAdvancedQuery = 0; + // + var sql = ''; + + //#region formSearch 查询面板 + var MblNo = form.findField('MblNo').getValue(); + sql = sql + getAndConSql(sql, MblNo, "(CODENAME like '%" + MblNo + "%' or SHORTNAME like '%" + MblNo + "%' or DESCRIPTION like '%" + MblNo + "%')"); + + + 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] = 'info_client'; + return ret; + } + +}); + + diff --git a/DSWeb/Areas/MvcShipping/Viewsjs/MsOpSeae/MsOpSeaeEdit.js b/DSWeb/Areas/MvcShipping/Viewsjs/MsOpSeae/MsOpSeaeEdit.js index b73fc843..1048f6ff 100644 --- a/DSWeb/Areas/MvcShipping/Viewsjs/MsOpSeae/MsOpSeaeEdit.js +++ b/DSWeb/Areas/MvcShipping/Viewsjs/MsOpSeae/MsOpSeaeEdit.js @@ -12760,6 +12760,20 @@ Ext.extend(Shipping.MsOpSeaeEdit, Ext.Panel, { if (isNullorEmpty(data.TOTALNO)) { this.SetTOTALNO(data.NOPKGS); } + if (data.DRFEESTATUS != '未录入' || data.CRFEESTATUS != '未录入') { + var paneltabitems = new Shipping.SeaeFee({ + id: 'pnlmodSeaeAllFee', + layout: "border", + region: "center", + autoScroll: true, + frame: false, + closable: true, + title: '应收应付费用' + }); + this.tabSeaepanel.add(paneltabitems); + //this.tabSeaepanel.setActiveTab(paneltabitems); + this.tabSeaepanel.doLayout(); + } } else { @@ -16390,7 +16404,7 @@ Ext.extend(Shipping.MsOpSeaeEdit, Ext.Panel, { var cgCARRIER = Ext.getCmp('rCARRIER'); cgCARRIER.setValue({ CARRIER: carriercode }); this.winINTTRShow.show(); - } else if (this.editype == 'YTEDI') { + } else if (this.editype == 'YTEDI' || this.editype == 'ZIMEDI') { var cgFILETYPE = Ext.getCmp('ytFILETYPE'); cgFILETYPE.setValue({ FILETYPE: type }); var cgCARRIER = Ext.getCmp('ytCARRIER'); diff --git a/DSWeb/Areas/MvcShipping/Viewsjs/MsOpSeae/MsOpSeaeIndex.js b/DSWeb/Areas/MvcShipping/Viewsjs/MsOpSeae/MsOpSeaeIndex.js index bb3d3fa2..381b1f7b 100644 --- a/DSWeb/Areas/MvcShipping/Viewsjs/MsOpSeae/MsOpSeaeIndex.js +++ b/DSWeb/Areas/MvcShipping/Viewsjs/MsOpSeae/MsOpSeaeIndex.js @@ -3107,8 +3107,13 @@ Ext.extend(Shipping.MsOpSeaeIndex, Ext.Panel, { var mydateend = new Date(nowYear, nowMonth, getMonthDays(nowMonth)); var mydatestr = Ext.util.Format.date(mydate, 'Y-m-d'); var mydateendstr = Ext.util.Format.date(mydateend, 'Y-m-d'); + this.formSearch.getForm().findField('ETDbgn').setValue(mydatestr); + this.formSearch.getForm().findField('ETDend').setValue(mydateendstr); + + // var mydatestr = Ext.util.Format.date(myDate, 'Y-m'); - this.sqlcontext = " ((B.ETD>='" + mydatestr + "' AND B.ETD<='" + mydateendstr+"') OR B.ETD IS NULL) "; + //this.sqlcontext = " ((B.ETD>='" + mydatestr + "' AND B.ETD<='" + mydateendstr+"') OR B.ETD IS NULL) "; + this.sqlcontext = " ((B.ETD>='" + mydatestr + "' AND B.ETD<='" + mydateendstr + "')) "; //this.gridList.filters.clearFilters(); @@ -9096,7 +9101,7 @@ Ext.extend(Shipping.MsOpSeaeIndex, Ext.Panel, { var cgCARRIER = Ext.getCmp('rCARRIER'); cgCARRIER.setValue({ CARRIER: carriercode }); this.winINTTRShow.show(); - } else if (this.editype == 'YTEDI') { + } else if (this.editype == 'YTEDI' || this.editype == 'ZIMEDI') { var cgFILETYPE = Ext.getCmp('ytFILETYPE'); cgFILETYPE.setValue({ FILETYPE: type }); var cgCARRIER = Ext.getCmp('ytCARRIER'); diff --git a/DSWeb/DSWeb.csproj b/DSWeb/DSWeb.csproj index b289a4a1..a078e7f4 100644 --- a/DSWeb/DSWeb.csproj +++ b/DSWeb/DSWeb.csproj @@ -1668,6 +1668,8 @@ + + @@ -2792,6 +2794,7 @@ +