From edb8ad27534dff2565232c75e0e2c0f03555d11d Mon Sep 17 00:00:00 2001 From: gaofei <181547018@qq.com> Date: Wed, 22 Feb 2023 12:34:27 +0800 Subject: [PATCH 1/2] =?UTF-8?q?=E4=BF=AE=E6=94=B9=E6=9D=90=E6=96=99?= =?UTF-8?q?=E7=AE=A1=E7=90=86?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../版本日志/SGGLDB_V2023-02-22_gaofei.sql | 2 + .../BLL/CQMS/Material/CQMS_MaterialService.cs | 2 + .../FineUIPro.Web/CQMS/Material/Material.aspx | 8 ++-- .../CQMS/Material/MaterialEdit.aspx | 14 +++--- .../CQMS/Material/MaterialEdit.aspx.cs | 21 +++++---- .../Material/MaterialEdit.aspx.designer.cs | 9 ++++ .../CQMS/Material/MaterialIn.aspx.cs | 43 ++++++++++++------ .../File/Excel/DataIn/材料信息导入模板.xls | Bin 26112 -> 26112 bytes SGGL/Model/Model.cs | 34 ++++++++++++-- 9 files changed, 95 insertions(+), 38 deletions(-) create mode 100644 DataBase/版本日志/SGGLDB_V2023-02-22_gaofei.sql diff --git a/DataBase/版本日志/SGGLDB_V2023-02-22_gaofei.sql b/DataBase/版本日志/SGGLDB_V2023-02-22_gaofei.sql new file mode 100644 index 00000000..a005a27a --- /dev/null +++ b/DataBase/版本日志/SGGLDB_V2023-02-22_gaofei.sql @@ -0,0 +1,2 @@ +alter table [dbo].[Material_Material] add Factory nvarchar(100) null +GO \ No newline at end of file diff --git a/SGGL/BLL/CQMS/Material/CQMS_MaterialService.cs b/SGGL/BLL/CQMS/Material/CQMS_MaterialService.cs index 618f8463..f481d62c 100644 --- a/SGGL/BLL/CQMS/Material/CQMS_MaterialService.cs +++ b/SGGL/BLL/CQMS/Material/CQMS_MaterialService.cs @@ -38,6 +38,7 @@ namespace BLL newMaterial.ArrivalDate = Material.ArrivalDate; newMaterial.CompileMan = Material.CompileMan; newMaterial.CompileDate = Material.CompileDate; + newMaterial.Factory = Material.Factory; db.Material_Material.InsertOnSubmit(newMaterial); db.SubmitChanges(); } @@ -64,6 +65,7 @@ namespace BLL newMaterial.Num = Material.Num; newMaterial.ArrivalDate = Material.ArrivalDate; newMaterial.InspectionId = Material.InspectionId; + newMaterial.Factory = Material.Factory; db.SubmitChanges(); } } diff --git a/SGGL/FineUIPro.Web/CQMS/Material/Material.aspx b/SGGL/FineUIPro.Web/CQMS/Material/Material.aspx index 0a5ee8ed..0d9d0ccc 100644 --- a/SGGL/FineUIPro.Web/CQMS/Material/Material.aspx +++ b/SGGL/FineUIPro.Web/CQMS/Material/Material.aspx @@ -29,7 +29,7 @@ - + @@ -67,7 +67,7 @@ HeaderTextAlign="Center"> - + diff --git a/SGGL/FineUIPro.Web/CQMS/Material/MaterialEdit.aspx b/SGGL/FineUIPro.Web/CQMS/Material/MaterialEdit.aspx index b87c6433..52950f31 100644 --- a/SGGL/FineUIPro.Web/CQMS/Material/MaterialEdit.aspx +++ b/SGGL/FineUIPro.Web/CQMS/Material/MaterialEdit.aspx @@ -16,15 +16,15 @@ + MaxLength="70" LabelWidth="100px"> - + - + @@ -34,7 +34,7 @@ + MaxLength="70" LabelWidth="100px" > @@ -63,10 +63,12 @@ - - + + diff --git a/SGGL/FineUIPro.Web/CQMS/Material/MaterialEdit.aspx.cs b/SGGL/FineUIPro.Web/CQMS/Material/MaterialEdit.aspx.cs index 7aacfae5..9ac662f8 100644 --- a/SGGL/FineUIPro.Web/CQMS/Material/MaterialEdit.aspx.cs +++ b/SGGL/FineUIPro.Web/CQMS/Material/MaterialEdit.aspx.cs @@ -57,6 +57,7 @@ namespace FineUIPro.Web.CQMS.Material { this.txtArrivalDate.Text = string.Format("{0:yyyy-MM-dd}", Material.ArrivalDate); } + this.txtFactory.Text = Material.Factory; } } } @@ -68,14 +69,14 @@ namespace FineUIPro.Web.CQMS.Material { if (this.drpUnit.SelectedValue == BLL.Const._Null) { - Alert.ShowInTop("请选择供货单位!", MessageBoxIcon.Warning); - return; - } - if (this.drpMainItem.SelectedValue == BLL.Const._Null) - { - Alert.ShowInTop("请选择主项!", MessageBoxIcon.Warning); + Alert.ShowInTop("请选择采购单位!", MessageBoxIcon.Warning); return; } + //if (this.drpMainItem.SelectedValue == BLL.Const._Null) + //{ + // Alert.ShowInTop("请选择主项!", MessageBoxIcon.Warning); + // return; + //} SaveData(); } else @@ -91,7 +92,10 @@ namespace FineUIPro.Web.CQMS.Material Material.ProjectId = this.CurrUser.LoginProjectId; Material.ContractNo = this.txtContractNo.Text.Trim(); Material.UnitId = this.drpUnit.SelectedValue; - Material.MainItemId = this.drpMainItem.SelectedValue; + if (this.drpMainItem.SelectedValue != BLL.Const._Null) + { + Material.MainItemId = this.drpMainItem.SelectedValue; + } Material.MaterialName = this.txtMaterialName.Text.Trim(); Material.SpecificationAndModel = this.txtSpecificationAndModel.Text.Trim(); Material.MaterialCode = this.txtMaterialCode.Text.Trim(); @@ -99,9 +103,10 @@ namespace FineUIPro.Web.CQMS.Material Material.PressClass = this.txtPressClass.Text.Trim(); Material.Unit = this.txtUnit.Text.Trim(); Material.Num = Funs.GetNewDecimalOrZero(this.txtNum.Text.Trim()); - Material.ArrivalDate = Funs.GetNewDateTimeOrNow(this.txtArrivalDate.Text.Trim()); + Material.ArrivalDate = Funs.GetNewDateTime(this.txtArrivalDate.Text.Trim()); Material.CompileMan = this.CurrUser.PersonId; Material.CompileDate = DateTime.Now; + Material.Factory = this.txtFactory.Text.Trim(); if (!string.IsNullOrEmpty(MaterialId)) { Material.MaterialId = MaterialId; diff --git a/SGGL/FineUIPro.Web/CQMS/Material/MaterialEdit.aspx.designer.cs b/SGGL/FineUIPro.Web/CQMS/Material/MaterialEdit.aspx.designer.cs index 1edfc69c..d83f3fd2 100644 --- a/SGGL/FineUIPro.Web/CQMS/Material/MaterialEdit.aspx.designer.cs +++ b/SGGL/FineUIPro.Web/CQMS/Material/MaterialEdit.aspx.designer.cs @@ -138,6 +138,15 @@ namespace FineUIPro.Web.CQMS.Material { /// protected global::FineUIPro.DatePicker txtArrivalDate; + /// + /// txtFactory 控件。 + /// + /// + /// 自动生成的字段。 + /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 + /// + protected global::FineUIPro.TextBox txtFactory; + /// /// Toolbar1 控件。 /// diff --git a/SGGL/FineUIPro.Web/CQMS/Material/MaterialIn.aspx.cs b/SGGL/FineUIPro.Web/CQMS/Material/MaterialIn.aspx.cs index 7d8dca86..41af5240 100644 --- a/SGGL/FineUIPro.Web/CQMS/Material/MaterialIn.aspx.cs +++ b/SGGL/FineUIPro.Web/CQMS/Material/MaterialIn.aspx.cs @@ -126,7 +126,7 @@ namespace FineUIPro.Web.CQMS.Material oleDBConn.Close(); oleDBConn.Dispose(); hdCheckResult.Text = "1"; - AddDatasetToSQL(ds.Tables[0], 11); + AddDatasetToSQL(ds.Tables[0], 12); } catch (Exception exc) { @@ -172,22 +172,22 @@ namespace FineUIPro.Web.CQMS.Material if (oldViewInfo == null) { string row0 = pds.Rows[i][0].ToString(); - if (string.IsNullOrEmpty(row0)) - { - result += (i + 2).ToString() + "," + "合同编号" + "," + "此项为必填项!" + "|"; - } + //if (string.IsNullOrEmpty(row0)) + //{ + // result += (i + 2).ToString() + "," + "合同编号" + "," + "此项为必填项!" + "|"; + //} string row1 = pds.Rows[i][1].ToString(); if (string.IsNullOrEmpty(row1)) { - result += (i + 2).ToString() + "," + "供货单位名称" + "," + "此项为必填项!" + "|"; + result += (i + 2).ToString() + "," + "采购单位" + "," + "此项为必填项!" + "|"; } else { var unit = units.FirstOrDefault(x => x.UnitName == row1); if (unit == null) { - result += (i + 2).ToString() + "," + "供货单位名称" + "," + "[" + row1 + "]不存在!" + "|"; + result += (i + 2).ToString() + "," + "采购单位" + "," + "[" + row1 + "]不存在!" + "|"; } } @@ -198,11 +198,14 @@ namespace FineUIPro.Web.CQMS.Material //} //else //{ + if (!string.IsNullOrEmpty(row2)) + { var mainItem = mainItems.FirstOrDefault(x => x.MainItemName == row2); if (mainItem == null) { result += (i + 2).ToString() + "," + "主项名称" + "," + "[" + row2 + "]不存在!" + "|"; } + } //} string row3 = pds.Rows[i][3].ToString(); @@ -211,11 +214,11 @@ namespace FineUIPro.Web.CQMS.Material result += (i + 2).ToString() + "," + "材料名称" + "," + "此项为必填项!" + "|"; } - string row4 = pds.Rows[i][4].ToString(); - if (string.IsNullOrEmpty(row4)) - { - result += (i + 2).ToString() + "," + "规格型号" + "," + "此项为必填项!" + "|"; - } + //string row4 = pds.Rows[i][4].ToString(); + //if (string.IsNullOrEmpty(row4)) + //{ + // result += (i + 2).ToString() + "," + "规格型号" + "," + "此项为必填项!" + "|"; + //} string row9 = pds.Rows[i][9].ToString(); if (!string.IsNullOrEmpty(row9)) @@ -250,6 +253,12 @@ namespace FineUIPro.Web.CQMS.Material //{ // result += (i + 2).ToString() + "," + "到货日期" + "," + "此项为必填项!" + "|"; //} + + string row11 = pds.Rows[i][11].ToString(); + if (string.IsNullOrEmpty(row11)) + { + result += (i + 2).ToString() + "," + "生产厂家" + "," + "此项为必填项!" + "|"; + } } } if (!string.IsNullOrEmpty(result)) @@ -357,7 +366,7 @@ namespace FineUIPro.Web.CQMS.Material oleDBConn.Close(); oleDBConn.Dispose(); - AddDatasetToSQL2(ds.Tables[0], 11); + AddDatasetToSQL2(ds.Tables[0], 12); } catch (Exception ex) { @@ -403,7 +412,10 @@ namespace FineUIPro.Web.CQMS.Material materialCheck.ProjectId = this.CurrUser.LoginProjectId; materialCheck.ContractNo = pds.Rows[i][0].ToString().Trim(); materialCheck.UnitId = units.First(e => e.UnitName == pds.Rows[i][1].ToString().Trim()).UnitId; - materialCheck.MainItemId = mainItems.First(e => e.MainItemName == pds.Rows[i][2].ToString().Trim()).MainItemId; + if (!string.IsNullOrEmpty(pds.Rows[i][2].ToString().Trim())) + { + materialCheck.MainItemId = mainItems.First(e => e.MainItemName == pds.Rows[i][2].ToString().Trim()).MainItemId; + } materialCheck.MaterialName = pds.Rows[i][3].ToString().Trim(); materialCheck.SpecificationAndModel = pds.Rows[i][4].ToString().Trim(); materialCheck.MaterialCode = pds.Rows[i][5].ToString().Trim(); @@ -411,7 +423,8 @@ namespace FineUIPro.Web.CQMS.Material materialCheck.PressClass = pds.Rows[i][7].ToString().Trim(); materialCheck.Unit = pds.Rows[i][8].ToString().Trim(); materialCheck.Num = Funs.GetNewDecimalOrZero(pds.Rows[i][9].ToString().Trim()); - materialCheck.ArrivalDate = Funs.GetNewDateTimeOrNow(pds.Rows[i][10].ToString().Trim()); + materialCheck.ArrivalDate = Funs.GetNewDateTime(pds.Rows[i][10].ToString().Trim()); + materialCheck.Factory = pds.Rows[i][11].ToString().Trim(); materialCheck.CompileMan = this.CurrUser.PersonId; materialCheck.CompileDate = DateTime.Now; BLL.CQMS_MaterialService.AddMaterial(materialCheck); diff --git a/SGGL/FineUIPro.Web/File/Excel/DataIn/材料信息导入模板.xls b/SGGL/FineUIPro.Web/File/Excel/DataIn/材料信息导入模板.xls index fa5414da6e69e8d988a66603feaf57023158be12..378eebfa550c4b3bd3c8275f5685b64a1eb890c8 100644 GIT binary patch delta 1063 zcmZ{kPiWIn9LK-EG-;AHYnxD8hfYh~WuR<@trI3|=TPwAAE>=p7%DrI;Xx2jW2Pv2 z6O>1hx)2 zS!~wlHJdQdFomzc)qk=r11K4)&5kGLp zkBr#%?;e;vm~_JYdJ_1Y<{jS1wu>nBHLwbTd|0 zP>d}Aq;}D#E`I#ay{Wb=Ic5cjZlo-iTW>4gD%v+y_g1nJJ5lRo$DYsw7{GxA%|S zZ8lDy6_sl7@WJbk&)jUhXb~)En3bLLuWdMd)cr}$z}%Yx{=!?BUAHvrJh1M4Uz{ws zb;wq)aR~AKWHe%hojq2>2_(?XN324{&uqjR7w-;n5=nG3k*`C?%1FcpFRtmPBf;c0 z)Xj)f+{afV*>Hhrr13r#FqDkHNBT*J6*gsj zfC)C`c?6`gmk3E?QbS5|ueFeLresJ4lOB@EIgOA~IL_M~R7hJ`_B$WVZd{F}AR(>jtqP4EDrssc=s|i&b5aDsLlHs5lazJ?qBlVp zauTF^DR?M}D~QngaV+$#0X-;q5(Ez(RFL{6%VtB_&cN>e{_nk+|C?dkyVTyL?sdH| z`RnzXztN|5FZb=~Mql31?^7=PqfZGE@|aZ`eU1x37gye{oraH>0QQ1M#4kJ;WG2xv zmRUc8VRX})3`S~oB93l}s5V*iGY-aiAXS9(R-mba=+t3_F^$;zE-<&X)(Wq7=J;$f?KX)(X_ z^KSU5Izj#(ihROfrhy#C`=(KGNkgx#*oe?%+qBEAnEm*jbPuOO2tst8S4xfJANjSsT_by);7=##On_!D- zsOD{nyuBasUD#}#VS2G59yNhL%im{h|NX$b1vRg607+*3>j&T~gGnS9mekSr!^ zNH&wY$7oS*f*Xk`gT}zrN3PyvmCcDF-l$^EgM4+lG3E|D5L}*`7TQ;SlXMr3zqq<3 ToVK~sUFTn4le94V?3(c(^IEjW diff --git a/SGGL/Model/Model.cs b/SGGL/Model/Model.cs index 53ff3e12..f704ab93 100644 --- a/SGGL/Model/Model.cs +++ b/SGGL/Model/Model.cs @@ -73403,7 +73403,7 @@ namespace Model OnCreated(); } - [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_MaterialCode", DbType="NVarChar(15) NOT NULL", CanBeNull=false, IsPrimaryKey=true)] + [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_MaterialCode", DbType="NVarChar(50) NOT NULL", CanBeNull=false, IsPrimaryKey=true)] public string MaterialCode { get @@ -73507,7 +73507,7 @@ namespace Model } } - [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_MaterialDef", DbType="NVarChar(3000)")] + [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_MaterialDef", DbType="NVarChar(MAX)", UpdateCheck=UpdateCheck.Never)] public string MaterialDef { get @@ -78097,7 +78097,7 @@ namespace Model } } - [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_MaterialCode", DbType="NVarChar(15)")] + [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_MaterialCode", DbType="NVarChar(50)")] public string MaterialCode { get @@ -82445,7 +82445,7 @@ namespace Model } } - [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_CanWelderCode", DbType="NVarChar(200)")] + [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_CanWelderCode", DbType="NVarChar(1000)")] public string CanWelderCode { get @@ -121574,6 +121574,8 @@ namespace Model private string _InspectionId; + private string _Factory; + private EntityRef _Base_Project; private EntityRef _Base_Unit; @@ -121616,6 +121618,8 @@ namespace Model partial void OnCompileDateChanged(); partial void OnInspectionIdChanging(string value); partial void OnInspectionIdChanged(); + partial void OnFactoryChanging(string value); + partial void OnFactoryChanged(); #endregion public Material_Material() @@ -121958,6 +121962,26 @@ namespace Model } } + [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_Factory", DbType="NVarChar(100)")] + public string Factory + { + get + { + return this._Factory; + } + set + { + if ((this._Factory != value)) + { + this.OnFactoryChanging(value); + this.SendPropertyChanging(); + this._Factory = value; + this.SendPropertyChanged("Factory"); + this.OnFactoryChanged(); + } + } + } + [global::System.Data.Linq.Mapping.AssociationAttribute(Name="FK_Material_Material_Base_Project", Storage="_Base_Project", ThisKey="ProjectId", OtherKey="ProjectId", IsForeignKey=true)] public Base_Project Base_Project { @@ -234443,7 +234467,7 @@ namespace Model } } - [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_CanWelderCode", DbType="NVarChar(200)")] + [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_CanWelderCode", DbType="NVarChar(1000)")] public string CanWelderCode { get From 2e19b42a4b368ac63146803061263ab9d7d54abb Mon Sep 17 00:00:00 2001 From: gaofei <181547018@qq.com> Date: Thu, 23 Feb 2023 09:37:24 +0800 Subject: [PATCH 2/2] =?UTF-8?q?=E4=BF=AE=E6=94=B9=E6=9D=90=E6=96=99?= =?UTF-8?q?=E6=8A=A5=E9=AA=8C=E6=B5=81=E7=A8=8B?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../CQMS/Material/CQMS_InspectionService.cs | 9 +-- .../CQMS/Material/EquipmentEdit.aspx | 6 +- .../CQMS/Material/EquipmentEdit.aspx.cs | 17 +++--- .../CQMS/Material/EquipmentIn.aspx.cs | 58 ++++++++++--------- .../CQMS/Material/Inspection.aspx.cs | 2 +- .../CQMS/Material/InspectionEdit.aspx.cs | 14 +---- .../CQMS/Material/InspectionView.aspx.cs | 2 +- 7 files changed, 49 insertions(+), 59 deletions(-) diff --git a/SGGL/BLL/CQMS/Material/CQMS_InspectionService.cs b/SGGL/BLL/CQMS/Material/CQMS_InspectionService.cs index 231fc465..0a7351b1 100644 --- a/SGGL/BLL/CQMS/Material/CQMS_InspectionService.cs +++ b/SGGL/BLL/CQMS/Material/CQMS_InspectionService.cs @@ -98,17 +98,10 @@ namespace BLL if (state == Const.Inspection_Compile || state == Const.Inspection_ReCompile) { ListItem[] lis = new ListItem[1]; - lis[0] = new ListItem("总包专业工程师审核", Const.Inspection_Audit1); + lis[0] = new ListItem("总包专业工程师审批", Const.Inspection_Audit1); return lis; } else if (state == Const.Inspection_Audit1) - { - ListItem[] lis = new ListItem[2]; - lis[0] = new ListItem("监理工程师审批", Const.Inspection_Audit2); - lis[1] = new ListItem("重新编制", Const.Inspection_ReCompile); - return lis; - } - else if (state == Const.Inspection_Audit2) { ListItem[] lis = new ListItem[2]; lis[0] = new ListItem("审批完成", Const.Inspection_Complete); diff --git a/SGGL/FineUIPro.Web/CQMS/Material/EquipmentEdit.aspx b/SGGL/FineUIPro.Web/CQMS/Material/EquipmentEdit.aspx index 402e2bf9..0847d20d 100644 --- a/SGGL/FineUIPro.Web/CQMS/Material/EquipmentEdit.aspx +++ b/SGGL/FineUIPro.Web/CQMS/Material/EquipmentEdit.aspx @@ -16,7 +16,7 @@ + MaxLength="70" LabelWidth="100px"> @@ -24,7 +24,7 @@ - + @@ -46,7 +46,7 @@ - diff --git a/SGGL/FineUIPro.Web/CQMS/Material/EquipmentEdit.aspx.cs b/SGGL/FineUIPro.Web/CQMS/Material/EquipmentEdit.aspx.cs index 23dafb55..3fc0a188 100644 --- a/SGGL/FineUIPro.Web/CQMS/Material/EquipmentEdit.aspx.cs +++ b/SGGL/FineUIPro.Web/CQMS/Material/EquipmentEdit.aspx.cs @@ -70,11 +70,11 @@ namespace FineUIPro.Web.CQMS.Material Alert.ShowInTop("请选择供货单位!", MessageBoxIcon.Warning); return; } - if (this.drpMainItem.SelectedValue == BLL.Const._Null) - { - Alert.ShowInTop("请选择主项!", MessageBoxIcon.Warning); - return; - } + //if (this.drpMainItem.SelectedValue == BLL.Const._Null) + //{ + // Alert.ShowInTop("请选择主项!", MessageBoxIcon.Warning); + // return; + //} SaveData(); } else @@ -90,14 +90,17 @@ namespace FineUIPro.Web.CQMS.Material Equipment.ProjectId = this.CurrUser.LoginProjectId; Equipment.ContractNo = this.txtContractNo.Text.Trim(); Equipment.UnitId = this.drpUnit.SelectedValue; - Equipment.MainItemId = this.drpMainItem.SelectedValue; + if (this.drpMainItem.SelectedValue != BLL.Const._Null) + { + Equipment.MainItemId = this.drpMainItem.SelectedValue; + } Equipment.EquipmentName = this.txtEquipmentName.Text.Trim(); Equipment.SpecificationAndModel = this.txtSpecificationAndModel.Text.Trim(); Equipment.EquipmentCode = this.txtEquipmentCode.Text.Trim(); Equipment.PressClass = this.txtPressClass.Text.Trim(); Equipment.Unit = this.txtUnit.Text.Trim(); Equipment.Num = Funs.GetNewDecimalOrZero(this.txtNum.Text.Trim()); - Equipment.ArrivalDate = Funs.GetNewDateTimeOrNow(this.txtArrivalDate.Text.Trim()); + Equipment.ArrivalDate = Funs.GetNewDateTime(this.txtArrivalDate.Text.Trim()); Equipment.CompileMan = this.CurrUser.PersonId; Equipment.CompileDate = DateTime.Now; if (!string.IsNullOrEmpty(EquipmentId)) diff --git a/SGGL/FineUIPro.Web/CQMS/Material/EquipmentIn.aspx.cs b/SGGL/FineUIPro.Web/CQMS/Material/EquipmentIn.aspx.cs index 89e5fe30..074457ae 100644 --- a/SGGL/FineUIPro.Web/CQMS/Material/EquipmentIn.aspx.cs +++ b/SGGL/FineUIPro.Web/CQMS/Material/EquipmentIn.aspx.cs @@ -171,11 +171,11 @@ namespace FineUIPro.Web.CQMS.Material && x.EquipmentName == pds.Rows[i][3].ToString() && x.EquipmentCode == pds.Rows[i][5].ToString() && x.ArrivalDate == Funs.GetNewDateTime(pds.Rows[i][9].ToString())); if (oldViewInfo == null) { - string row0 = pds.Rows[i][0].ToString(); - if (string.IsNullOrEmpty(row0)) - { - result += (i + 2).ToString() + "," + "合同编号" + "," + "此项为必填项!" + "|"; - } + //string row0 = pds.Rows[i][0].ToString(); + //if (string.IsNullOrEmpty(row0)) + //{ + // result += (i + 2).ToString() + "," + "合同编号" + "," + "此项为必填项!" + "|"; + //} string row1 = pds.Rows[i][1].ToString(); if (string.IsNullOrEmpty(row1)) @@ -192,12 +192,14 @@ namespace FineUIPro.Web.CQMS.Material } string row2 = pds.Rows[i][2].ToString(); - if (string.IsNullOrEmpty(row2)) - { - result += (i + 2).ToString() + "," + "主项名称" + "," + "此项为必填项!" + "|"; - } - else - { + //if (string.IsNullOrEmpty(row2)) + //{ + // result += (i + 2).ToString() + "," + "主项名称" + "," + "此项为必填项!" + "|"; + //} + //else + //{ + if (!string.IsNullOrEmpty(row2)) + { var mainItem = mainItems.FirstOrDefault(x => x.MainItemName == row2); if (mainItem == null) { @@ -240,22 +242,22 @@ namespace FineUIPro.Web.CQMS.Material result += (i + 2).ToString() + "," + "数量" + "," + "此项为必填项!" + "|"; } - string row9 = pds.Rows[i][9].ToString(); - if (!string.IsNullOrEmpty(row9)) - { - try - { - DateTime d = Convert.ToDateTime(row9.Trim()); - } - catch (Exception) - { - result += (i + 2).ToString() + "," + "到货日期" + "," + "[" + row9 + "]格式错误!" + "|"; - } - } - else - { - result += (i + 2).ToString() + "," + "到货日期" + "," + "此项为必填项!" + "|"; - } + //string row9 = pds.Rows[i][9].ToString(); + //if (!string.IsNullOrEmpty(row9)) + //{ + // try + // { + // DateTime d = Convert.ToDateTime(row9.Trim()); + // } + // catch (Exception) + // { + // result += (i + 2).ToString() + "," + "到货日期" + "," + "[" + row9 + "]格式错误!" + "|"; + // } + //} + //else + //{ + // result += (i + 2).ToString() + "," + "到货日期" + "," + "此项为必填项!" + "|"; + //} } } if (!string.IsNullOrEmpty(result)) @@ -416,7 +418,7 @@ namespace FineUIPro.Web.CQMS.Material equipment.PressClass = pds.Rows[i][6].ToString().Trim(); equipment.Unit = pds.Rows[i][7].ToString().Trim(); equipment.Num = Funs.GetNewDecimalOrZero(pds.Rows[i][8].ToString().Trim()); - equipment.ArrivalDate = Funs.GetNewDateTimeOrNow(pds.Rows[i][9].ToString().Trim()); + equipment.ArrivalDate = Funs.GetNewDateTime(pds.Rows[i][9].ToString().Trim()); equipment.CompileMan = this.CurrUser.PersonId; equipment.CompileDate = DateTime.Now; BLL.CQMS_EquipmentService.AddEquipment(equipment); diff --git a/SGGL/FineUIPro.Web/CQMS/Material/Inspection.aspx.cs b/SGGL/FineUIPro.Web/CQMS/Material/Inspection.aspx.cs index 2b079e56..704c59f7 100644 --- a/SGGL/FineUIPro.Web/CQMS/Material/Inspection.aspx.cs +++ b/SGGL/FineUIPro.Web/CQMS/Material/Inspection.aspx.cs @@ -320,7 +320,7 @@ namespace FineUIPro.Web.CQMS.Material } else if (state.ToString() == BLL.Const.Inspection_Audit1) { - return "总包专业工程师审核"; + return "总包专业工程师审批"; } else if (state.ToString() == BLL.Const.Inspection_Audit2) { diff --git a/SGGL/FineUIPro.Web/CQMS/Material/InspectionEdit.aspx.cs b/SGGL/FineUIPro.Web/CQMS/Material/InspectionEdit.aspx.cs index 376752ee..de72a83b 100644 --- a/SGGL/FineUIPro.Web/CQMS/Material/InspectionEdit.aspx.cs +++ b/SGGL/FineUIPro.Web/CQMS/Material/InspectionEdit.aspx.cs @@ -218,7 +218,7 @@ namespace FineUIPro.Web.CQMS.Material } else if (state.ToString() == BLL.Const.Inspection_Audit1) { - return "总包专业工程师审核"; + return "总包专业工程师审批"; } else if (state.ToString() == BLL.Const.Inspection_Audit2) { @@ -256,20 +256,12 @@ namespace FineUIPro.Web.CQMS.Material string State = BLL.CQMS_InspectionService.GetInspectionByInspectionId(this.InspectionId).State; if (this.RadioButtonList1.SelectedValue.Equals("true")) { - if (State == Const.Inspection_Audit2) + if (State == Const.Inspection_Audit1) { this.drpHandleMan.Enabled = false; } this.drpHandleType.SelectedIndex = 0; - if (State == Const.Inspection_Audit1) - { - this.drpHandleMan.SelectedIndex = 2; - } - else - { - this.drpHandleMan.SelectedIndex = 0; - } - + this.drpHandleMan.SelectedIndex = 0; } else { diff --git a/SGGL/FineUIPro.Web/CQMS/Material/InspectionView.aspx.cs b/SGGL/FineUIPro.Web/CQMS/Material/InspectionView.aspx.cs index 91a2113d..8272adb5 100644 --- a/SGGL/FineUIPro.Web/CQMS/Material/InspectionView.aspx.cs +++ b/SGGL/FineUIPro.Web/CQMS/Material/InspectionView.aspx.cs @@ -175,7 +175,7 @@ namespace FineUIPro.Web.CQMS.Material } else if (state.ToString() == BLL.Const.Inspection_Audit1) { - return "总包专业工程师审核"; + return "总包专业工程师审批"; } else if (state.ToString() == BLL.Const.Inspection_Audit2) {