diff --git a/BookingJieFeng/BookingJieFeng.csproj.user b/BookingJieFeng/BookingJieFeng.csproj.user index 28be9c4c..a48b3371 100644 --- a/BookingJieFeng/BookingJieFeng.csproj.user +++ b/BookingJieFeng/BookingJieFeng.csproj.user @@ -1,7 +1,7 @@  - Release|Any CPU + Debug|Any CPU FolderProfile true diff --git a/BookingWeb/BookingWeb.csproj.user b/BookingWeb/BookingWeb.csproj.user index af17a67a..e6a8406a 100644 --- a/BookingWeb/BookingWeb.csproj.user +++ b/BookingWeb/BookingWeb.csproj.user @@ -1,7 +1,7 @@  - Release|Any CPU + Debug|Any CPU true diff --git a/DSWeb/Areas/MvcShipping/Controllers/MsOpAirnController.cs b/DSWeb/Areas/MvcShipping/Controllers/MsOpAirnController.cs index 61907c73..e308142e 100644 --- a/DSWeb/Areas/MvcShipping/Controllers/MsOpAirnController.cs +++ b/DSWeb/Areas/MvcShipping/Controllers/MsOpAirnController.cs @@ -296,6 +296,11 @@ namespace DSWeb.MvcShipping.Controllers if (isPost) { + //增加一个判断 如无揽货人sale则报警不保存 + + + + var modb = new ModelObjectRepository(); DBResult result = modb.Save(headData, ModelObjectConvert.ToModelObjectList(CargobodyList), @@ -465,9 +470,6 @@ namespace DSWeb.MvcShipping.Controllers } - - - } diff --git a/DSWeb/Areas/MvcShipping/DAL/MsOpAirn/MsOpAirnDAL.cs b/DSWeb/Areas/MvcShipping/DAL/MsOpAirn/MsOpAirnDAL.cs index 5f63993c..c925f837 100644 --- a/DSWeb/Areas/MvcShipping/DAL/MsOpAirn/MsOpAirnDAL.cs +++ b/DSWeb/Areas/MvcShipping/DAL/MsOpAirn/MsOpAirnDAL.cs @@ -73,6 +73,7 @@ namespace DSWeb.MvcShipping.DAL.MsOpAirnDAL strSql.Append(" ,c.PRICE price,ISVOID "); strSql.Append(" ,(select isnull(ISAGENTCN,0) from info_client where shortname=B.AIRLINES) ISAGENTCN "); strSql.Append(" ,(select CODENAME from info_client where shortname=B.AIRLINES) AIRLINESCODE "); + strSql.Append(" ,(select name from company where gid=CORPID) CORPREF "); strSql.Append(" from OP_AIRN B "); //sql主分单过滤条件已在where中体现,无需再join中嵌套case 2018年1月27日10:44:14 @@ -155,6 +156,7 @@ namespace DSWeb.MvcShipping.DAL.MsOpAirnDAL strSql.Append(" ,c.PRICE price,ISVOID "); strSql.Append(" ,(select isnull(ISAGENTCN,0) from info_client where shortname=B.AIRLINES) ISAGENTCN "); strSql.Append(" ,(select CODENAME from info_client where shortname=B.AIRLINES) AIRLINESCODE "); + strSql.Append(" ,(select name from company where gid=CORPID) CORPREF "); strSql.Append(" from OP_AIRN B "); strSql.Append(" left join OP_AIRN_CARGO C on c.bsno =( CASE b.BLTYPE when '国内分单' then B.bsno else (select top 1 bsno from OP_AIRN where HBLNO=b.HBLNO and BLTYPE='国内分单') end) "); strSql.Append(" left join Import_cargoName icn on icn.gid=c.CARGOGID "); @@ -205,6 +207,7 @@ namespace DSWeb.MvcShipping.DAL.MsOpAirnDAL strSql.Append(" ,c.PRICE price,ISVOID "); strSql.Append(" ,(select isnull(ISAGENTCN,0) from info_client where shortname=B.AIRLINES) ISAGENTCN "); strSql.Append(" ,(select CODENAME from info_client where shortname=B.AIRLINES) AIRLINESCODE "); + strSql.Append(" ,(select name from company where gid=CORPID) CORPREF "); strSql.Append(" from OP_AIRN B "); strSql.Append(" left join OP_AIRN_CARGO C on c.bsno =( CASE b.BLTYPE when '国内分单' then B.bsno else (select top 1 bsno from OP_AIRN where HBLNO=b.HBLNO and BLTYPE='国内分单') end) "); strSql.Append(" left join Import_cargoName icn on icn.gid=c.CARGOGID "); @@ -260,6 +263,9 @@ namespace DSWeb.MvcShipping.DAL.MsOpAirnDAL strSql.Append(" ,c.PRICE price ,ISVOID,HDEMO"); strSql.Append(" ,(select isnull(ISAGENTCN,0) from info_client where shortname=B.AIRLINES) ISAGENTCN "); strSql.Append(" ,(select CODENAME from info_client where shortname=B.AIRLINES) AIRLINESCODE,HDEMO "); + strSql.Append(" ,(select name from company where gid=CORPID) CORPREF "); + strSql.Append(" ,(select name from company where gid=CORPID) CORPREF "); + strSql.Append(" from OP_AIRN B "); strSql.Append(" left join OP_AIRN_CARGO C on c.bsno =( CASE b.BLTYPE when '国内分单' then B.bsno else (select top 1 bsno from OP_AIRN where HBLNO=b.HBLNO and BLTYPE='国内分单') end) "); strSql.Append(" left join Import_cargoName icn on icn.gid=c.CARGOGID "); @@ -499,6 +505,8 @@ namespace DSWeb.MvcShipping.DAL.MsOpAirnDAL data.ISVOID = Convert.ToDecimal(reader["ISVOID"]); data.HDEMO = Convert.ToString(reader["HDEMO"]); + data.CORPREF = Convert.ToString(reader["CORPREF"]); + #endregion headList.Add(data); } diff --git a/DSWeb/Areas/MvcShipping/Models/MsOpAirn/MsOpAirn.cs b/DSWeb/Areas/MvcShipping/Models/MsOpAirn/MsOpAirn.cs index 258c8a82..00be8bd7 100644 --- a/DSWeb/Areas/MvcShipping/Models/MsOpAirn/MsOpAirn.cs +++ b/DSWeb/Areas/MvcShipping/Models/MsOpAirn/MsOpAirn.cs @@ -236,9 +236,16 @@ namespace DSWeb.MvcShipping.Models.MsOpAirn { get{ return _corpid; } set{ _corpid = value; } - } - - private string _saledept = ""; + } + + private string _CORPREF = ""; + public string CORPREF + { + get { return _CORPREF; } + set { _CORPREF = value; } + } + + private string _saledept = ""; /// /// 所属部门 /// diff --git a/DSWeb/Areas/MvcShipping/Viewsjs/MainForm/MainForm.js b/DSWeb/Areas/MvcShipping/Viewsjs/MainForm/MainForm.js index ed67b113..ac9363dd 100644 --- a/DSWeb/Areas/MvcShipping/Viewsjs/MainForm/MainForm.js +++ b/DSWeb/Areas/MvcShipping/Viewsjs/MainForm/MainForm.js @@ -963,6 +963,12 @@ Ext.extend(Shipping.MainForm, Ext.Panel, { proxy: { url: modurl }//{ url: '/MvcShipping/MsChFee/GetFeeTypeRefListNew' } }); + this.PubStore_OpCode = Ext.create('DsExt.ux.RefTableStore', { + model: 'DsShipping.ux.UserRefModel', + proxy: { url: '/CommMng/BasicDataRef/GetUserLinkRefList' } + }); + this.PubStore_OpCode.load(); + ////var StoreStatusTask = { //Ext的定时器,每隔30秒刷新store。 //// run: function () { @@ -1180,6 +1186,10 @@ Ext.extend(Shipping.MainForm, Ext.Panel, { result = this.PubStore_CODE_FEE; } + if (STORENAME == "OpCode") { + result = this.PubStore_OpCode; + } + return result; //if ((result != "") && (result.getCount() == 0) ) { diff --git a/DSWeb/Areas/MvcShipping/Viewsjs/MsOpAirn/MsOpAirnFenEdit.js b/DSWeb/Areas/MvcShipping/Viewsjs/MsOpAirn/MsOpAirnFenEdit.js index fb393eaa..89b87824 100644 --- a/DSWeb/Areas/MvcShipping/Viewsjs/MsOpAirn/MsOpAirnFenEdit.js +++ b/DSWeb/Areas/MvcShipping/Viewsjs/MsOpAirn/MsOpAirnFenEdit.js @@ -19,6 +19,9 @@ Ext.extend(Shipping.MsOpSeaeFenEdit, Ext.Panel, { //this.bodyDel = []; this.itemindex = 1; + parentWin = window.parent.opener; + mainWin = getMainForm(parentWin); + //#region 信息加载 //权限范围 this.storeDefValue = Ext.create('Ext.data.Store', { @@ -59,7 +62,8 @@ Ext.extend(Shipping.MsOpSeaeFenEdit, Ext.Panel, { model: 'DsShipping.ux.UserRefModel', proxy: { url: '/CommMng/BasicDataRef/GetUserRefList' } }); - this.storeOpCode.load(); + //this.storeOpCode.load(); + this.storeOpCode.loadData(mainWin.GetPubStore("OpCode").data.items); //客服 this.comboxCUSTSERVICE = Ext.create('DsExt.ux.RefTableCombox', { fieldLabel: '客服', diff --git a/DSWeb/Areas/MvcShipping/Viewsjs/MsOpAirn/MsOpAirnFenIndex.js b/DSWeb/Areas/MvcShipping/Viewsjs/MsOpAirn/MsOpAirnFenIndex.js index 371a77d6..1e12db59 100644 --- a/DSWeb/Areas/MvcShipping/Viewsjs/MsOpAirn/MsOpAirnFenIndex.js +++ b/DSWeb/Areas/MvcShipping/Viewsjs/MsOpAirn/MsOpAirnFenIndex.js @@ -313,6 +313,17 @@ Ext.extend(Shipping.MsOpAirnFenIndex, Ext.Panel, { dataIndex: 'VOUNO', header: '凭证号', width: 60 + }, { + sortable: true, + dataIndex: 'SALEDEPT', + header: '所属部门', + width: 120 + }, { + sortable: true, + hidden:true, + dataIndex: 'CORPREF', + header: '所属公司', + width: 120 }]; //定义Grid diff --git a/DSWeb/Areas/MvcShipping/Viewsjs/MsOpAirn/MsOpAirnIndex.js b/DSWeb/Areas/MvcShipping/Viewsjs/MsOpAirn/MsOpAirnIndex.js index 666083a0..2d494d26 100644 --- a/DSWeb/Areas/MvcShipping/Viewsjs/MsOpAirn/MsOpAirnIndex.js +++ b/DSWeb/Areas/MvcShipping/Viewsjs/MsOpAirn/MsOpAirnIndex.js @@ -19,6 +19,10 @@ Ext.extend(Shipping.MsOpAirnIndex, Ext.Panel, { initUIComponents: function () { this.formname = "formMsOpAirnIndex"; //页面名称 + + parentWin = window.parent; + mainWin = getMainForm(parentWin); + //定义数据集 this.storePLList = Ext.create('Ext.data.Store', { model: 'MsOpAirnModel' @@ -674,6 +678,17 @@ Ext.extend(Shipping.MsOpAirnIndex, Ext.Panel, { dataIndex: 'STLDATE', header: '结算日期', width: 120 + }, { + sortable: true, + dataIndex: 'SALEDEPT', + header: '所属部门', + width: 120 + }, { + sortable: true, + hidden: true, + dataIndex: 'CORPREF', + header: '所属公司', + width: 120 }]; diff --git a/DSWeb/Areas/MvcShipping/Viewsjs/MsOpAirn/MsOpAirnMainEdit.js b/DSWeb/Areas/MvcShipping/Viewsjs/MsOpAirn/MsOpAirnMainEdit.js index dee622f1..1853981a 100644 --- a/DSWeb/Areas/MvcShipping/Viewsjs/MsOpAirn/MsOpAirnMainEdit.js +++ b/DSWeb/Areas/MvcShipping/Viewsjs/MsOpAirn/MsOpAirnMainEdit.js @@ -17,6 +17,7 @@ Ext.extend(Shipping.MsOpAirnEdit, Ext.Panel, { isfen: false, HBLNO: "", BSNO: "", + cansave:false, initUIComponents: function () { this.serialNo = 0; @@ -25,6 +26,9 @@ Ext.extend(Shipping.MsOpAirnEdit, Ext.Panel, { this.initloaddata = 0; this.CargoDel = []; this.formname = "OpAirnMainEdit"; //页面名称 + + + //#region 信息加载 this.storeDefValue = Ext.create('Ext.data.Store', { model: 'DsShipping.ux.OpDefValue', @@ -70,6 +74,7 @@ Ext.extend(Shipping.MsOpAirnEdit, Ext.Panel, { model: 'DsShipping.ux.UserRefModel', proxy: { url: '/CommMng/BasicDataRef/GetUserLinkRefList' } }); + //客服 this.comboxCUSTSERVICE = Ext.create('DsExt.ux.RefTableCombox', { @@ -492,7 +497,8 @@ Ext.extend(Shipping.MsOpAirnEdit, Ext.Panel, { this.storeDept.load(); this.comboxDept = Ext.create('DsExt.ux.RefTableCombox', { fieldLabel: '所属部门', - hidden: true, + //hidden: true, + readOnly: true, store: this.storeDept, forceSelection: true, name: 'SALEDEPT', @@ -755,7 +761,7 @@ Ext.extend(Shipping.MsOpAirnEdit, Ext.Panel, { xtype: 'container', layout: 'hbox', defaultType: 'textfield', - items: [this.comboxCustCode, this.comboxBSSOURCE, this.comboxBSSOURCEDETAIL, this.comboxDept] + items: [this.comboxCustCode, this.comboxBSSOURCE, this.comboxBSSOURCEDETAIL] }, { xtype: 'container', layout: 'hbox', @@ -806,7 +812,7 @@ Ext.extend(Shipping.MsOpAirnEdit, Ext.Panel, { xtype: 'container', layout: 'hbox', defaultType: 'textfield', - items: [this.comboxSALE, this.comboxCUSTSERVICE, {xtype:"hiddenfield",flex:3}] + items: [this.comboxSALE, this.comboxCUSTSERVICE, this.comboxDept, {xtype:"hiddenfield",flex:2}] } , this.myCheckboxService, { xtype: 'container', @@ -2854,13 +2860,14 @@ Ext.extend(Shipping.MsOpAirnEdit, Ext.Panel, { // parentWin = window.parent.opener._this; parentWin = window.parent.opener._thisfenlist; + if (parentWin == NaN || parentWin == null) { parentWin = window.parent.opener._this; - } else { this.isfen = true; } + this.InitData(); this.formCargo.on('edit', function (editor, e, eOpts) { @@ -2942,6 +2949,23 @@ Ext.extend(Shipping.MsOpAirnEdit, Ext.Panel, { this._Head = ret[5]; this._Edit = ret[6]; + + mainWin = {}; + if (this.parenttype == "OP_AIRN_Edit" ) { + //parentWin = window.parent.opener._this; + + parentWin2 = window.parent.opener.opener; + mainWin = getMainForm(parentWin2); + + } else { + + parentWin2 = window.parent.opener; + mainWin = getMainForm(parentWin2); + } + + this.storeOpCode.loadData(mainWin.GetPubStore("OpCode").data.items); + + /* if (parenttype == "OP_AIRN_Edit") { this.formHead.getForm().findField('HBLNO').setValue(ret[3]); @@ -3121,7 +3145,7 @@ Ext.extend(Shipping.MsOpAirnEdit, Ext.Panel, { if (data.ISVOID == "1") { this.setSaveBtnStatus(false); } - + this.cansave = true; } else { Ext.MessageBox.alert('请求出现错误,请重试', response.responseText); } @@ -3147,7 +3171,7 @@ Ext.extend(Shipping.MsOpAirnEdit, Ext.Panel, { LoadInitData: function () { this.storeCustCode.load({ params: { condition: "ISCONTROLLER='1'"} }); - this.storeOpCode.load(); + //this.storeOpCode.load(); this.storeAIRLINES.load({ params: { condition: "ISAIRLINES='1'" } , callback: function (r, options, success) { @@ -3173,6 +3197,9 @@ Ext.extend(Shipping.MsOpAirnEdit, Ext.Panel, { }, //#region 保存 Save: function (type, print) { + + if (!this.cansave) return; + var _this = this; var basicForm = this.formEdit.getForm(); var basicForm2 = this.formHead.getForm(); diff --git a/DSWeb/DSWeb.csproj.user b/DSWeb/DSWeb.csproj.user index 68b78620..4b503d3c 100644 --- a/DSWeb/DSWeb.csproj.user +++ b/DSWeb/DSWeb.csproj.user @@ -4,7 +4,7 @@ ShowAllFiles 配置文件1 true - Release|Any CPU + Debug|Any CPU diff --git a/DSWeb/Web.config b/DSWeb/Web.config index a5d86bb9..327c4aff 100644 --- a/DSWeb/Web.config +++ b/DSWeb/Web.config @@ -96,7 +96,7 @@ --> - + - - --> - + + - + - - --> - + +