From 2ec46c24c2f4adf1d431e356a7ca4ade0a9ed52c Mon Sep 17 00:00:00 2001 From: yxj <yxj@hz-kingdee.com> Date: 星期三, 08 五月 2024 14:21:26 +0800 Subject: [PATCH] Merge branch 'master' of http://101.37.171.70:10101/r/MES-WEB-API --- DAL/质检管理/ClsQC_FirstPieceCheckBill.cs | 6 PayM/bin/x86/Debug/SQLHelper.dll | 0 PayM/obj/x86/Debug/PayM.csproj.GenerateResource.cache | 0 PayM/obj/x86/Debug/PayM.csproj.ResolveComReference.cache | 0 WebAPI/Controllers/QC_ManagementController.cs | 120 ++ PayM/bin/x86/Debug/Pub_Control.pdb | 0 WebAPI/Models/CheckItem.cs | 12 DAL/生产管理/模具管理/ClsSc_MouldDotCheckRuleBill.cs | 22 WebAPI/DLL/ClsQC_PatrolProcCheckBill.cs | 6 WebAPI/Models/ClsGy_DotCheck.cs | 1 PayM/bin/x86/Debug/Pub_Class.pdb | 0 Model/销售管理/ClsXs_SeOrderBillSub.cs | 3 WebAPI/Controllers/基础资料/基础资料/Gy_DotCheckItemClassController.cs | 379 ++++++++ PayM/bin/x86/Debug/Pub_Control.dll | 0 DAL/生产管理/模具管理/ClsSc_MouldDotCheckPlanBill.cs | 28 WebAPI/Models/ClsGy_Material_Model.cs | 1 WebAPI/Controllers/基础资料/基础资料/Gy_DotCheckItemMethodController.cs | 379 ++++++++ PayM/bin/x86/Debug/Pub_Class.dll | 0 PayM/bin/x86/Debug/SQLHelper.pdb | 0 LMES/bin/x86/Debug.zip | 0 Model/基础资料/基础资料/ClsGy_DotCheckItemClass_Model.cs | 11 Model/生产管理/设备管理/ClsSb_EquipDotCheckPlanBillSub.cs | 4 PayM/bin/x86/Debug/Model.pdb | 0 Model/生产管理/模具管理/ClsSc_MouldDotCheckPlanBillSub.cs | 3 PayM/bin/x86/Debug/BLL.dll | 0 WebAPI/Controllers/SBGL/Sb_EquipDotCheckPlanBillController.cs | 6 WebAPI/Controllers/CJGL/Cj_StationOutBillController.cs | 13 WebAPI/Controllers/Sc_MouldRepairInBillListController.cs | 9 WebAPI/Controllers/WebAPIController.cs | 108 ++ WarM/条码打印/Gy_PackBarCodeBill_automaticallyByPLC.cs | 363 ++++++- PayM/obj/x86/Debug/PayM.csproj.AssemblyReference.cache | 0 PayM/bin/x86/Debug/BLL.pdb | 0 WebAPI/Controllers/项目管理/工作任务/PM_WorkTaskBillController.cs | 7 DAL/基础资料/公用基础资料/ClsGy_DotCheckItemMethod_Ctl.cs | 98 ++ WebAPI/Controllers/仓存管理/调拨盘点/Kf_MoveStockRequestBillController.cs | 433 +++++++++ WebAPI/Controllers/XSGL/Xs_ReceivableBillController.cs | 30 WebAPI/Controllers/XSGL/Xs_SeOrderBillController.cs | 6 WebAPI/ListModels.cs | 24 DAL/DAL.csproj | 2 DAL/销售管理/ClsXs_ReceivableBill.cs | 98 +- WebAPI/Controllers/MJGL/Sc_MouldDotCheckRuleBillController.cs | 3 Model/基础资料/其他基础资料/ClsGy_QCCheckProjectSub.cs | 37 WebAPI/DLL/ClsSb_EquipDotCheckRuleBill.cs | 8 WebAPI/Controllers/XSGL/Xs_SeOutStockBillController.cs | 34 WebAPI/WebAPI.csproj | 2 PayM/bin/x86/Debug/DBUtility.dll | 0 Model/生产管理/模具管理/ClsSc_MouldDotCheckRuleBillSub.cs | 3 WebAPI/Models/StationBill.cs | 5 PayM/bin/x86/Debug/DAL.dll | 0 WarM/条码打印/Gy_PackBarCodeBill_automaticallyByPLC.Designer.cs | 38 PayM/bin/x86/Debug/DBUtility.pdb | 0 Model/Model.csproj | 2 Model/基础资料/基础资料/ClsGy_DotCheckItemMethod_Model.cs | 11 Model/质检管理/ClsQC_PatrolProcCheckBillMain.cs | 2 WebAPI/Controllers/基础资料/基础资料/Gy_DotCheckBillController.cs | 10 WarM/条码打印/Gy_BarCodeBill_automaticallyByPLC_New.cs | 68 + DAL/质检管理/ClsQC_ProcessCheckBill.cs | 6 PayM/obj/x86/Debug/PayM.pdb | 0 WebAPI/Models/ClsSb_EquipDotCheckRuleBillSub.cs | 3 DAL/销售管理/ClsXs_SeOrderBill.cs | 19 WebAPI/Controllers/项目管理/工程项目/PM_ProjectBillController.cs | 22 WebAPI/Controllers/品质管理/首件检验单/QC_FirstPieceCheckBillController.cs | 2 PayM/obj/x86/Debug/PayM.dll | 0 PayM/bin/x86/Debug/Model.dll | 0 WarM/条码打印/Gy_BarCodeBill_automaticallyByPLC_New.designer.cs | 25 DAL/基础资料/其他基础资料/ClsGy_QCCheckProjectMain.cs | 37 Model/质检管理/ClsQC_ProcessCheckBillMain.cs | 3 Model/质检管理/ClsQC_FirstPieceCheckBillMain.cs | 2 DAL/生产管理/设备管理/ClsSb_EquipDotCheckPlanBill.cs | 14 DAL/基础资料/公用基础资料/ClsGy_DotCheckItemClass_Ctl.cs | 97 ++ WebAPI/Controllers/BaseSet/Gy_CheckItemController.cs | 181 +++ Model/基础资料/其他基础资料/ClsGy_QCCheckProjectMain.cs | 1 PayM/bin/x86/Debug/DAL.pdb | 0 PayM/bin/x86/Debug/PayM.dll | 0 PayM/bin/x86/Debug/PayM.pdb | 0 WebAPI/Controllers/品质管理/工序检验单/QC_ProcessCheckBillController.cs | 2 WebAPI/DLL/ClsGy_Material_Ctl.cs | 5 77 files changed, 2,550 insertions(+), 264 deletions(-) diff --git a/DAL/DAL.csproj b/DAL/DAL.csproj index 3f645de..ea11ba7 100644 --- a/DAL/DAL.csproj +++ b/DAL/DAL.csproj @@ -108,8 +108,10 @@ <Compile Include="鍩虹璧勬枡\鍏敤鍩虹璧勬枡\ClsGy_CardStatus_Ctl.cs" /> <Compile Include="鍩虹璧勬枡\鍏敤鍩虹璧勬枡\ClsGy_CardAddress_Ctl.cs" /> <Compile Include="鍩虹璧勬枡\鍏敤鍩虹璧勬枡\ClsGy_CustLocation_Ctl.cs" /> + <Compile Include="鍩虹璧勬枡\鍏敤鍩虹璧勬枡\ClsGy_DotCheckItemMethod_Ctl.cs" /> <Compile Include="鍩虹璧勬枡\鍏敤鍩虹璧勬枡\ClsGy_EquipStatus_Ctl.cs" /> <Compile Include="鍩虹璧勬枡\鍏敤鍩虹璧勬枡\ClsGy_CardType_Ctl.cs" /> + <Compile Include="鍩虹璧勬枡\鍏敤鍩虹璧勬枡\ClsGy_DotCheckItemClass_Ctl.cs" /> <Compile Include="鍩虹璧勬枡\鍏敤鍩虹璧勬枡\ClsGy_MouldStatus_Ctl.cs" /> <Compile Include="鍩虹璧勬枡\鍏敤鍩虹璧勬枡\ClsGy_Operator_Ctl.cs" /> <Compile Include="鍩虹璧勬枡\鍏敤鍩虹璧勬枡\ClsGy_RateType_Ctl.cs" /> diff --git "a/DAL/\345\237\272\347\241\200\350\265\204\346\226\231/\345\205\254\347\224\250\345\237\272\347\241\200\350\265\204\346\226\231/ClsGy_DotCheckItemClass_Ctl.cs" "b/DAL/\345\237\272\347\241\200\350\265\204\346\226\231/\345\205\254\347\224\250\345\237\272\347\241\200\350\265\204\346\226\231/ClsGy_DotCheckItemClass_Ctl.cs" new file mode 100644 index 0000000..0b3d5f8 --- /dev/null +++ "b/DAL/\345\237\272\347\241\200\350\265\204\346\226\231/\345\205\254\347\224\250\345\237\272\347\241\200\350\265\204\346\226\231/ClsGy_DotCheckItemClass_Ctl.cs" @@ -0,0 +1,97 @@ +锘縰sing System; +using System.Collections.Generic; +using System.Text; +using System.Data; + +namespace DAL +{ + public class ClsGy_DotCheckItemClass_Ctl:DBUtility.ClsGy_Base_Ctl + { + SQLHelper.ClsCN oCn = new SQLHelper.ClsCN(); + //鍘熶唬鐮� 鐢ㄤ簬 鏇挎崲瀛愰」鐩� + public string HOldNumber; + public Model.ClsGy_DotCheckItemClass_Model oModel = new Model.ClsGy_DotCheckItemClass_Model(); + //鏂板 + public override bool AddNew() + { + try + { + oCn.BeginTran(); + oCn.RunProc("Insert into Gy_DotCheckItemClass (" + + "HNumber,HName,HHelpCode,HShortNumber,HParentID" + + ",HLevel,HEndFlag,HStopflag,HRemark" + + ",HMakeTime,HMakeEmp,HCREATEORGID,HUSEORGID) " + + " Values('" + oModel.HNumber + "','" + oModel.HName + "','" + oModel.HHelpCode + "','" + oModel.HShortNumber + "'," + oModel.HParentID.ToString() + + ", " + oModel.HLevel.ToString() + "," + Convert.ToString(oModel.HEndFlag ? 1 : 0) + "," + Convert.ToString(oModel.HStopflag ? 1 : 0) + ",'" + oModel.HRemark + "',getdate()" + ",'" + oModel.HMakeEmp + "'," + oModel.HCREATEORGID + "," + oModel.HUSEORGID + ")", ref DBUtility.ClsPub.sExeReturnInfo); + //淇敼涓婄骇涓洪潪鏈骇浠g爜 + oCn.RunProc("Update " + MvarItemKey + " set HEndflag=0 where HItemID=" + oModel.HParentID, ref DBUtility.ClsPub.sExeReturnInfo); + oCn.Commit(); + return true; + } + catch (Exception e) + { + oCn.RollBack(); + throw (e); + } + } + + //淇敼 + public override bool ModifyByID(Int64 sItemID) + { + try + { + oCn.BeginTran(); + oCn.RunProc("Update " + MvarItemKey + " set " + + " HNumber='" + oModel.HNumber + "'" + + ",HName='" + oModel.HName + "'" + + ",HShortNumber='" + oModel.HShortNumber + "'" + + ",HParentID=" + oModel.HParentID.ToString() + + ",HLevel=" + oModel.HLevel.ToString() + + ",HEndflag=" + Convert.ToString(oModel.HEndFlag ? 1 : 0) + + ",HStopflag=" + Convert.ToString(oModel.HStopflag ? 1 : 0) + + ",HRemark= '" + oModel.HRemark + "'" + + ",HHelpCode='" + oModel.HHelpCode + "'" + + " Where HItemID=" + sItemID, ref DBUtility.ClsPub.sExeReturnInfo); + //淇敼瀛愰」鐩唬鐮� + oCn.RunProc("exec h_p_Gy_UpdateNumber '" + MvarItemKey + "','" + oModel.HNumber + ".','" + this.HOldNumber + ".'", ref DBUtility.ClsPub.sExeReturnInfo); + //灏嗕笂绾� 涓洪潪鏈骇 + oCn.RunProc("Update " + MvarItemKey + " set HEndflag=0 where HItemID=" + oModel.HParentID, ref DBUtility.ClsPub.sExeReturnInfo); + // + oCn.Commit(); + return true; + } + catch (Exception e) + { + oCn.RollBack(); + throw (e); + } + } + //鏍规嵁浠g爜鍒ゆ柇淇℃伅 + public override bool HavParentCode(string sCode, Int64 sItemID) + { + DataSet DS; + try + { + DS = oCn.RunProcReturn("Select * from " + MvarItemKey + " Where HStopflag=0 and HNumber='" + sCode + "' and HItemID<>" + sItemID, MvarItemKey, ref Pub_Class.ClsPub.sExeReturnInfo); + if (DS.Tables[0].Rows.Count == 0) + return false; + else + { + oModel.HItemID = Convert.ToInt64(DS.Tables[0].Rows[0]["HItemID"]); + return true; + } + } + catch (Exception e) + { + throw (e); + } + } + //鏋勯�犲嚱鏁� + public ClsGy_DotCheckItemClass_Ctl() + { + MvarItemKey = "Gy_DotCheckItemClass"; + MvarReportTitle = "鐐规椤圭洰鍒嗙被"; + oModel = new Model.ClsGy_DotCheckItemClass_Model(); + } + } +} diff --git "a/DAL/\345\237\272\347\241\200\350\265\204\346\226\231/\345\205\254\347\224\250\345\237\272\347\241\200\350\265\204\346\226\231/ClsGy_DotCheckItemMethod_Ctl.cs" "b/DAL/\345\237\272\347\241\200\350\265\204\346\226\231/\345\205\254\347\224\250\345\237\272\347\241\200\350\265\204\346\226\231/ClsGy_DotCheckItemMethod_Ctl.cs" new file mode 100644 index 0000000..edca622 --- /dev/null +++ "b/DAL/\345\237\272\347\241\200\350\265\204\346\226\231/\345\205\254\347\224\250\345\237\272\347\241\200\350\265\204\346\226\231/ClsGy_DotCheckItemMethod_Ctl.cs" @@ -0,0 +1,98 @@ +锘縰sing System; +using System.Collections.Generic; +using System.Text; +using System.Data; + +namespace DAL +{ + public class ClsGy_DotCheckItemMethod_Ctl:DBUtility.ClsGy_Base_Ctl + { + SQLHelper.ClsCN oCn = new SQLHelper.ClsCN(); + //鍘熶唬鐮� 鐢ㄤ簬 鏇挎崲瀛愰」鐩� + public string HOldNumber; + public Model.ClsGy_DotCheckItemMethod_Model oModel = new Model.ClsGy_DotCheckItemMethod_Model(); + //鏂板 + public override bool AddNew() + { + + try + { + oCn.BeginTran(); + oCn.RunProc("Insert into Gy_DotCheckItemMethod (" + + "HNumber,HName,HHelpCode,HShortNumber,HParentID" + + ",HLevel,HEndFlag,HStopflag,HRemark" + + ",HMakeTime,HMakeEmp,HCREATEORGID,HUSEORGID) " + + " Values('" + oModel.HNumber + "','" + oModel.HName + "','" + oModel.HHelpCode + "','" + oModel.HShortNumber + "'," + oModel.HParentID.ToString() + + ", " + oModel.HLevel.ToString() + "," + Convert.ToString(oModel.HEndFlag ? 1 : 0) + "," + Convert.ToString(oModel.HStopflag ? 1 : 0) + ",'" + oModel.HRemark + "','" + oModel.HMakeTime + "','" + oModel.HMakeEmp + "'," + oModel.HCREATEORGID + "," + oModel.HUSEORGID + ")", ref DBUtility.ClsPub.sExeReturnInfo); + //淇敼涓婄骇涓洪潪鏈骇浠g爜 + oCn.RunProc("Update " + MvarItemKey + " set HEndflag=0 where HItemID=" + oModel.HParentID, ref DBUtility.ClsPub.sExeReturnInfo); + oCn.Commit(); + return true; + } + catch (Exception e) + { + oCn.RollBack(); + throw (e); + } + } + + //淇敼 + public override bool ModifyByID(Int64 sItemID) + { + try + { + oCn.BeginTran(); + oCn.RunProc("Update " + MvarItemKey + " set " + + " HNumber='" + oModel.HNumber + "'" + + ",HName='" + oModel.HName + "'" + + ",HShortNumber='" + oModel.HShortNumber + "'" + + ",HParentID=" + oModel.HParentID.ToString() + + ",HLevel=" + oModel.HLevel.ToString() + + ",HEndflag=" + Convert.ToString(oModel.HEndFlag ? 1 : 0) + + ",HStopflag=" + Convert.ToString(oModel.HStopflag ? 1 : 0) + + ",HRemark= '" + oModel.HRemark + "'" + + ",HHelpCode='" + oModel.HHelpCode + "'" + + " Where HItemID=" + sItemID, ref DBUtility.ClsPub.sExeReturnInfo); + //淇敼瀛愰」鐩唬鐮� + oCn.RunProc("exec h_p_Gy_UpdateNumber '" + MvarItemKey + "','" + oModel.HNumber + ".','" + this.HOldNumber + ".'", ref DBUtility.ClsPub.sExeReturnInfo); + //灏嗕笂绾� 涓洪潪鏈骇 + oCn.RunProc("Update " + MvarItemKey + " set HEndflag=0 where HItemID=" + oModel.HParentID, ref DBUtility.ClsPub.sExeReturnInfo); + // + oCn.Commit(); + return true; + } + catch (Exception e) + { + oCn.RollBack(); + throw (e); + } + } + //鏍规嵁浠g爜鍒ゆ柇淇℃伅 + public override bool HavParentCode(string sCode, Int64 sItemID) + { + DataSet DS; + try + { + DS = oCn.RunProcReturn("Select * from " + MvarItemKey + " Where HStopflag=0 and HNumber='" + sCode + "' and HItemID<>" + sItemID, MvarItemKey, ref Pub_Class.ClsPub.sExeReturnInfo); + if (DS.Tables[0].Rows.Count == 0) + return false; + else + { + oModel.HItemID = Convert.ToInt64(DS.Tables[0].Rows[0]["HItemID"]); + return true; + } + } + catch (Exception e) + { + throw (e); + } + } + //鏋勯�犲嚱鏁� + public ClsGy_DotCheckItemMethod_Ctl() + { + MvarItemKey = "Gy_DotCheckItemMethod"; + MvarReportTitle = "鐐规鏂规硶"; + oModel = new Model.ClsGy_DotCheckItemMethod_Model(); + } + } +} diff --git "a/DAL/\345\237\272\347\241\200\350\265\204\346\226\231/\345\205\266\344\273\226\345\237\272\347\241\200\350\265\204\346\226\231/ClsGy_QCCheckProjectMain.cs" "b/DAL/\345\237\272\347\241\200\350\265\204\346\226\231/\345\205\266\344\273\226\345\237\272\347\241\200\350\265\204\346\226\231/ClsGy_QCCheckProjectMain.cs" index be93e06..86b90bd 100644 --- "a/DAL/\345\237\272\347\241\200\350\265\204\346\226\231/\345\205\266\344\273\226\345\237\272\347\241\200\350\265\204\346\226\231/ClsGy_QCCheckProjectMain.cs" +++ "b/DAL/\345\237\272\347\241\200\350\265\204\346\226\231/\345\205\266\344\273\226\345\237\272\347\241\200\350\265\204\346\226\231/ClsGy_QCCheckProjectMain.cs" @@ -67,9 +67,10 @@ ",HMaterTypeID=" + omodel.HMaterTypeID.ToString() + ",HUnitID=" + omodel.HUnitID.ToString() + ",HUnitNumber='" + omodel.HUnitNumber + "'" + - ",HStandard=" + Convert.ToString(omodel.HStandard ? 1 : 0) + + ",HStandard=" + Convert.ToString(omodel.HStandard == false ? 0 : 1) + ",HProcID=" + omodel.HProcID.ToString() + ",HDeptID=" + omodel.HDeptID.ToString() + + ",HSampleSchemeID=" + omodel.HSampleSchemeID.ToString() + " where HInterID=" + lngBillKey.ToString()); //鍒犻櫎鍏宠仈 DeleteRelation(ref sReturn, lngBillKey); @@ -84,11 +85,26 @@ ",HEntryCloseDate,HCloseType,HRemark,HSourceInterID" + ",HSourceEntryID,HSourceBillNo,HSourceBillType,HRelationQty,HRelationMoney" + ",HPrjNo,HQCCheckItemID,HQCStd,HQCStdMax,HQCUnit" + + + ",HQCTool,HAnalysisMethod,HDefectLevel,HDestructInspect,HKeyInspect,HQualityStdID" + + ",HInspectMethodID,HInspectInstruMentID,HInspectBasisID,HSampleSchemeID,HStatus,HCompareSymbol" + + ",HTargetVal,HUpLimit,HDownLimit,HUpOffSet,HDownOffSet,HTargetValKey,HUpLimitKey" + + ",HDownLimitKey,HUpOffSetKey,HDownOffSetKey,HTargetValQ,HUpLimitQ,HDownLimitQ" + + ",HUpOffSetQ,HDownOffSetQ,HTargetValB,HUpLimitB,HDownLimitB,HUpOffSetB" + + ",HDownOffSetB,HTargetValTxt,HUpLimitTxt,HDownLimitTxt,HUpOffSetTxt,HDownOffSetTxt" + ") values(" + omodel.HInterID.ToString() + ",'" + oSub.HBillNo_bak + "'," + oSub.HEntryID.ToString() + ",'" + oSub.HCloseMan + "'" + ",getdate()," + Convert.ToString(oSub.HCloseType ? 1 : 0) + ",'" + oSub.HRemark + "'," + oSub.HSourceInterID.ToString() + "," + oSub.HSourceEntryID.ToString() + ",'" + oSub.HSourceBillNo + "','" + oSub.HSourceBillType + "'," + oSub.HRelationQty.ToString() + "," + oSub.HRelationMoney.ToString() + "," + oSub.HPrjNo.ToString() + "," + oSub.HQCCheckItemID.ToString() + ",'" + oSub.HQCStd + "','" + oSub.HQCStdMax + "','" + oSub.HQCUnit + "'" + + ",'" + oSub.HQCTool + "','" + oSub.HAnalysisMethod + "','" + oSub.HDefectLevel + "'," + oSub.HDestructInspect + "," + oSub.HKeyInspect + + "," + oSub.HQualityStdID + "," + oSub.HInspectMethodID + "," + oSub.HInspectInstruMentID + "," + oSub.HInspectBasisID + "," + oSub.HSampleSchemeID + + ",'" + oSub.HStatus + "','" + oSub.HCompareSymbol + "','" + oSub.HTargetVal + "','" + oSub.HUpLimit + "','" + oSub.HDownLimit + + "','" + oSub.HUpLimit + "','" + oSub.HDownOffSet + "','" + oSub.HTargetValKey + "','" + oSub.HUpLimitKey + "','" + oSub.HDownLimitKey + + "','" + oSub.HUpOffSetKey + "','" + oSub.HDownOffSetKey + "'," + oSub.HTargetValQ + "," + oSub.HUpLimitQ + "," + oSub.HDownLimitQ + + "," + oSub.HUpOffSetQ + "," + oSub.HDownOffSetQ + "," + oSub.HTargetValB + "," + oSub.HUpLimitB + "," + oSub.HDownLimitB + + "," + oSub.HUpOffSetB + "," + oSub.HDownOffSetB + ",'" + oSub.HTargetValTxt + "','" + oSub.HUpLimitTxt + "','" + oSub.HDownLimitTxt + + "','" + oSub.HUpOffSetTxt + "','" + oSub.HDownOffSetTxt + "'" + ") "); } @@ -128,13 +144,13 @@ "(HBillType,HBillSubType,HInterID,HBillNo,HBillStatus,HDate,HMaker,HMakeDate" + ",HYear,HPeriod,HRemark" + ",HMaterID,HName,HMaterNumber,HMaterTypeID,HUnitID" + - ",HUnitNumber,HStandard,HProcID,HDeptID" + + ",HUnitNumber,HStandard,HProcID,HDeptID,HSampleSchemeID" + ") " + " values('" + this.BillType + "','" + this.HBillSubType + "'," + omodel.HInterID.ToString() + ",'" + omodel.HBillNo + "'," + omodel.HBillStatus.ToString() + ",'" + omodel.HDate + "','" + DBUtility.ClsPub.CurUserName + "',getdate()" + "," + omodel.HYear.ToString() + "," + omodel.HPeriod.ToString() + ",'" + omodel.HRemark + "'"+ "," + omodel.HMaterID.ToString() + ",'" + omodel.HName + "','" + omodel.HMaterNumber + "'," + omodel.HMaterTypeID.ToString() + "," + omodel.HUnitID.ToString() + ",'" + omodel.HUnitNumber + "', " + Convert.ToString(omodel.HStandard ? 1 : 0) + "," + omodel.HProcID.ToString() + "," + omodel.HDeptID.ToString() + - ") "); + "," + omodel.HSampleSchemeID + ") "); //鎻掑叆瀛愯〃 foreach (Model.ClsGy_QCCheckProjectSub oSub in DetailColl) { @@ -143,11 +159,26 @@ ",HEntryCloseDate,HCloseType,HRemark,HSourceInterID" + ",HSourceEntryID,HSourceBillNo,HSourceBillType,HRelationQty,HRelationMoney" + ",HPrjNo,HQCCheckItemID,HQCStd,HQCStdMax,HQCUnit" + + + ",HQCTool,HAnalysisMethod,HDefectLevel,HDestructInspect,HKeyInspect,HQualityStdID" + + ",HInspectMethodID,HInspectInstruMentID,HInspectBasisID,HSampleSchemeID,HStatus,HCompareSymbol" + + ",HTargetVal,HUpLimit,HDownLimit,HUpOffSet,HDownOffSet,HTargetValKey,HUpLimitKey" + + ",HDownLimitKey,HUpOffSetKey,HDownOffSetKey,HTargetValQ,HUpLimitQ,HDownLimitQ" + + ",HUpOffSetQ,HDownOffSetQ,HTargetValB,HUpLimitB,HDownLimitB,HUpOffSetB" + + ",HDownOffSetB,HTargetValTxt,HUpLimitTxt,HDownLimitTxt,HUpOffSetTxt,HDownOffSetTxt" + ") values(" + omodel.HInterID.ToString() + ",'" + oSub.HBillNo_bak + "'," + oSub.HEntryID.ToString() + ",'" + oSub.HCloseMan + "'" + ",getdate()," + Convert.ToString(oSub.HCloseType ? 1 : 0) + ",'" + oSub.HRemark + "'," + oSub.HSourceInterID.ToString() + "," + oSub.HSourceEntryID.ToString() + ",'" + oSub.HSourceBillNo + "','" + oSub.HSourceBillType + "'," + oSub.HRelationQty.ToString() + "," + oSub.HRelationMoney.ToString() + "," + oSub.HPrjNo.ToString() + "," + oSub.HQCCheckItemID.ToString() + ",'" + oSub.HQCStd + "','" + oSub.HQCStdMax + "','" + oSub.HQCUnit + "'" + + ",'" + oSub.HQCTool + "','" + oSub.HAnalysisMethod + "','" + oSub.HDefectLevel + "'," + oSub.HDestructInspect + "," + oSub.HKeyInspect + + "," + oSub.HQualityStdID + "," + oSub.HInspectMethodID + "," + oSub.HInspectInstruMentID + "," + oSub.HInspectBasisID + "," + oSub.HSampleSchemeID + + ",'" + oSub.HStatus + "','" + oSub.HCompareSymbol + "','" + oSub.HTargetVal + "','" + oSub.HUpLimit + "','" + oSub.HDownLimit + + "','" + oSub.HUpLimit + "','" + oSub.HDownOffSet + "','" + oSub.HTargetValKey + "','" + oSub.HUpLimitKey + "','" + oSub.HDownLimitKey + + "','" + oSub.HUpOffSetKey + "','" + oSub.HDownOffSetKey + "'," + oSub.HTargetValQ + "," + oSub.HUpLimitQ + "," + oSub.HDownLimitQ + + "," + oSub.HUpOffSetQ + "," + oSub.HDownOffSetQ + "," + oSub.HTargetValB + "," + oSub.HUpLimitB + "," + oSub.HDownLimitB + + "," + oSub.HUpOffSetB + "," + oSub.HDownOffSetB + ",'" + oSub.HTargetValTxt + "','" + oSub.HUpLimitTxt + "','" + oSub.HDownLimitTxt + + "','" + oSub.HUpOffSetTxt + "','" + oSub.HDownOffSetTxt + "'" + ") "); } diff --git "a/DAL/\347\224\237\344\272\247\347\256\241\347\220\206/\346\250\241\345\205\267\347\256\241\347\220\206/ClsSc_MouldDotCheckPlanBill.cs" "b/DAL/\347\224\237\344\272\247\347\256\241\347\220\206/\346\250\241\345\205\267\347\256\241\347\220\206/ClsSc_MouldDotCheckPlanBill.cs" index ccd31ec..8e34344 100644 --- "a/DAL/\347\224\237\344\272\247\347\256\241\347\220\206/\346\250\241\345\205\267\347\256\241\347\220\206/ClsSc_MouldDotCheckPlanBill.cs" +++ "b/DAL/\347\224\237\344\272\247\347\256\241\347\220\206/\346\250\241\345\205\267\347\256\241\347\220\206/ClsSc_MouldDotCheckPlanBill.cs" @@ -73,18 +73,19 @@ foreach (Model.ClsSc_MouldDotCheckPlanBillSub oSub in DetailColl) { oCn.RunProc("Insert into Sc_MouldDotCheckPlanBillSub " + - " (HInterID,HEntryID" + - ",HManagerID"+ - ",HDotCheckItem,HDotCheckItemID,HDotCheckPart,HClaim" + - ",HCloseMan,HCloseType,HRemark" + - ",HSourceInterID,HSourceEntryID,HSourceBillNo,HSourceBillType,HRelationQty,HRelationMoney" + - ") values(" - + omodel.HInterID.ToString() + "," + oSub.HEntryID.ToString() + - "," + oSub.HManagerID.ToString() + - ",'" + oSub.HDotCheckItem +"'," + oSub.HDotCheckItemID + ",'" + oSub.HDotCheckPart + "','" + oSub.HClaim + "'" + - ",'" + oSub.HCloseMan + "'," + Convert.ToString(oSub.HCloseType ? 1 : 0) + ",'" + oSub.HRemark + "'"+ - "," + oSub.HSourceInterID.ToString() + "," + oSub.HSourceEntryID.ToString() + ",'" + oSub.HSourceBillNo + "','" + oSub.HSourceBillType + "'," + oSub.HRelationQty.ToString() + "," + oSub.HRelationMoney.ToString() + - ") "); + " (HInterID,HEntryID" + + ",HManagerID" + + ",HDotCheckItem,HDotCheckPart,HClaim" + + ",HCloseMan,HCloseType,HRemark" + + ",HSourceInterID,HSourceEntryID,HSourceBillNo,HSourceBillType,HRelationQty,HRelationMoney" + + ",HDotCheckItemClassID,HDotCheckItemMethodID" + + ") values(" + + omodel.HInterID.ToString() + "," + oSub.HEntryID.ToString() + + "," + oSub.HManagerID.ToString() + + ",'" + oSub.HDotCheckItem + "','" + oSub.HDotCheckPart + "','" + oSub.HClaim + "'" + + ",'" + oSub.HCloseMan + "'," + Convert.ToString(oSub.HCloseType ? 1 : 0) + ",'" + oSub.HRemark + "'" + + "," + oSub.HSourceInterID.ToString() + "," + oSub.HSourceEntryID.ToString() + ",'" + oSub.HSourceBillNo + "','" + oSub.HSourceBillType + "'," + oSub.HRelationQty.ToString() + "," + oSub.HRelationMoney.ToString() + "," + oSub.HDotCheckItemClassID + "," + oSub.HDotCheckItemMethodID + + ") "); } ////閰嶄欢椤圭洰 @@ -157,12 +158,13 @@ ",HDotCheckItem,HDotCheckPart,HClaim" + ",HCloseMan,HCloseType,HRemark" + ",HSourceInterID,HSourceEntryID,HSourceBillNo,HSourceBillType,HRelationQty,HRelationMoney" + + ",HDotCheckItemClassID,HDotCheckItemMethodID" + ") values(" + omodel.HInterID.ToString() + "," + oSub.HEntryID.ToString() + "," + oSub.HManagerID.ToString() + ",'" + oSub.HDotCheckItem + "','" + oSub.HDotCheckPart + "','" + oSub.HClaim + "'" + ",'" + oSub.HCloseMan + "'," + Convert.ToString(oSub.HCloseType ? 1 : 0) + ",'" + oSub.HRemark + "'" + - "," + oSub.HSourceInterID.ToString() + "," + oSub.HSourceEntryID.ToString() + ",'" + oSub.HSourceBillNo + "','" + oSub.HSourceBillType + "'," + oSub.HRelationQty.ToString() + "," + oSub.HRelationMoney.ToString() + + "," + oSub.HSourceInterID.ToString() + "," + oSub.HSourceEntryID.ToString() + ",'" + oSub.HSourceBillNo + "','" + oSub.HSourceBillType + "'," + oSub.HRelationQty.ToString() + "," + oSub.HRelationMoney.ToString() + "," + oSub.HDotCheckItemClassID + "," + oSub.HDotCheckItemMethodID + ") "); } diff --git "a/DAL/\347\224\237\344\272\247\347\256\241\347\220\206/\346\250\241\345\205\267\347\256\241\347\220\206/ClsSc_MouldDotCheckRuleBill.cs" "b/DAL/\347\224\237\344\272\247\347\256\241\347\220\206/\346\250\241\345\205\267\347\256\241\347\220\206/ClsSc_MouldDotCheckRuleBill.cs" index cd137ea..f6d6520 100644 --- "a/DAL/\347\224\237\344\272\247\347\256\241\347\220\206/\346\250\241\345\205\267\347\256\241\347\220\206/ClsSc_MouldDotCheckRuleBill.cs" +++ "b/DAL/\347\224\237\344\272\247\347\256\241\347\220\206/\346\250\241\345\205\267\347\256\241\347\220\206/ClsSc_MouldDotCheckRuleBill.cs" @@ -64,16 +64,15 @@ foreach (Model.ClsSc_MouldDotCheckRuleBillSub oSub in DetailColl) { oCn.RunProc("Insert into Sc_MouldDotCheckRuleBillSub " + - " (HInterID,HEntryID,HCloseMan,HEntryCloseDate,HCloseType,HRemark" + - ",HSourceInterID,HSourceEntryID,HSourceBillNo,HSourceBillType,HRelationQty,HRelationMoney"+ + " (HInterID,HEntryID,HCloseMan,HEntryCloseDate,HCloseType,HRemark" + + ",HSourceInterID,HSourceEntryID,HSourceBillNo,HSourceBillType,HRelationQty,HRelationMoney" + + ",HDotCheckItemID,HDotCheckItem,HDotCheckPart,HClaim,HManagerID,HDotCheckItemClassID,HDotCheckItemMethodID" + + ") values(" + + omodel.HInterID.ToString() + "," + oSub.HEntryID.ToString() + ",'" + oSub.HCloseMan + "'," + oSub.HEntryCloseDate.ToShortDateString() + "," + Convert.ToString(oSub.HCloseType ? 1 : 0) + ",'" + oSub.HRemark + "'" + + "," + oSub.HSourceInterID.ToString() + "," + oSub.HSourceEntryID.ToString() + ",'" + oSub.HSourceBillNo + "','" + oSub.HSourceBillType + "'," + oSub.HRelationQty.ToString() + "," + oSub.HRelationMoney.ToString() + - ",HDotCheckItemID,HDotCheckItem,HDotCheckPart,HClaim,HManagerID" + - ") values(" - + omodel.HInterID.ToString() + "," + oSub.HEntryID.ToString() + ",'" + oSub.HCloseMan + "'," + oSub.HEntryCloseDate.ToShortDateString() + "," + Convert.ToString(oSub.HCloseType ? 1 : 0) + ",'" + oSub.HRemark + "'" + - "," + oSub.HSourceInterID.ToString() + "," + oSub.HSourceEntryID.ToString() + ",'" + oSub.HSourceBillNo + "','" + oSub.HSourceBillType + "'," + oSub.HRelationQty.ToString() + "," + oSub.HRelationMoney.ToString() + - - "," + oSub.HDotCheckItemID.ToString() + ",'" + oSub.HDotCheckItem + "','" + oSub.HDotCheckPart + "','" + oSub.HClaim + "'," + oSub.HManagerID.ToString() + - ") "); + "," + oSub.HDotCheckItemID.ToString() + ",'" + oSub.HDotCheckItem + "','" + oSub.HDotCheckPart + "','" + oSub.HClaim + "'," + oSub.HManagerID.ToString() + "," + oSub.HDotCheckItemClassID + "," + oSub.HDotCheckItemMethodID + + ") "); } //foreach (Model.ClsSc_MouldDotCheckRuleBillSub_Item oSub in DetailColl) //{ @@ -127,13 +126,12 @@ oCn.RunProc("Insert into Sc_MouldDotCheckRuleBillSub " + " (HInterID,HEntryID,HCloseMan,HEntryCloseDate,HCloseType,HRemark" + ",HSourceInterID,HSourceEntryID,HSourceBillNo,HSourceBillType,HRelationQty,HRelationMoney" + - - ",HDotCheckItemID,HDotCheckItem,HDotCheckPart,HClaim,HManagerID" + + ",HDotCheckItemID,HDotCheckItem,HDotCheckPart,HClaim,HManagerID,HDotCheckItemClassID,HDotCheckItemMethodID" + ") values(" + omodel.HInterID.ToString() + "," + oSub.HEntryID.ToString() + ",'" + oSub.HCloseMan + "'," + oSub.HEntryCloseDate.ToShortDateString() + "," + Convert.ToString(oSub.HCloseType ? 1 : 0) + ",'" + oSub.HRemark + "'" + "," + oSub.HSourceInterID.ToString() + "," + oSub.HSourceEntryID.ToString() + ",'" + oSub.HSourceBillNo + "','" + oSub.HSourceBillType + "'," + oSub.HRelationQty.ToString() + "," + oSub.HRelationMoney.ToString() + - "," + oSub.HDotCheckItemID.ToString() + ",'" + oSub.HDotCheckItem + "','" + oSub.HDotCheckPart + "','" + oSub.HClaim + "'," + oSub.HManagerID.ToString() + + "," + oSub.HDotCheckItemID.ToString() + ",'" + oSub.HDotCheckItem + "','" + oSub.HDotCheckPart + "','" + oSub.HClaim + "'," + oSub.HManagerID.ToString() + "," + oSub.HDotCheckItemClassID + "," + oSub.HDotCheckItemMethodID + ") "); } //foreach (Model.ClsSc_MouldDotCheckRuleBillSub_Item oSub in DetailColl) diff --git "a/DAL/\347\224\237\344\272\247\347\256\241\347\220\206/\350\256\276\345\244\207\347\256\241\347\220\206/ClsSb_EquipDotCheckPlanBill.cs" "b/DAL/\347\224\237\344\272\247\347\256\241\347\220\206/\350\256\276\345\244\207\347\256\241\347\220\206/ClsSb_EquipDotCheckPlanBill.cs" index 9fc7812..4a90c79 100644 --- "a/DAL/\347\224\237\344\272\247\347\256\241\347\220\206/\350\256\276\345\244\207\347\256\241\347\220\206/ClsSb_EquipDotCheckPlanBill.cs" +++ "b/DAL/\347\224\237\344\272\247\347\256\241\347\220\206/\350\256\276\345\244\207\347\256\241\347\220\206/ClsSb_EquipDotCheckPlanBill.cs" @@ -69,13 +69,13 @@ "HCloseMan,HEntryCloseDate,HCloseType,HRemark," + "HSourceInterID,HSourceEntryID,HSourceBillNo,HSourceBillType,HRelationQty,HRelationMoney," + "HDotCheckItem,HDotCheckPart,HClaim," + - "HManagerID,HManagerNumber" + + "HManagerID,HManagerNumber,HDotCheckItemClassID,HDotCheckItemMethodID" + ") values(" - + omodel.HInterID.ToString() + "," + oSub.HEntryID.ToString() + - ",'" + oSub.HCloseMan + "','"+oSub.HEntryCloseDate+"'," + Convert.ToString(oSub.HCloseType ? 1 : 0) + ",'" + oSub.HRemark + "'" + + + omodel.HInterID.ToString() + "," + oSub.HEntryID.ToString() + + ",'" + oSub.HCloseMan + "','" + oSub.HEntryCloseDate + "'," + Convert.ToString(oSub.HCloseType ? 1 : 0) + ",'" + oSub.HRemark + "'" + "," + oSub.HSourceInterID.ToString() + "," + oSub.HSourceEntryID.ToString() + ",'" + oSub.HSourceBillNo + "','" + oSub.HSourceBillType + "'," + oSub.HRelationQty.ToString() + "," + oSub.HRelationMoney.ToString() + - ",'" + oSub.HDotCheckItem + "','" + oSub.HDotCheckPart + "','" + oSub.HClaim + - "'," + oSub.HManagerID.ToString()+",'" +oSub.HManagerNumber+"'"+ + ",'" + oSub.HDotCheckItem + "','" + oSub.HDotCheckPart + "','" + oSub.HClaim + + "'," + oSub.HManagerID.ToString() + ",'" + oSub.HManagerNumber + "'," + oSub.HDotCheckItemClassID + "," + oSub.HDotCheckItemMethodID + ") "); } // @@ -128,13 +128,13 @@ "HCloseMan,HEntryCloseDate,HCloseType,HRemark," + "HSourceInterID,HSourceEntryID,HSourceBillNo,HSourceBillType,HRelationQty,HRelationMoney," + "HDotCheckItem,HDotCheckPart,HClaim," + - "HManagerID,HManagerNumber" + + "HManagerID,HManagerNumber,HDotCheckItemClassID,HDotCheckItemMethodID" + ") values(" + omodel.HInterID.ToString() + "," + oSub.HEntryID.ToString() + ",'" + oSub.HCloseMan + "','" + oSub.HEntryCloseDate + "'," + Convert.ToString(oSub.HCloseType ? 1 : 0) + ",'" + oSub.HRemark + "'" + "," + oSub.HSourceInterID.ToString() + "," + oSub.HSourceEntryID.ToString() + ",'" + oSub.HSourceBillNo + "','" + oSub.HSourceBillType + "'," + oSub.HRelationQty.ToString() + "," + oSub.HRelationMoney.ToString() + ",'" + oSub.HDotCheckItem + "','" + oSub.HDotCheckPart + "','" + oSub.HClaim + - "'," + oSub.HManagerID.ToString() + ",'" + oSub.HManagerNumber + "'" + + "'," + oSub.HManagerID.ToString() + ",'" + oSub.HManagerNumber + "'," + oSub.HDotCheckItemClassID + "," + oSub.HDotCheckItemMethodID + ") "); } // diff --git "a/DAL/\350\264\250\346\243\200\347\256\241\347\220\206/ClsQC_FirstPieceCheckBill.cs" "b/DAL/\350\264\250\346\243\200\347\256\241\347\220\206/ClsQC_FirstPieceCheckBill.cs" index 3494e2f..57ad084 100644 --- "a/DAL/\350\264\250\346\243\200\347\256\241\347\220\206/ClsQC_FirstPieceCheckBill.cs" +++ "b/DAL/\350\264\250\346\243\200\347\256\241\347\220\206/ClsQC_FirstPieceCheckBill.cs" @@ -92,6 +92,8 @@ ",HMaterID=" + omodel.HMaterID.ToString() + ",HFirstCheckEmp=" + omodel.HFirstCheckEmp.ToString() + ",HLastResult=" + DBUtility.ClsPub.BoolToString(omodel.HLastResult) + + ",HShiftsID=" + omodel.HShiftsID.ToString() + + ",HErrTreatment='" + omodel.HErrTreatment + "'" + " where HInterID=" + lngBillKey.ToString()); //鍒犻櫎鍏宠仈 DeleteRelation(ref sReturn, lngBillKey); @@ -204,13 +206,13 @@ ",HYear,HPeriod,HRemark" + ",HSourceID,HICMOInterID,HICMOBillNo,HICMOQty,HProcExchInterID,HProcExchEntryID" + ",HProcExchBillNo,HProcExchQty,HMaterID,HFirstCheckEmp,HLastResult" + - ",HMainSourceInterID,HMainSourceEntryID,HMainSourceBillNo,HMainSourceBillType,HICMOEntryID,HQCSchemeID" + + ",HMainSourceInterID,HMainSourceEntryID,HMainSourceBillNo,HMainSourceBillType,HICMOEntryID,HQCSchemeID,HShiftsID,HErrTreatment" + ") " + " values('" + this.BillType + "','" + this.HBillSubType + "'," + omodel.HInterID.ToString() + ",'" + omodel.HBillNo + "'," + omodel.HBillStatus.ToString() + ",'" + omodel.HDate + "','" + omodel.HMaker + "',getdate()" + "," + omodel.HYear.ToString() + "," + omodel.HPeriod.ToString() + ",'" + omodel.HRemark + "'" + "," + omodel.HSourceID.ToString() + "," + omodel.HICMOInterID.ToString() + ",'" + omodel.HICMOBillNo + "'," + omodel.HICMOQty.ToString() + "," + omodel.HProcExchInterID.ToString() + "," + omodel.HProcExchEntryID.ToString() + ",'" + omodel.HProcExchBillNo + "'," + omodel.HProcExchQty.ToString() + "," + omodel.HMaterID.ToString() + "," + omodel.HFirstCheckEmp.ToString() + ", " + DBUtility.ClsPub.BoolToString(omodel.HLastResult) + - "," + omodel.HMainSourceInterID + "," + omodel.HMainSourceEntryID + ",'" + omodel.HMainSourceBillNo + "','" + omodel.HMainSourceBillType + "'," + omodel.HICMOEntryID + "," + omodel.HQCSchemeID + + "," + omodel.HMainSourceInterID + "," + omodel.HMainSourceEntryID + ",'" + omodel.HMainSourceBillNo + "','" + omodel.HMainSourceBillType + "'," + omodel.HICMOEntryID + "," + omodel.HQCSchemeID + "," + omodel.HShiftsID + ",'" + omodel.HErrTreatment + "'" + ") "); //鎻掑叆瀛愯〃 foreach (Model.ClsQC_FirstPieceCheckBillSub oSub in DetailColl) diff --git "a/DAL/\350\264\250\346\243\200\347\256\241\347\220\206/ClsQC_ProcessCheckBill.cs" "b/DAL/\350\264\250\346\243\200\347\256\241\347\220\206/ClsQC_ProcessCheckBill.cs" index 56431ed..115aa38 100644 --- "a/DAL/\350\264\250\346\243\200\347\256\241\347\220\206/ClsQC_ProcessCheckBill.cs" +++ "b/DAL/\350\264\250\346\243\200\347\256\241\347\220\206/ClsQC_ProcessCheckBill.cs" @@ -106,6 +106,8 @@ ",HRoutingInterID=" + omodel.HRoutingInterID.ToString() + ",HDrawingDireID='" + omodel.HDrawingDireID + "'" + ",HPackTypeID=" + omodel.HPackTypeID.ToString() + + ",HShiftsID=" + omodel.HShiftsID.ToString() + + ",HErrTreatment='" + omodel.HErrTreatment + "'" + " where HInterID=" + lngBillKey.ToString()); //鍒犻櫎鍏宠仈 DeleteRelation(ref sReturn, lngBillKey); @@ -206,7 +208,7 @@ ",HBarCode,HLBatchNo,HCusID,HSortBillNo,HContrctBatchNo" + ",HProdAreaID,HProdTypeID,HProdStoveNo,HRecipeID,HDiameter1" + ",HDiameter2,HRoutingInterID,HDrawingDireID,HPackTypeID" + - ",HMainSourceInterID,HMainSourceEntryID,HMainSourceBillNo,HMainSourceBillType,HICMOEntryID,HQCSchemeID,HICMOQty,HProcExchQty" + + ",HMainSourceInterID,HMainSourceEntryID,HMainSourceBillNo,HMainSourceBillType,HICMOEntryID,HQCSchemeID,HICMOQty,HProcExchQty,HShiftsID,HErrTreatment" + ") " + " values('" + this.BillType + "','" + this.HBillSubType + "'," + omodel.HInterID.ToString() + ",'" + omodel.HBillNo + "'," + omodel.HBillStatus.ToString() + ",'" + omodel.HDate + "','" + omodel.HMaker + "',getdate()" + "," + omodel.HYear.ToString() + "," + omodel.HPeriod.ToString() + ",'" + omodel.HRemark + "'"+ @@ -216,7 +218,7 @@ ",'" + omodel.HBarCode + "','" + omodel.HLBatchNo + "'," + omodel.HCusID.ToString() + ",'" + omodel.HSortBillNo + "','" + omodel.HContrctBatchNo + "'" + "," + omodel.HProdAreaID.ToString() + "," + omodel.HProdTypeID.ToString() + ",'" + omodel.HProdStoveNo + "'," + omodel.HRecipeID.ToString() + "," + omodel.HDiameter1.ToString() + "," + omodel.HDiameter2.ToString() + "," + omodel.HRoutingInterID.ToString() + ",'" + omodel.HDrawingDireID + "'," + omodel.HPackTypeID.ToString() + - "," + omodel.HMainSourceInterID + "," + omodel.HMainSourceEntryID + ",'" + omodel.HMainSourceBillNo + "','" + omodel.HMainSourceBillType + "'," + omodel.HICMOEntryID + "," + omodel.HQCSchemeID + "," + omodel.HICMOQty + "," + omodel.HProcExchQty + + "," + omodel.HMainSourceInterID + "," + omodel.HMainSourceEntryID + ",'" + omodel.HMainSourceBillNo + "','" + omodel.HMainSourceBillType + "'," + omodel.HICMOEntryID + "," + omodel.HQCSchemeID + "," + omodel.HICMOQty + "," + omodel.HProcExchQty + "," + omodel.HShiftsID + ",'" + omodel.HErrTreatment + "'" + ") "); //鎻掑叆瀛愯〃 foreach (Model.ClsQC_ProcessCheckBillSub oSub in DetailColl) diff --git "a/DAL/\351\224\200\345\224\256\347\256\241\347\220\206/ClsXs_ReceivableBill.cs" "b/DAL/\351\224\200\345\224\256\347\256\241\347\220\206/ClsXs_ReceivableBill.cs" index 3691193..d087237 100644 --- "a/DAL/\351\224\200\345\224\256\347\256\241\347\220\206/ClsXs_ReceivableBill.cs" +++ "b/DAL/\351\224\200\345\224\256\347\256\241\347\220\206/ClsXs_ReceivableBill.cs" @@ -36,52 +36,52 @@ #region 鍏宠仈鏁伴噺 //鍒犻櫎鍏宠仈 - //public override void DeleteRelation(ref string sReturn, Int64 lngBillKey) - //{ - // //閿�鍞鍗� 閿�鍞嚭搴撳崟 鍏宠仈鏁伴噺 - // try - // { - // if (DetailColl[0].HSourceBillType == "1401") //閿�鍞鍗� - // { - // oCn.RunProc("exec h_p_Xs_UpDateRelation_SeOrderToPOStockIn_Del " + lngBillKey.ToString()); - // } - // else if (DetailColl[0].HSourceBillType == "1205") //閿�鍞嚭搴撳崟 - // { - // oCn.RunProc("exec h_p_Xs_UpDateRelation_ICStockoPOStockIn_Del " + lngBillKey.ToString()); - // } - // else - // { - // } - // } - // catch (Exception e) - // { - // throw (e); - // } - //} - ////鏂板鍏宠仈 - //public override void AddNewRelation(ref string sReturn, Int64 lngBillKey) - //{ - // //閿�鍞鍗� 閿�鍞嚭搴撳崟 鍏宠仈鏁伴噺 - // try - // { - // if (DetailColl[0].HSourceBillType == "1401") //閿�鍞鍗� - // { - // oCn.RunProc("exec h_p_Xs_UpDateRelation_SeOrderToPOStockIn_Add " + lngBillKey.ToString()); - // } - // else if (DetailColl[0].HSourceBillType == "1205") //閿�鍞嚭搴撳崟 - // { - // oCn.RunProc("exec h_p_Xs_UpDateRelation_ICStockToPOStockIn_Add " + lngBillKey.ToString()); - // } - // else - // { + public override void DeleteRelation(ref string sReturn, Int64 lngBillKey) + { + //閿�鍞鍗� 閿�鍞嚭搴撳崟 鍏宠仈鏁伴噺 + try + { + if (DetailColl[0].HSourceBillType == "1401") //閿�鍞鍗� + { + oCn.RunProc("exec h_p_Xs_UpDateRelation_SeOrderToPOStockIn_Del " + lngBillKey.ToString()); + } + else if (DetailColl[0].HSourceBillType == "1205") //閿�鍞嚭搴撳崟 + { + oCn.RunProc("exec h_p_Xs_UpDateRelation_ICStockoPOStockIn_Del " + lngBillKey.ToString()); + } + else + { + } + } + catch (Exception e) + { + throw (e); + } + } + //鏂板鍏宠仈 + public override void AddNewRelation(ref string sReturn, Int64 lngBillKey) + { + //閿�鍞鍗� 閿�鍞嚭搴撳崟 鍏宠仈鏁伴噺 + try + { + if (DetailColl[0].HSourceBillType == "1401") //閿�鍞鍗� + { + oCn.RunProc("exec h_p_Xs_UpDateRelation_SeOrderToPOStockIn_Add " + lngBillKey.ToString()); + } + else if (DetailColl[0].HSourceBillType == "1205") //閿�鍞嚭搴撳崟 + { + oCn.RunProc("exec h_p_Xs_UpDateRelation_ICStockToPOStockIn_Add " + lngBillKey.ToString()); + } + else + { - // } - // } - // catch (Exception e) - // { - // throw (e); - // } - //} + } + } + catch (Exception e) + { + throw (e); + } + } #endregion @@ -169,8 +169,8 @@ oCn.RunProc(subSql); } - ////鏇存柊璁㈠崟鍏宠仈鏁伴噺 - //AddNewRelation(ref sReturn, omodel.HInterID); + //鏇存柊璁㈠崟鍏宠仈鏁伴噺 + AddNewRelation(ref sReturn, omodel.HInterID); sReturn = "淇敼鍗曟嵁鎴愬姛锛�"; oCn.Commit(); @@ -288,8 +288,8 @@ oCn.RunProc(subSql); } - ////鏇存柊璁㈠崟鍏宠仈鏁伴噺 - //AddNewRelation(ref sReturn, omodel.HInterID); + //鏇存柊璁㈠崟鍏宠仈鏁伴噺 + AddNewRelation(ref sReturn, omodel.HInterID); sReturn = "鏂板鍗曟嵁鎴愬姛锛�"; oCn.Commit(); diff --git "a/DAL/\351\224\200\345\224\256\347\256\241\347\220\206/ClsXs_SeOrderBill.cs" "b/DAL/\351\224\200\345\224\256\347\256\241\347\220\206/ClsXs_SeOrderBill.cs" index 185066c..1c0e78f 100644 --- "a/DAL/\351\224\200\345\224\256\347\256\241\347\220\206/ClsXs_SeOrderBill.cs" +++ "b/DAL/\351\224\200\345\224\256\347\256\241\347\220\206/ClsXs_SeOrderBill.cs" @@ -134,7 +134,7 @@ string subSql = "Insert into Xs_SeOrderBillSub" + "(HInterID,HEntryID,HSourceInterID,HSourceEntryID,HSourceBillNo,HSourceBillType,HRelationQty,HRelationQty_SellOutCheck,HRelationMoney_SellOutCheck,HRelationQty_ICMO,HRelationQty_SellBack,HRelationQty_SellBackCheck,HRelationMoney,HMaterID,HUnitID,HQty,HPrice,HTaxPrice,HMoney" + ",HDiscountRate,HRelTaxPrice,HTaxRate,HTaxMoney,HlineTotal,HlineTotalBB,HDate,HOutStockQty,HInvoiceQty,HRemark,HOrderLevID" + - ",HCusMaterNumber,HCusModel,HCusMaterName,HisStockGoods,HWHID) " + + ",HCusMaterNumber,HCusModel,HCusMaterName,HisStockGoods,HWHID,HRemark_TL,HRemark_SJG) " + "values(" + "" + omodel.HInterID + "," + oSub.HEntryID + @@ -170,8 +170,10 @@ "','" + oSub.HCusModel + "','" + oSub.HCusMaterName + "'," + (oSub.HisStockGoods?1:0) + - ",'" + oSub.HWhID + - "')"; + ",'" + oSub.HWhID + "'" + + ",'" + oSub.HRemark_TL + "'" + + ",'" + oSub.HRemark_SJG + "'" + + ")"; oCn.RunProc(subSql); } @@ -350,7 +352,7 @@ string subSql = "Insert into Xs_SeOrderBillSub" + "(HInterID,HEntryID,HSourceInterID,HSourceEntryID,HSourceBillNo,HSourceBillType,HRelationQty,HRelationQty_SellOutCheck,HRelationMoney_SellOutCheck,HRelationQty_ICMO,HRelationQty_SellBack,HRelationQty_SellBackCheck,HRelationMoney,HMaterID,HUnitID,HQty,HPrice,HTaxPrice,HMoney" + ",HDiscountRate,HRelTaxPrice,HTaxRate,HTaxMoney,HlineTotal,HlineTotalBB,HDate,HOutStockQty,HInvoiceQty,HRemark,HOrderLevID" + - ",HCusMaterNumber,HCusModel,HCusMaterName,HisStockGoods,HWHID) " + + ",HCusMaterNumber,HCusModel,HCusMaterName,HisStockGoods,HWHID,HRemark_TL,HRemark_SJG) " + "values(" + "" + omodel.HInterID + "," + oSub.HEntryID + @@ -386,8 +388,10 @@ "','" + oSub.HCusModel + "','" + oSub.HCusMaterName + "'," + (oSub.HisStockGoods?1:0) + - ",'" + oSub.HWhID + - "')"; + ",'" + oSub.HWhID + "'" + + ",'" + oSub.HRemark_TL + "'" + + ",'" + oSub.HRemark_SJG + "'" + + ")"; oCn.RunProc(subSql); } @@ -538,6 +542,9 @@ oSub.HInvoiceQty = DBUtility.ClsPub.isDoule(DsSub.Tables[0].Rows[i]["HInvoiceQty"]); oSub.HisStockGoods = DBUtility.ClsPub.isLong(DsSub.Tables[0].Rows[i]["HisStockGoods"]) == 1 ? true : false; + oSub.HRemark_TL = DBUtility.ClsPub.isStrNull(DsSub.Tables[0].Rows[0]["HRemark_TL"]); + oSub.HRemark_SJG = DBUtility.ClsPub.isStrNull(DsSub.Tables[0].Rows[0]["HRemark_SJG"]); + DetailColl.Add(oSub); } sReturn = "鏄剧ず鍗曟嵁鎴愬姛锛�"; diff --git a/LMES/bin/x86/Debug.zip b/LMES/bin/x86/Debug.zip index e79df31..3cce815 100644 --- a/LMES/bin/x86/Debug.zip +++ b/LMES/bin/x86/Debug.zip Binary files differ diff --git a/Model/Model.csproj b/Model/Model.csproj index f0533f1..d285e15 100644 --- a/Model/Model.csproj +++ b/Model/Model.csproj @@ -361,6 +361,8 @@ <Compile Include="鍩虹璧勬枡\鍩虹璧勬枡\ClsGy_CardStatus_Model.cs" /> <Compile Include="鍩虹璧勬枡\鍩虹璧勬枡\ClsGy_CardAddress_Model.cs" /> <Compile Include="鍩虹璧勬枡\鍩虹璧勬枡\ClsGy_CardType_Model.cs" /> + <Compile Include="鍩虹璧勬枡\鍩虹璧勬枡\ClsGy_DotCheckItemMethod_Model.cs" /> + <Compile Include="鍩虹璧勬枡\鍩虹璧勬枡\ClsGy_DotCheckItemClass_Model.cs" /> <Compile Include="鍩虹璧勬枡\鍩虹璧勬枡\ClsGy_ErrMsgBackType_Model.cs" /> <Compile Include="鍩虹璧勬枡\鍩虹璧勬枡\ClsGy_TaskClass_Model.cs" /> <Compile Include="鍩虹璧勬枡\鍩虹璧勬枡\ClsGy_ProjectClass_Model.cs" /> diff --git "a/Model/\345\237\272\347\241\200\350\265\204\346\226\231/\345\205\266\344\273\226\345\237\272\347\241\200\350\265\204\346\226\231/ClsGy_QCCheckProjectMain.cs" "b/Model/\345\237\272\347\241\200\350\265\204\346\226\231/\345\205\266\344\273\226\345\237\272\347\241\200\350\265\204\346\226\231/ClsGy_QCCheckProjectMain.cs" index 658479c..e3757a5 100644 --- "a/Model/\345\237\272\347\241\200\350\265\204\346\226\231/\345\205\266\344\273\226\345\237\272\347\241\200\350\265\204\346\226\231/ClsGy_QCCheckProjectMain.cs" +++ "b/Model/\345\237\272\347\241\200\350\265\204\346\226\231/\345\205\266\344\273\226\345\237\272\347\241\200\350\265\204\346\226\231/ClsGy_QCCheckProjectMain.cs" @@ -16,5 +16,6 @@ public bool HStandard; public Int64 HProcID; public Int64 HDeptID; + public Int64 HSampleSchemeID; } } diff --git "a/Model/\345\237\272\347\241\200\350\265\204\346\226\231/\345\205\266\344\273\226\345\237\272\347\241\200\350\265\204\346\226\231/ClsGy_QCCheckProjectSub.cs" "b/Model/\345\237\272\347\241\200\350\265\204\346\226\231/\345\205\266\344\273\226\345\237\272\347\241\200\350\265\204\346\226\231/ClsGy_QCCheckProjectSub.cs" index 68b5725..b5e03db 100644 --- "a/Model/\345\237\272\347\241\200\350\265\204\346\226\231/\345\205\266\344\273\226\345\237\272\347\241\200\350\265\204\346\226\231/ClsGy_QCCheckProjectSub.cs" +++ "b/Model/\345\237\272\347\241\200\350\265\204\346\226\231/\345\205\266\344\273\226\345\237\272\347\241\200\350\265\204\346\226\231/ClsGy_QCCheckProjectSub.cs" @@ -14,5 +14,42 @@ public String HQCStdMax; public String HQCUnit; + public String HQCTool; + public String HAnalysisMethod; + public String HDefectLevel; + public Int64 HDestructInspect; + public Int64 HKeyInspect; + public Int64 HQualityStdID; + public Int64 HInspectMethodID; + public Int64 HInspectInstruMentID; + public Int64 HInspectBasisID; + public Int64 HSampleSchemeID; + public String HStatus; + public String HCompareSymbol; + public String HTargetVal; + public String HUpLimit; + public String HDownLimit; + public String HUpOffSet; + public String HDownOffSet; + public String HTargetValKey; + public String HUpLimitKey; + public String HDownLimitKey; + public String HUpOffSetKey; + public String HDownOffSetKey; + public Decimal HTargetValQ; + public Decimal HUpLimitQ; + public Decimal HDownLimitQ; + public Decimal HUpOffSetQ; + public Decimal HDownOffSetQ; + public Int64 HTargetValB; + public Int64 HUpLimitB; + public Int64 HDownLimitB; + public Int64 HUpOffSetB; + public Int64 HDownOffSetB; + public String HTargetValTxt; + public String HUpLimitTxt; + public String HDownLimitTxt; + public String HUpOffSetTxt; + public String HDownOffSetTxt; } } diff --git "a/Model/\345\237\272\347\241\200\350\265\204\346\226\231/\345\237\272\347\241\200\350\265\204\346\226\231/ClsGy_DotCheckItemClass_Model.cs" "b/Model/\345\237\272\347\241\200\350\265\204\346\226\231/\345\237\272\347\241\200\350\265\204\346\226\231/ClsGy_DotCheckItemClass_Model.cs" new file mode 100644 index 0000000..d644a4f --- /dev/null +++ "b/Model/\345\237\272\347\241\200\350\265\204\346\226\231/\345\237\272\347\241\200\350\265\204\346\226\231/ClsGy_DotCheckItemClass_Model.cs" @@ -0,0 +1,11 @@ +using System; +using System.Collections.Generic; +using System.Text; + +namespace Model +{ + public class ClsGy_DotCheckItemClass_Model : DBUtility.ClsGy_Base_Model + { + // + } +} diff --git "a/Model/\345\237\272\347\241\200\350\265\204\346\226\231/\345\237\272\347\241\200\350\265\204\346\226\231/ClsGy_DotCheckItemMethod_Model.cs" "b/Model/\345\237\272\347\241\200\350\265\204\346\226\231/\345\237\272\347\241\200\350\265\204\346\226\231/ClsGy_DotCheckItemMethod_Model.cs" new file mode 100644 index 0000000..58501fd --- /dev/null +++ "b/Model/\345\237\272\347\241\200\350\265\204\346\226\231/\345\237\272\347\241\200\350\265\204\346\226\231/ClsGy_DotCheckItemMethod_Model.cs" @@ -0,0 +1,11 @@ +using System; +using System.Collections.Generic; +using System.Text; + +namespace Model +{ + public class ClsGy_DotCheckItemMethod_Model : DBUtility.ClsGy_Base_Model + { + // + } +} diff --git "a/Model/\347\224\237\344\272\247\347\256\241\347\220\206/\346\250\241\345\205\267\347\256\241\347\220\206/ClsSc_MouldDotCheckPlanBillSub.cs" "b/Model/\347\224\237\344\272\247\347\256\241\347\220\206/\346\250\241\345\205\267\347\256\241\347\220\206/ClsSc_MouldDotCheckPlanBillSub.cs" index 27ac977..6fb7d28 100644 --- "a/Model/\347\224\237\344\272\247\347\256\241\347\220\206/\346\250\241\345\205\267\347\256\241\347\220\206/ClsSc_MouldDotCheckPlanBillSub.cs" +++ "b/Model/\347\224\237\344\272\247\347\256\241\347\220\206/\346\250\241\345\205\267\347\256\241\347\220\206/ClsSc_MouldDotCheckPlanBillSub.cs" @@ -15,6 +15,7 @@ public string HClaim;// varchar(100) --具体要求 public long HManagerID;// int --负责人id(职员表) - + public Int64 HDotCheckItemClassID;//点检项目分类id + public Int64 HDotCheckItemMethodID;//点检方法id } } diff --git "a/Model/\347\224\237\344\272\247\347\256\241\347\220\206/\346\250\241\345\205\267\347\256\241\347\220\206/ClsSc_MouldDotCheckRuleBillSub.cs" "b/Model/\347\224\237\344\272\247\347\256\241\347\220\206/\346\250\241\345\205\267\347\256\241\347\220\206/ClsSc_MouldDotCheckRuleBillSub.cs" index 45cdc0f..44054ea 100644 --- "a/Model/\347\224\237\344\272\247\347\256\241\347\220\206/\346\250\241\345\205\267\347\256\241\347\220\206/ClsSc_MouldDotCheckRuleBillSub.cs" +++ "b/Model/\347\224\237\344\272\247\347\256\241\347\220\206/\346\250\241\345\205\267\347\256\241\347\220\206/ClsSc_MouldDotCheckRuleBillSub.cs" @@ -15,6 +15,7 @@ public string HClaim;// varchar(100) --具体要求 public Int64 HManagerID;// int --负责人id(职员表) - + public Int64 HDotCheckItemClassID;//点检项目分类id + public Int64 HDotCheckItemMethodID;//点检方法id } } diff --git "a/Model/\347\224\237\344\272\247\347\256\241\347\220\206/\350\256\276\345\244\207\347\256\241\347\220\206/ClsSb_EquipDotCheckPlanBillSub.cs" "b/Model/\347\224\237\344\272\247\347\256\241\347\220\206/\350\256\276\345\244\207\347\256\241\347\220\206/ClsSb_EquipDotCheckPlanBillSub.cs" index 35eab31..4295b33 100644 --- "a/Model/\347\224\237\344\272\247\347\256\241\347\220\206/\350\256\276\345\244\207\347\256\241\347\220\206/ClsSb_EquipDotCheckPlanBillSub.cs" +++ "b/Model/\347\224\237\344\272\247\347\256\241\347\220\206/\350\256\276\345\244\207\347\256\241\347\220\206/ClsSb_EquipDotCheckPlanBillSub.cs" @@ -24,7 +24,9 @@ public string HUnitName; public Int64 HManagerID; public string HManagerNumber; - public string HManagerName; + public string HManagerName; + public Int64 HDotCheckItemClassID;//点检项目分类id + public Int64 HDotCheckItemMethodID;//点检方法id } } diff --git "a/Model/\350\264\250\346\243\200\347\256\241\347\220\206/ClsQC_FirstPieceCheckBillMain.cs" "b/Model/\350\264\250\346\243\200\347\256\241\347\220\206/ClsQC_FirstPieceCheckBillMain.cs" index 633a7d6..54afc0b 100644 --- "a/Model/\350\264\250\346\243\200\347\256\241\347\220\206/ClsQC_FirstPieceCheckBillMain.cs" +++ "b/Model/\350\264\250\346\243\200\347\256\241\347\220\206/ClsQC_FirstPieceCheckBillMain.cs" @@ -24,5 +24,7 @@ public Int64 HUnitID; public Int64 HProcID; + public Int64 HShiftsID; + public string HErrTreatment; } } diff --git "a/Model/\350\264\250\346\243\200\347\256\241\347\220\206/ClsQC_PatrolProcCheckBillMain.cs" "b/Model/\350\264\250\346\243\200\347\256\241\347\220\206/ClsQC_PatrolProcCheckBillMain.cs" index 1b73614..658e8c0 100644 --- "a/Model/\350\264\250\346\243\200\347\256\241\347\220\206/ClsQC_PatrolProcCheckBillMain.cs" +++ "b/Model/\350\264\250\346\243\200\347\256\241\347\220\206/ClsQC_PatrolProcCheckBillMain.cs" @@ -21,5 +21,7 @@ public Int64 HMainProcID; public Int64 HLastResult; + public Int64 HShiftsID; + public string HErrTreatment; } } diff --git "a/Model/\350\264\250\346\243\200\347\256\241\347\220\206/ClsQC_ProcessCheckBillMain.cs" "b/Model/\350\264\250\346\243\200\347\256\241\347\220\206/ClsQC_ProcessCheckBillMain.cs" index c42294f..ecf88d1 100644 --- "a/Model/\350\264\250\346\243\200\347\256\241\347\220\206/ClsQC_ProcessCheckBillMain.cs" +++ "b/Model/\350\264\250\346\243\200\347\256\241\347\220\206/ClsQC_ProcessCheckBillMain.cs" @@ -43,5 +43,8 @@ public Int64 HICMOQty; public Int64 HProcExchQty; + + public Int64 HShiftsID; + public string HErrTreatment; } } diff --git "a/Model/\351\224\200\345\224\256\347\256\241\347\220\206/ClsXs_SeOrderBillSub.cs" "b/Model/\351\224\200\345\224\256\347\256\241\347\220\206/ClsXs_SeOrderBillSub.cs" index 85ecdbc..678e592 100644 --- "a/Model/\351\224\200\345\224\256\347\256\241\347\220\206/ClsXs_SeOrderBillSub.cs" +++ "b/Model/\351\224\200\345\224\256\347\256\241\347\220\206/ClsXs_SeOrderBillSub.cs" @@ -93,5 +93,8 @@ public double HRelationQty_ICMO; public double HRelationQty_SellBack; public double HRelationQty_SellBackCheck; + + public string HRemark_TL; //投料 + public string HRemark_SJG; //深加工 } } diff --git a/PayM/bin/x86/Debug/BLL.dll b/PayM/bin/x86/Debug/BLL.dll index 7a5ed00..bccfb5a 100644 --- a/PayM/bin/x86/Debug/BLL.dll +++ b/PayM/bin/x86/Debug/BLL.dll Binary files differ diff --git a/PayM/bin/x86/Debug/BLL.pdb b/PayM/bin/x86/Debug/BLL.pdb index 7cd1875..e1750df 100644 --- a/PayM/bin/x86/Debug/BLL.pdb +++ b/PayM/bin/x86/Debug/BLL.pdb Binary files differ diff --git a/PayM/bin/x86/Debug/DAL.dll b/PayM/bin/x86/Debug/DAL.dll index 3c1fb8c..1264702 100644 --- a/PayM/bin/x86/Debug/DAL.dll +++ b/PayM/bin/x86/Debug/DAL.dll Binary files differ diff --git a/PayM/bin/x86/Debug/DAL.pdb b/PayM/bin/x86/Debug/DAL.pdb index c1092cd..c501852 100644 --- a/PayM/bin/x86/Debug/DAL.pdb +++ b/PayM/bin/x86/Debug/DAL.pdb Binary files differ diff --git a/PayM/bin/x86/Debug/DBUtility.dll b/PayM/bin/x86/Debug/DBUtility.dll index d82eed2..e07f770 100644 --- a/PayM/bin/x86/Debug/DBUtility.dll +++ b/PayM/bin/x86/Debug/DBUtility.dll Binary files differ diff --git a/PayM/bin/x86/Debug/DBUtility.pdb b/PayM/bin/x86/Debug/DBUtility.pdb index 84f212e..7816369 100644 --- a/PayM/bin/x86/Debug/DBUtility.pdb +++ b/PayM/bin/x86/Debug/DBUtility.pdb Binary files differ diff --git a/PayM/bin/x86/Debug/Model.dll b/PayM/bin/x86/Debug/Model.dll index 0393c69..18da444 100644 --- a/PayM/bin/x86/Debug/Model.dll +++ b/PayM/bin/x86/Debug/Model.dll Binary files differ diff --git a/PayM/bin/x86/Debug/Model.pdb b/PayM/bin/x86/Debug/Model.pdb index 92f12c0..52743b9 100644 --- a/PayM/bin/x86/Debug/Model.pdb +++ b/PayM/bin/x86/Debug/Model.pdb Binary files differ diff --git a/PayM/bin/x86/Debug/PayM.dll b/PayM/bin/x86/Debug/PayM.dll index 2f0a384..7b30b9a 100644 --- a/PayM/bin/x86/Debug/PayM.dll +++ b/PayM/bin/x86/Debug/PayM.dll Binary files differ diff --git a/PayM/bin/x86/Debug/PayM.pdb b/PayM/bin/x86/Debug/PayM.pdb index c4b3640..bd8ca73 100644 --- a/PayM/bin/x86/Debug/PayM.pdb +++ b/PayM/bin/x86/Debug/PayM.pdb Binary files differ diff --git a/PayM/bin/x86/Debug/Pub_Class.dll b/PayM/bin/x86/Debug/Pub_Class.dll index 3d6a754..af4bf43 100644 --- a/PayM/bin/x86/Debug/Pub_Class.dll +++ b/PayM/bin/x86/Debug/Pub_Class.dll Binary files differ diff --git a/PayM/bin/x86/Debug/Pub_Class.pdb b/PayM/bin/x86/Debug/Pub_Class.pdb index 40138c1..a4c180e 100644 --- a/PayM/bin/x86/Debug/Pub_Class.pdb +++ b/PayM/bin/x86/Debug/Pub_Class.pdb Binary files differ diff --git a/PayM/bin/x86/Debug/Pub_Control.dll b/PayM/bin/x86/Debug/Pub_Control.dll index 394b4e1..16c2d95 100644 --- a/PayM/bin/x86/Debug/Pub_Control.dll +++ b/PayM/bin/x86/Debug/Pub_Control.dll Binary files differ diff --git a/PayM/bin/x86/Debug/Pub_Control.pdb b/PayM/bin/x86/Debug/Pub_Control.pdb index 8059a13..d8a67a5 100644 --- a/PayM/bin/x86/Debug/Pub_Control.pdb +++ b/PayM/bin/x86/Debug/Pub_Control.pdb Binary files differ diff --git a/PayM/bin/x86/Debug/SQLHelper.dll b/PayM/bin/x86/Debug/SQLHelper.dll index d6ab7f3..a201f7f 100644 --- a/PayM/bin/x86/Debug/SQLHelper.dll +++ b/PayM/bin/x86/Debug/SQLHelper.dll Binary files differ diff --git a/PayM/bin/x86/Debug/SQLHelper.pdb b/PayM/bin/x86/Debug/SQLHelper.pdb index 6265c0b..8589493 100644 --- a/PayM/bin/x86/Debug/SQLHelper.pdb +++ b/PayM/bin/x86/Debug/SQLHelper.pdb Binary files differ diff --git a/PayM/obj/x86/Debug/PayM.csproj.AssemblyReference.cache b/PayM/obj/x86/Debug/PayM.csproj.AssemblyReference.cache index 26c8fce..7252149 100644 --- a/PayM/obj/x86/Debug/PayM.csproj.AssemblyReference.cache +++ b/PayM/obj/x86/Debug/PayM.csproj.AssemblyReference.cache Binary files differ diff --git a/PayM/obj/x86/Debug/PayM.csproj.GenerateResource.cache b/PayM/obj/x86/Debug/PayM.csproj.GenerateResource.cache index 05e9dd9..4b865a8 100644 --- a/PayM/obj/x86/Debug/PayM.csproj.GenerateResource.cache +++ b/PayM/obj/x86/Debug/PayM.csproj.GenerateResource.cache Binary files differ diff --git a/PayM/obj/x86/Debug/PayM.csproj.ResolveComReference.cache b/PayM/obj/x86/Debug/PayM.csproj.ResolveComReference.cache index 307fc5b..ff08134 100644 --- a/PayM/obj/x86/Debug/PayM.csproj.ResolveComReference.cache +++ b/PayM/obj/x86/Debug/PayM.csproj.ResolveComReference.cache Binary files differ diff --git a/PayM/obj/x86/Debug/PayM.dll b/PayM/obj/x86/Debug/PayM.dll index 2f0a384..7b30b9a 100644 --- a/PayM/obj/x86/Debug/PayM.dll +++ b/PayM/obj/x86/Debug/PayM.dll Binary files differ diff --git a/PayM/obj/x86/Debug/PayM.pdb b/PayM/obj/x86/Debug/PayM.pdb index c4b3640..bd8ca73 100644 --- a/PayM/obj/x86/Debug/PayM.pdb +++ b/PayM/obj/x86/Debug/PayM.pdb Binary files differ diff --git "a/WarM/\346\235\241\347\240\201\346\211\223\345\215\260/Gy_BarCodeBill_automaticallyByPLC_New.cs" "b/WarM/\346\235\241\347\240\201\346\211\223\345\215\260/Gy_BarCodeBill_automaticallyByPLC_New.cs" index b681710..6da5b7b 100644 --- "a/WarM/\346\235\241\347\240\201\346\211\223\345\215\260/Gy_BarCodeBill_automaticallyByPLC_New.cs" +++ "b/WarM/\346\235\241\347\240\201\346\211\223\345\215\260/Gy_BarCodeBill_automaticallyByPLC_New.cs" @@ -850,6 +850,8 @@ HBatchNo2 = getBatchNo(); } + HBarCode = ClsPub.isStrNull(grdSub.Rows[i].Cells[HMaterModel2Col].Value) + getHBarCode_MaxNo(); + long HSourceID = 0; string sql = "select * from Gy_Source where HName = '" + comboBox_SourceNameParams.Text + "' "; DataSet ds = oCn.RunProcReturn(sql, "Gy_Source"); @@ -917,7 +919,7 @@ string LIU = ""; int LEN = 4; DataSet ds; - string sql = "select * from h_v_IF_BarCodeBillList Where 婧愬崟鍗曞彿 ='" + grdMain.Rows[0].Cells[HSourceBillNoCol].Value + "' and HMaterID = " + grdMain.Rows[0].Cells[HMaterIDCol].Value + " and HSTOCKORGID = " + HOrgID + " and CONVERT(varchar(100),鏉$爜鏃ユ湡, 23) = '" + HDate + "' order by 鎵瑰彿 desc"; + string sql = "select * from h_v_IF_BarCodeBillList Where HMaterID = " + grdMain.Rows[0].Cells[HMaterIDCol].Value + " and HSTOCKORGID = " + HOrgID + " and CONVERT(varchar(100),鏉$爜鏃ユ湡, 23) = '" + HDate + "' order by 鎵瑰彿 desc"; ds = oCn.RunProcReturn(sql, "h_v_IF_BarCodeBillList"); if (ds != null) { @@ -944,6 +946,69 @@ return HBatchNo; } + + //鐢熸垚褰撳ぉ浜у搧鏉$爜鐨勬祦姘村彿 + private string getHBarCode_MaxNo() + { + string HBarCode_MaxNo = ""; + + //鏃ユ湡鑾峰彇鏂瑰紡 + string sDate = dtpHDate.Value.ToShortDateString(); // + string sYear = ClsPub.isDate(sDate).Year.ToString().Substring(2, 2); + string sPeriod = "0" + ClsPub.isDate(sDate).Month.ToString(); + sPeriod = sPeriod.Substring(sPeriod.Length - 2, 2); + string sDay = "0" + ClsPub.isDate(sDate).Day.ToString(); + sDay = sDay.Substring(sDay.Length - 2, 2); + + string HDate = "20" + sYear + "-" + sPeriod + "-" + sDay; + + //鑾峰彇娴佹按鍙凤細鍥涗綅锛岃鐗╂枡褰撳ぉ鐢熸垚鐨勬潯鐮佹暟 + string LIU = ""; + int LEN = 4; + + //鑾峰彇浜у搧鏉$爜澶囦唤琛ㄤ腑褰撴棩鏈骇鍝佹潯鐮佺紪鍙锋渶澶х殑璁板綍 + long HMaxNo_Bak = 0; //璁板綍浜у搧鏉$爜澶囦唤琛ㄤ腑褰撴棩鏈骇鍝佹潯鐮佺紪鍙锋渶澶х殑璁板綍鐨勬潯鐮佺紪鍙风殑娴佹按鍙� + DataSet ds1; + string sql1 = "select * from Gy_BarCodeBill_SWELL_SubBarCodeBill Where HMaterID = " + grdMain.Rows[0].Cells[HMaterIDCol].Value + " and HSTOCKORGID = " + HOrgID + " and CONVERT(varchar(100),HBarCodeDate, 23) = '" + HDate + "' and HInterID <>0 order by HBarCode desc"; + ds1 = oCn.RunProcReturn(sql1, "Gy_BarCodeBill_SWELL_SubBarCodeBill"); + if (ds1 != null && ds1.Tables[0].Rows.Count>0) + { + string HBarCodeMaxNo = ds1.Tables[0].Rows[0]["HBarCode"].ToString(); + HBarCodeMaxNo = HBarCodeMaxNo.Substring(HBarCodeMaxNo.Length - LEN, LEN); + HMaxNo_Bak = ClsPub.isLong(HBarCodeMaxNo); + } + + ////鑾峰彇鏉$爜妗f涓綋鏃ユ湰浜у搧鏉$爜缂栧彿鏈�澶х殑璁板綍 + long HMaxNo = 0; //璁板綍鏉$爜妗f涓綋鏃ユ湰浜у搧鏉$爜缂栧彿鏈�澶х殑璁板綍鐨勬潯鐮佺紪鍙风殑娴佹按鍙� + DataSet ds; + string sql = "select * from h_v_IF_BarCodeBillList Where HMaterID = " + grdMain.Rows[0].Cells[HMaterIDCol].Value + " and HSTOCKORGID = " + HOrgID + " and CONVERT(varchar(100),鏉$爜鏃ユ湡, 23) = '" + HDate + "' and HInterID <> 0 order by 鏉$爜缂栧彿 desc"; + ds = oCn.RunProcReturn(sql, "h_v_IF_BarCodeBillList"); + if (ds != null && ds.Tables[0].Rows.Count > 0) + { + string HBarCodeMaxNo = ds.Tables[0].Rows[0]["鏉$爜缂栧彿"].ToString(); + HBarCodeMaxNo = HBarCodeMaxNo.Substring(HBarCodeMaxNo.Length - LEN, LEN); + HMaxNo = ClsPub.isLong(HBarCodeMaxNo); + } + + + //鑾峰彇褰撴棩鏈骇鍝� 鍦ㄦ潯鐮佹。妗堝拰浜у搧鏉$爜澶囦唤琛ㄤ腑 鏈�澶х殑娴佹按鍙� + long count = 0; + count = HMaxNo >= HMaxNo_Bak ? HMaxNo : HMaxNo_Bak; + + //涓烘祦姘村彿鍓嶉潰琛ラ浂 + LIU += count + 1; + while (LIU.Length < LEN) //濡傛灉娴佹按鍙峰皬浜�6浣嶆暟鍓嶉潰琛�0 + { + LIU = "0" + LIU; + } + + //鎷兼帴鎵瑰彿 + HBarCode_MaxNo = sYear + sPeriod + sDay + LIU; + + return HBarCode_MaxNo; + } + #endregion + #endregion #region 鐩戝惉閫氳 @@ -1712,7 +1777,6 @@ { return DBUtility.Xt_BaseBillFun.Fun_GetCol(sCol, grdList); } - #endregion #endregion diff --git "a/WarM/\346\235\241\347\240\201\346\211\223\345\215\260/Gy_BarCodeBill_automaticallyByPLC_New.designer.cs" "b/WarM/\346\235\241\347\240\201\346\211\223\345\215\260/Gy_BarCodeBill_automaticallyByPLC_New.designer.cs" index 4ee964d..0831a25 100644 --- "a/WarM/\346\235\241\347\240\201\346\211\223\345\215\260/Gy_BarCodeBill_automaticallyByPLC_New.designer.cs" +++ "b/WarM/\346\235\241\347\240\201\346\211\223\345\215\260/Gy_BarCodeBill_automaticallyByPLC_New.designer.cs" @@ -296,7 +296,7 @@ this.bc.ImageScaling = System.Windows.Forms.ToolStripItemImageScaling.None; this.bc.ImageTransparentColor = System.Drawing.Color.Magenta; this.bc.Name = "bc"; - this.bc.Size = new System.Drawing.Size(35, 47); + this.bc.Size = new System.Drawing.Size(60, 60); this.bc.Text = "鐢熸垚"; this.bc.TextAlign = System.Drawing.ContentAlignment.BottomCenter; this.bc.TextImageRelation = System.Windows.Forms.TextImageRelation.ImageAboveText; @@ -498,8 +498,9 @@ this.tc.ImageAlign = System.Drawing.ContentAlignment.BottomCenter; this.tc.ImageScaling = System.Windows.Forms.ToolStripItemImageScaling.None; this.tc.ImageTransparentColor = System.Drawing.Color.White; + this.tc.Margin = new System.Windows.Forms.Padding(100, 2, 0, 3); this.tc.Name = "tc"; - this.tc.Size = new System.Drawing.Size(35, 47); + this.tc.Size = new System.Drawing.Size(60, 60); this.tc.Text = "閫�鍑�"; this.tc.TextAlign = System.Drawing.ContentAlignment.BottomCenter; this.tc.TextImageRelation = System.Windows.Forms.TextImageRelation.ImageAboveText; @@ -593,11 +594,10 @@ // cmdSourceBillNo // this.cmdSourceBillNo.Image = ((System.Drawing.Image)(resources.GetObject("cmdSourceBillNo.Image"))); - this.cmdSourceBillNo.ImageAlign = System.Drawing.ContentAlignment.TopRight; - this.cmdSourceBillNo.Location = new System.Drawing.Point(1214, 11); + this.cmdSourceBillNo.Location = new System.Drawing.Point(1214, -4); this.cmdSourceBillNo.Margin = new System.Windows.Forms.Padding(4); this.cmdSourceBillNo.Name = "cmdSourceBillNo"; - this.cmdSourceBillNo.Size = new System.Drawing.Size(33, 33); + this.cmdSourceBillNo.Size = new System.Drawing.Size(60, 60); this.cmdSourceBillNo.TabIndex = 99; this.cmdSourceBillNo.UseVisualStyleBackColor = true; this.cmdSourceBillNo.Click += new System.EventHandler(this.cmdSourceBillNo_Click_1); @@ -638,6 +638,7 @@ // radioButton_HIsUsingBatchNo // this.radioButton_HIsUsingBatchNo.AutoSize = true; + this.radioButton_HIsUsingBatchNo.Enabled = false; this.radioButton_HIsUsingBatchNo.Location = new System.Drawing.Point(874, 190); this.radioButton_HIsUsingBatchNo.Name = "radioButton_HIsUsingBatchNo"; this.radioButton_HIsUsingBatchNo.Size = new System.Drawing.Size(141, 22); @@ -657,9 +658,9 @@ // // button_stopListen // - this.button_stopListen.Location = new System.Drawing.Point(404, 250); + this.button_stopListen.Location = new System.Drawing.Point(404, 223); this.button_stopListen.Name = "button_stopListen"; - this.button_stopListen.Size = new System.Drawing.Size(151, 35); + this.button_stopListen.Size = new System.Drawing.Size(192, 62); this.button_stopListen.TabIndex = 97; this.button_stopListen.Text = "鍋滄鐩戝惉"; this.button_stopListen.UseVisualStyleBackColor = true; @@ -711,9 +712,9 @@ // // button_startListen // - this.button_startListen.Location = new System.Drawing.Point(214, 250); + this.button_startListen.Location = new System.Drawing.Point(187, 223); this.button_startListen.Name = "button_startListen"; - this.button_startListen.Size = new System.Drawing.Size(133, 35); + this.button_startListen.Size = new System.Drawing.Size(160, 62); this.button_startListen.TabIndex = 96; this.button_startListen.Text = "寮�濮嬬洃鍚�"; this.button_startListen.UseVisualStyleBackColor = true; @@ -906,7 +907,7 @@ // this.button_resetParams.Location = new System.Drawing.Point(590, 173); this.button_resetParams.Name = "button_resetParams"; - this.button_resetParams.Size = new System.Drawing.Size(89, 40); + this.button_resetParams.Size = new System.Drawing.Size(153, 75); this.button_resetParams.TabIndex = 105; this.button_resetParams.Text = "閲� 缃�"; this.button_resetParams.UseVisualStyleBackColor = true; @@ -914,9 +915,9 @@ // // button_saveParams // - this.button_saveParams.Location = new System.Drawing.Point(377, 173); + this.button_saveParams.Location = new System.Drawing.Point(311, 173); this.button_saveParams.Name = "button_saveParams"; - this.button_saveParams.Size = new System.Drawing.Size(89, 40); + this.button_saveParams.Size = new System.Drawing.Size(155, 75); this.button_saveParams.TabIndex = 104; this.button_saveParams.Text = "淇� 瀛�"; this.button_saveParams.UseVisualStyleBackColor = true; diff --git "a/WarM/\346\235\241\347\240\201\346\211\223\345\215\260/Gy_PackBarCodeBill_automaticallyByPLC.Designer.cs" "b/WarM/\346\235\241\347\240\201\346\211\223\345\215\260/Gy_PackBarCodeBill_automaticallyByPLC.Designer.cs" index c435527..703f4cb 100644 --- "a/WarM/\346\235\241\347\240\201\346\211\223\345\215\260/Gy_PackBarCodeBill_automaticallyByPLC.Designer.cs" +++ "b/WarM/\346\235\241\347\240\201\346\211\223\345\215\260/Gy_PackBarCodeBill_automaticallyByPLC.Designer.cs" @@ -34,6 +34,7 @@ this.tabControl_MainInfo = new System.Windows.Forms.TabControl(); this.tabPage_BillInfo = new System.Windows.Forms.TabPage(); this.gbUp = new System.Windows.Forms.GroupBox(); + this.button_produceTemp = new System.Windows.Forms.Button(); this.label_sBillNo = new System.Windows.Forms.Label(); this.textBox_sBillNo = new System.Windows.Forms.TextBox(); this.label_sBillID = new System.Windows.Forms.Label(); @@ -121,6 +122,7 @@ // gbUp // this.gbUp.BackColor = System.Drawing.Color.Transparent; + this.gbUp.Controls.Add(this.button_produceTemp); this.gbUp.Controls.Add(this.label_sBillNo); this.gbUp.Controls.Add(this.textBox_sBillNo); this.gbUp.Controls.Add(this.label_sBillID); @@ -149,6 +151,16 @@ this.gbUp.Size = new System.Drawing.Size(1374, 310); this.gbUp.TabIndex = 33; this.gbUp.TabStop = false; + // + // button_produceTemp + // + this.button_produceTemp.Location = new System.Drawing.Point(829, 215); + this.button_produceTemp.Name = "button_produceTemp"; + this.button_produceTemp.Size = new System.Drawing.Size(158, 70); + this.button_produceTemp.TabIndex = 123; + this.button_produceTemp.Text = "涓存椂缁勬墭"; + this.button_produceTemp.UseVisualStyleBackColor = true; + this.button_produceTemp.Click += new System.EventHandler(this.button_produceTemp_Click); // // label_sBillNo // @@ -193,9 +205,9 @@ // // button_produceByHand // - this.button_produceByHand.Location = new System.Drawing.Point(591, 250); + this.button_produceByHand.Location = new System.Drawing.Point(591, 215); this.button_produceByHand.Name = "button_produceByHand"; - this.button_produceByHand.Size = new System.Drawing.Size(151, 35); + this.button_produceByHand.Size = new System.Drawing.Size(186, 70); this.button_produceByHand.TabIndex = 118; this.button_produceByHand.Text = "鏈弧鎵樼敓鎴�"; this.button_produceByHand.UseVisualStyleBackColor = true; @@ -276,9 +288,9 @@ // // button_stopListen // - this.button_stopListen.Location = new System.Drawing.Point(404, 250); + this.button_stopListen.Location = new System.Drawing.Point(379, 215); this.button_stopListen.Name = "button_stopListen"; - this.button_stopListen.Size = new System.Drawing.Size(151, 35); + this.button_stopListen.Size = new System.Drawing.Size(176, 70); this.button_stopListen.TabIndex = 97; this.button_stopListen.Text = "鍋滄缁勬墭"; this.button_stopListen.UseVisualStyleBackColor = true; @@ -287,11 +299,11 @@ // textBox_HPackBarCode // this.textBox_HPackBarCode.BackColor = System.Drawing.SystemColors.ScrollBar; - this.textBox_HPackBarCode.Enabled = false; this.textBox_HPackBarCode.Location = new System.Drawing.Point(122, 81); this.textBox_HPackBarCode.Name = "textBox_HPackBarCode"; this.textBox_HPackBarCode.Size = new System.Drawing.Size(280, 28); this.textBox_HPackBarCode.TabIndex = 43; + this.textBox_HPackBarCode.KeyPress += new System.Windows.Forms.KeyPressEventHandler(this.textBox_HPackBarCode__KeyPress); // // dtpHDate // @@ -312,9 +324,9 @@ // // button_startListen // - this.button_startListen.Location = new System.Drawing.Point(214, 250); + this.button_startListen.Location = new System.Drawing.Point(147, 215); this.button_startListen.Name = "button_startListen"; - this.button_startListen.Size = new System.Drawing.Size(133, 35); + this.button_startListen.Size = new System.Drawing.Size(200, 70); this.button_startListen.TabIndex = 96; this.button_startListen.Text = "鑷姩缁勬墭"; this.button_startListen.UseVisualStyleBackColor = true; @@ -387,16 +399,16 @@ // this.button_resetParams.Location = new System.Drawing.Point(590, 173); this.button_resetParams.Name = "button_resetParams"; - this.button_resetParams.Size = new System.Drawing.Size(89, 40); + this.button_resetParams.Size = new System.Drawing.Size(134, 81); this.button_resetParams.TabIndex = 105; this.button_resetParams.Text = "閲� 缃�"; this.button_resetParams.UseVisualStyleBackColor = true; // // button_saveParams // - this.button_saveParams.Location = new System.Drawing.Point(377, 173); + this.button_saveParams.Location = new System.Drawing.Point(311, 173); this.button_saveParams.Name = "button_saveParams"; - this.button_saveParams.Size = new System.Drawing.Size(89, 40); + this.button_saveParams.Size = new System.Drawing.Size(155, 81); this.button_saveParams.TabIndex = 104; this.button_saveParams.Text = "淇� 瀛�"; this.button_saveParams.UseVisualStyleBackColor = true; @@ -638,7 +650,7 @@ this.toolStripButton_Delete.ImageScaling = System.Windows.Forms.ToolStripItemImageScaling.None; this.toolStripButton_Delete.ImageTransparentColor = System.Drawing.Color.White; this.toolStripButton_Delete.Name = "toolStripButton_Delete"; - this.toolStripButton_Delete.Size = new System.Drawing.Size(35, 47); + this.toolStripButton_Delete.Size = new System.Drawing.Size(60, 60); this.toolStripButton_Delete.Text = "鍒犻櫎"; this.toolStripButton_Delete.TextAlign = System.Drawing.ContentAlignment.BottomCenter; this.toolStripButton_Delete.TextImageRelation = System.Windows.Forms.TextImageRelation.ImageAboveText; @@ -651,8 +663,9 @@ this.tc.ImageAlign = System.Drawing.ContentAlignment.BottomCenter; this.tc.ImageScaling = System.Windows.Forms.ToolStripItemImageScaling.None; this.tc.ImageTransparentColor = System.Drawing.Color.White; + this.tc.Margin = new System.Windows.Forms.Padding(100, 2, 0, 3); this.tc.Name = "tc"; - this.tc.Size = new System.Drawing.Size(35, 47); + this.tc.Size = new System.Drawing.Size(60, 60); this.tc.Text = "閫�鍑�"; this.tc.TextAlign = System.Drawing.ContentAlignment.BottomCenter; this.tc.TextImageRelation = System.Windows.Forms.TextImageRelation.ImageAboveText; @@ -743,5 +756,6 @@ private System.Windows.Forms.ToolStripSeparator toolStripSeparator10; private System.Windows.Forms.ToolStripButton tc; private System.Windows.Forms.ToolStripButton toolStripButton_Delete; + private System.Windows.Forms.Button button_produceTemp; } } \ No newline at end of file diff --git "a/WarM/\346\235\241\347\240\201\346\211\223\345\215\260/Gy_PackBarCodeBill_automaticallyByPLC.cs" "b/WarM/\346\235\241\347\240\201\346\211\223\345\215\260/Gy_PackBarCodeBill_automaticallyByPLC.cs" index bec4a79..a53a36e 100644 --- "a/WarM/\346\235\241\347\240\201\346\211\223\345\215\260/Gy_PackBarCodeBill_automaticallyByPLC.cs" +++ "b/WarM/\346\235\241\347\240\201\346\211\223\345\215\260/Gy_PackBarCodeBill_automaticallyByPLC.cs" @@ -347,12 +347,18 @@ //鏈弧鎵樼敓鎴� 鎸夐挳 鐐瑰嚮浜嬩欢 private void button_produceByHand_Click(object sender, EventArgs e) { - if (HQty == 0) + try { - MessageBox.Show("璇锋壂鐮佸瓙鏉$爜!"); - return; + if (HQty == 0) + { + MessageBox.Show("璇锋壂鐮佸瓙鏉$爜!"); + return; + } + this.Sub_SaveBill(); + }catch(Exception ex) + { + MessageBox.Show(ex.Message); } - this.Sub_SaveBill(); } //鑷姩缁勬墭 @@ -379,6 +385,8 @@ comboBox_SourceNameParams.Enabled = false; button_saveParams.Enabled = false; + + textBox_HBarCode.Focus(); } //鍋滄缁勬墭 @@ -406,22 +414,28 @@ { if(isStartListen == 1) { - if(HQty == DBUtility.ClsPub.isDoule(textBox_PackQty.Text)) + try { - this.Sub_SaveBill(); - - //璁剧疆鎵撳嵃妯℃澘锛屾墦鍗� - grdSub.Rows[0].Cells[0].Value = "*"; - Report = new GridppReport(); - Report.LoadFromFile(DBUtility.ClsPub.AppPath + @"\" + textBox_PrintModelParams.Text + ".grf"); //here . - Report.BeforePostRecord += new _IGridppReportEvents_BeforePostRecordEventHandler(ReportBeforePostRecord); - Report.FetchRecord += new _IGridppReportEvents_FetchRecordEventHandler(ReportFetchRecordByDataTable); - Report.PrintEnd += new _IGridppReportEvents_PrintEndEventHandler(ReportPrintEnd); - if (comboBox_PrinterParams.Text != "") + if (HQty == DBUtility.ClsPub.isDoule(textBox_PackQty.Text)) { - Report.Printer.PrinterName = comboBox_PrinterParams.Text.Replace("(榛樿)", ""); + this.Sub_SaveBill(); + + //璁剧疆鎵撳嵃妯℃澘锛屾墦鍗� + grdSub.Rows[0].Cells[0].Value = "*"; + Report = new GridppReport(); + Report.LoadFromFile(DBUtility.ClsPub.AppPath + @"\" + textBox_PrintModelParams.Text + ".grf"); //here . + Report.BeforePostRecord += new _IGridppReportEvents_BeforePostRecordEventHandler(ReportBeforePostRecord); + Report.FetchRecord += new _IGridppReportEvents_FetchRecordEventHandler(ReportFetchRecordByDataTable); + Report.PrintEnd += new _IGridppReportEvents_PrintEndEventHandler(ReportPrintEnd); + if (comboBox_PrinterParams.Text != "") + { + Report.Printer.PrinterName = comboBox_PrinterParams.Text.Replace("(榛樿)", ""); + } + Report.Print(false); } - Report.Print(false); + }catch(Exception ex) + { + MessageBox.Show(ex.Message); } } } @@ -430,25 +444,29 @@ //鐢熸垚鎵樼洏鏉$爜 private bool Sub_SaveBill() { - //鑾峰彇缁勭粐淇℃伅 - HOrgID = get_ORGANIZATIONSIDByName(cmbHOrgID.Text); - HOrgNumber = get_ORGANIZATIONSNOByName(cmbHOrgID.Text); - - if (HOrgID == -1) + try { - MessageBox.Show("閫夋嫨缁勭粐鏈夐敊璇紒"); - return false; - } + //鑾峰彇缁勭粐淇℃伅 + HOrgID = get_ORGANIZATIONSIDByName(cmbHOrgID.Text); + HOrgNumber = get_ORGANIZATIONSNOByName(cmbHOrgID.Text); + if (HOrgID == -1) + { + throw new Exception("閫夋嫨缁勭粐鏈夐敊璇紒"); + } - if (!Sub_AllowSave())//鍗曟嵁瀹屾暣鎬у垽鏂� + if (!Sub_AllowSave())//鍗曟嵁瀹屾暣鎬у垽鏂� + { + throw new Exception("鍗曟嵁瀹屾暣鎬у垽鏂け璐ワ紒"); + } + + SaveBarCode(); + return true; + }catch(Exception ex) { - return false; + throw new Exception(ex.Message); } - - - SaveBarCode(); - return true; + } //鍗曟嵁瀹屾暣鎬у垽鏂� 鏈畬鎴� @@ -506,6 +524,15 @@ sSQLMul[1] = " exec h_p_WMS_SetMaxNo_QTY '" + sTMNumber + "'," + HQty.ToString() + " "; + //鍒ゆ柇褰撳墠鎵樼洏鏉$爜鏄惁宸茬粡閫氳繃涓存椂缁勬墭鍦ㄦ潯鐮佹。妗堜腑鐢熸垚浜嗭紝鑻ュ凡缁忕敓鎴愪簡鍒欎笉闇�瑕佸湪鎻掑叆 + ds = oCn.RunProcReturn("select * from Gy_BarCodeBill where HBarCode = '" + textBox_HPackBarCode.Text + "' and HSTOCKORGID = " + HOrgID, "Gy_BarCodeBill"); + if (ds != null && ds.Tables[0].Rows.Count > 0) + { + sSQLMul[0] = ""; + } + + oCn.BeginTran(); + if (getRunProcByMul_Back(sSQLMul, ref DBUtility.ClsPub.sExeReturnInfo)) { //MessageBox.Show("鏉$爜鐢熸垚瀹屾瘯锛�"); @@ -517,15 +544,21 @@ setPackBarCodeBillData(); getDisplay_GrdMain(); + + oCn.Commit(); } else { //MessageBox.Show("鏉$爜鐢熸垚澶辫触锛�" + DBUtility.ClsPub.sExeReturnInfo); + oCn.RollBack(); } + + //oCn.Commit(); } catch (Exception e) { - //MessageBox.Show("鏉$爜鐢熸垚澶辫触锛�" + e.Message); + oCn.RollBack(); + throw new Exception(e.Message); } } @@ -540,27 +573,30 @@ { for (int i = 0; i < 1; i++) { - oCn.RunProc(sSQL[i]); + if (sSQL[i].Length > 0) + { + oCn.RunProc(sSQL[i]); + } } - - + //涓婁紶缁勬墭淇℃伅鍒版湇鍔″櫒 send(); + oCn.Commit(); } else { - sErrMsg = "娌℃湁鏁版嵁锛�"; oCn.Commit(); - return false; + sErrMsg = "娌℃湁鏁版嵁锛�"; + throw new Exception(sErrMsg); } - oCn.Commit(); + //oCn.Commit(); return true; } catch (Exception e) { - sErrMsg = e.Message; oCn.RollBack(); - return false; + sErrMsg = e.Message; + throw new Exception(sErrMsg); } } #endregion @@ -570,16 +606,22 @@ private void send() { string err = ""; - if (!CheckModRight(ModRightNamePackUnion, DBUtility.ClsPub.CurUserName, ref err)) - { - MessageBox.Show(err); - return; - } + //if (!CheckModRight(ModRightNamePackUnion, DBUtility.ClsPub.CurUserName, ref err)) + //{ + // MessageBox.Show(err); + // return; + //} //if (MessageBox.Show("纭畾瑕佷笂浼狅紵", "鎻愮ず", MessageBoxButtons.OKCancel, MessageBoxIcon.Question, MessageBoxDefaultButton.Button2) == DialogResult.Cancel) //{ // return; //} - LoadData(); + try + { + LoadData(); + }catch(Exception ex) + { + throw new Exception(ex.Message); + } } //鍒ゆ柇鐢ㄦ埛鏉冮檺 @@ -608,7 +650,7 @@ //鍒ゆ柇鏄惁鏁版嵁瀹屾暣 if (AllowLoadData() == false) { - return; + throw new Exception("鏁版嵁瀹屾暣鎬у垽鏂け璐ワ紒"); } try { @@ -626,14 +668,14 @@ } else { - MessageBox.Show("鐢熸垚澶辫触锛佸師鍥�:" + err); - return; + string error = "鐢熸垚澶辫触锛佸師鍥�:" + err; + throw new Exception(error); } } catch (Exception e) { - MessageBox.Show("鍗曟嵁鍙凤細" + textBox_sBillID.Text + "锛屽崟鎹甀D锛�" + textBox_sBillID.Text + "锛涗笂浼犲け璐ワ紒" + e.Message); - return; + string error = "鍗曟嵁鍙凤細" + textBox_sBillID.Text + "锛屽崟鎹甀D锛�" + textBox_sBillID.Text + "锛涗笂浼犲け璐ワ紒" + e.Message; + throw new Exception(error); } } @@ -657,37 +699,37 @@ public bool set_SavePackUnionBill_Add(Int64 HInterID, string HBillType, string HBillNo, string HBarCode_Pack, string HMaker, Int64 HStockOrgID, ref string sErrMsg) { SQLHelper.ClsCN oCn = new SQLHelper.ClsCN(); + oCn.BeginTran(); try { - oCn.BeginTran(); DataSet ds = oCn.RunProcReturn("exec h_p_Sc_PackUnionBill_Insert_New " + HInterID.ToString() + ",'" + HBillNo + "','" + HBillType + "','" + HBarCode_Pack + "','" + HMaker + "'," + HStockOrgID.ToString(), "h_p_Sc_PackUnionBill_Insert_New"); if (ds == null || ds.Tables[0].Rows.Count == 0) { - sErrMsg = "鍗曟嵁鍙凤細" + HBillNo + "锛屽崟鎹甀D锛�" + HInterID + "锛涗笂浼犲け璐ワ紒"; oCn.RollBack(); - return false; + sErrMsg = "鍗曟嵁鍙凤細" + HBillNo + "锛屽崟鎹甀D锛�" + HInterID + "锛涗笂浼犲け璐ワ紒"; + throw new Exception(sErrMsg); } else { if (DBUtility.ClsPub.isLong(ds.Tables[0].Rows[0][0]) == 1) { - sErrMsg = "涓婁紶澶辫触锛屽崟鎹彿锛�" + HBillNo + "锛屽崟鎹甀D锛�" + HInterID + "锛�" + DBUtility.ClsPub.isStrNull(ds.Tables[0].Rows[0]["HRemark"]); oCn.RollBack(); - return false; + sErrMsg = "涓婁紶澶辫触锛屽崟鎹彿锛�" + HBillNo + "锛屽崟鎹甀D锛�" + HInterID + "锛�" + DBUtility.ClsPub.isStrNull(ds.Tables[0].Rows[0]["HRemark"]); + throw new Exception(sErrMsg); } else { - //sErrMsg = "鐢熸垚鐢熶骇缁勬墭鍗曟垚鍔燂紒鍗曟嵁鍙蜂负锛�" + HBillNo; oCn.Commit(); + //sErrMsg = "鐢熸垚鐢熶骇缁勬墭鍗曟垚鍔燂紒鍗曟嵁鍙蜂负锛�" + HBillNo; return true; } } } catch (Exception e) { - sErrMsg = "鐢熸垚鐢熶骇缁勬墭鍗曞け璐ワ紒" + e.Message; oCn.RollBack(); - return false; + sErrMsg = "鐢熸垚鐢熶骇缁勬墭鍗曞け璐ワ紒" + e.Message; + throw new Exception(sErrMsg); } } @@ -713,11 +755,9 @@ } catch (Exception e2) { - //if (DBUtility.ClsPub.bSound) - //{ - // DBUtility.ClsPub.MessageBeep((int)DBUtility.ClsPub.BeepType.Warning); - //} - MessageBox.Show("鍙戠敓缃戠粶寮傚父锛岃绋嶅悗鍐嶈瘯锛�"); + textBox_HBarCode.Text = ""; + textBox_HBarCode.Focus(); + MessageBox.Show(e2.Message); } } //灏嗘潯鐮佷俊鎭啓鍏ユ潯鐮佸嚭鍏ュ簱涓存椂琛� @@ -741,13 +781,13 @@ } else { - MessageBox.Show(err); - return; + throw new Exception(err); } } catch (Exception e) { - MessageBox.Show("鎵弿瀛愭潯鐮侊紝鍐欏叆涓存椂琛ㄤ俊鎭け璐ワ紒" + e.Message + err); + string sError = "鎵弿瀛愭潯鐮侊紝鍐欏叆涓存椂琛ㄤ俊鎭け璐ワ紒" + e.Message + err; + throw new Exception(sError); } } @@ -1161,9 +1201,196 @@ } } + #endregion - + + #region 涓存椂缁勬墭 + #region 涓存椂缁勬墭 鎸夐挳鐐瑰嚮浜嬩欢 + private void button_produceTemp_Click(object sender, EventArgs e) + { + if (HQty == 0) + { + MessageBox.Show("璇锋壂鐮佸瓙鏉$爜!"); + return; + } + this.produceTemp(); + + //璁剧疆鎵撳嵃妯℃澘锛屾墦鍗� + grdSub.Rows[0].Cells[0].Value = "*"; + Report = new GridppReport(); + Report.LoadFromFile(DBUtility.ClsPub.AppPath + @"\" + textBox_PrintModelParams.Text + "_Temp" + ".grf"); //here . + Report.BeforePostRecord += new _IGridppReportEvents_BeforePostRecordEventHandler(ReportBeforePostRecord); + Report.FetchRecord += new _IGridppReportEvents_FetchRecordEventHandler(ReportFetchRecordByDataTable); + Report.PrintEnd += new _IGridppReportEvents_PrintEndEventHandler(ReportPrintEnd); + if (comboBox_PrinterParams.Text != "") + { + Report.Printer.PrinterName = comboBox_PrinterParams.Text.Replace("(榛樿)", ""); + } + Report.Print(false); + } + #endregion + + #region 涓存椂缁勬墭 + private void produceTemp() + { + //鍒ゆ柇鏉$爜妗f涓槸鍚﹀凡缁忓瓨鍦ㄨ鎵樻潯鐮侊紝鑻ュ瓨鍦紝鍒欎笉闇�瑕佸啀鍒涘缓銆傞噸鏂板姞杞界晫闈㈠嵆鍙�� + DataSet ds_getPackBarCode; + string sql_getPackBarCode = "select * from Gy_BarCodeBill where HBarCode = '" + textBox_HPackBarCode.Text + "'"; + ds_getPackBarCode = oCn.RunProcReturn(sql_getPackBarCode, "Gy_BarCodeBill"); + if (ds_getPackBarCode != null && ds_getPackBarCode.Tables[0].Rows.Count > 0) + { + //閲嶆柊鍔犺浇鐣岄潰 + getDisplay_grdSub(); + + setPackBarCodeBillData(); + + getDisplay_GrdMain(); + return; + } + + + //鑾峰彇缁勭粐淇℃伅 + HOrgID = get_ORGANIZATIONSIDByName(cmbHOrgID.Text); + HOrgNumber = get_ORGANIZATIONSNOByName(cmbHOrgID.Text); + + //楠岃瘉缁勭粐 + if (HOrgID == -1) + { + MessageBox.Show("閫夋嫨缁勭粐鏈夐敊璇紒"); + return; + } + + //鍗曟嵁瀹屾暣鎬у垽鏂� + if (!Sub_AllowSave()) + { + return; + } + + //鑾峰彇褰撳墠浜х嚎鍙婁骇绾垮唴鐮� + long HSourceID = 0; + string sql = "select * from Gy_Source where HName = '" + comboBox_SourceNameParams.Text + "' "; + DataSet ds = oCn.RunProcReturn(sql, "Gy_Source"); + if (ds != null && ds.Tables[0].Rows.Count > 0) + { + HSourceID = DBUtility.ClsPub.isLong(ds.Tables[0].Rows[0]["HItemID"].ToString()); + } + + //鎷兼帴涓存椂缁勬墭鏃讹紝鎵樻潯鐮佺殑鐢熸垚璇彞 + sSQLMul = new string[2]; + sSQLMul[0] = "insert into Gy_BarCodeBill (HBarCode,HBarCodeType,HMaterID,HUnitID,HQty" + + ",HBatchNo,HSupID,HGroupID,HMaker,HMakeDate,HPrintQty,HinitQty" + + ",HSourceInterID,HSourceEntryID,HSourceBillNo,HSourceBillType,HEndQty " + + ",HBarcodeQtys,HBarcodeNo,HDeptID,HWhID,HSPID,HRemark " + + ",HCusID,HCusType,HEndDate,HWorkLineName,HJiaYe " + + ",HPressModel,HCusModel,HMaterialModel,HColor,HBarCodeDate " + + ",HLogo,HPackageSize,HMaterialJQty,HMaterialMQty,HCustomBatchNo " + + ",HSTOCKORGID,HOWNERID,HBeginDate,HSeOrderBillNo,HGBBarCode " + + ",POOrderBillNo,HInterID,HInitSourceEntryID,HBarCode_Pack " + + ",HMaterName,HMaterModel,HPinfan,HAuxPropID,HMTONo " + + ",HCustomQty1,HLayerNumber,HCusBarCode,HBarCodeStatus,HSourceID " + + ") values (" + + "'" + textBox_HPackBarCode.Text + "','" + HBarCodeType + "',0,0,1" + + ",'',0,0,'" + ClsPub.CurUserName + "',getdate(),0,1" + + ",0,0,'','',''" + + "," + HQty.ToString() + ",1,0,0,0,''" + + ",0,'','','',''" + + ",'','','','','" + sDate + "'" + + ",'','',0,0,''" + + "," + HOrgID.ToString() + "," + HOrgID.ToString() + ",'','',''" + + ",''," + HInterID.ToString() + ",0,'" + textBox_HPackBarCode.Text + "'" + + ",'','','',0,''" + + ",0,0,'',''," + HSourceID + + ")"; + //鎷兼帴 鏇存柊 鎵樻潯鐮佹祦姘村彿 鐨剆ql璇彞 + sSQLMul[1] = " exec h_p_WMS_SetMaxNo_QTY '" + sTMNumber + "'," + HQty.ToString() + " "; + + if (sSQLMul.Length > 0) + { + //鎵ц鎵樻潯鐮佺殑鐢熸垚璇彞涓庢墭鏉$爜娴佹按鍙风殑鏇存柊璇彞 + for (int i = 0; i < 1; i++) + { + oCn.RunProc(sSQLMul[i]); + } + + //閲嶆柊鍔犺浇鐣岄潰 + getDisplay_grdSub(); + + setPackBarCodeBillData(); + + getDisplay_GrdMain(); + } + else + { + MessageBox.Show("娌℃湁鏁版嵁锛�"); + return; + } + } + #endregion + + #region 鎵樻潯鐮� 鎵爜 + private void textBox_HPackBarCode__KeyPress(object sender, KeyPressEventArgs e) + { + if (e.KeyChar == (char)Keys.Return) + { + //鑾峰彇鎵弿鐨勬墭鏉$爜 + string HPackBarCode = textBox_HPackBarCode.Text; + //鏉$爜绫诲瀷 + HBarCodeType = ClsPub.isStrNull(cmbHBarCodeType.Text); + //鑾峰彇缁勭粐淇℃伅 + HOrgID = get_ORGANIZATIONSIDByName(cmbHOrgID.Text); + HOrgNumber = get_ORGANIZATIONSNOByName(cmbHOrgID.Text); + + //澹版槑鐢ㄤ簬鏁版嵁搴撴煡璇㈢殑鍙橀噺 + string sql = ""; + DataSet ds; + + //鍒ゆ柇 鎵樻潯鐮佹槸鍚﹀凡缁忕敓鎴愮粍鎵樺崟 + sql = "select * from Sc_PackUnionBillMain where HBarCode_Pack = '" + HPackBarCode + "'"; + ds = oCn.RunProcReturn(sql, "Sc_PackUnionBillMain"); + if (ds != null && ds.Tables[0].Rows.Count > 0) + { + MessageBox.Show("鎵樻潯鐮乕" + HPackBarCode + "]宸茬粡缁勬墭锛�"); + return; + } + + + //鑾峰彇褰撳墠浜х嚎 + long HSourceID = 0; + sql = "select * from Gy_Source where HName = '" + comboBox_SourceNameParams.Text + "'"; + ds = oCn.RunProcReturn(sql, "Gy_Source"); + if (ds != null && ds.Tables[0].Rows.Count > 0) + { + HSourceID = DBUtility.ClsPub.isLong(ds.Tables[0].Rows[0]["HItemID"].ToString()); + } + + + //鑾峰彇缂撳瓨鍒楄〃涓� 鎵樻潯鐮� 瀵瑰簲鐨� 缁勬墭璁板綍 + sql = "select top(1) a.* from Sc_PackUnionBill_Temp as a inner join Gy_BarCodeBill as b on a.HBarCode = b.HBarCode where a.HBarCode_Pack = '" + HPackBarCode + "' and b.HSourceID = " + HSourceID + " and a.HStockorgID = " + HOrgID; + ds = oCn.RunProcReturn(sql, "Sc_PackUnionBill_Temp"); + if (ds == null || ds.Tables[0].Rows.Count == 0) + { + MessageBox.Show("缂撳瓨鍒楄〃涓湭鏌ヨ鍒拌鎵樻潯鐮佷笌瀛愭潯鐮佺殑缁勬墭璁板綍锛�"); + return; + } + else + { + string HBarCode_Pack = ds.Tables[0].Rows[0]["HBarCode_Pack"].ToString(); + long HBillID = DBUtility.ClsPub.isLong(ds.Tables[0].Rows[0]["HInterID"].ToString()); + string HBillNo = ds.Tables[0].Rows[0]["HBillNo"].ToString(); + + textBox_HPackBarCode.Text = HBarCode_Pack; + textBox_sBillID.Text = HBillID.ToString(); + textBox_sBillNo.Text = HBillNo; + + getDisplay_GrdMain(); + } + } + } + #endregion + #endregion + + } } diff --git a/WebAPI/Controllers/BaseSet/Gy_CheckItemController.cs b/WebAPI/Controllers/BaseSet/Gy_CheckItemController.cs index 73d3d35..f62fb7d 100644 --- a/WebAPI/Controllers/BaseSet/Gy_CheckItemController.cs +++ b/WebAPI/Controllers/BaseSet/Gy_CheckItemController.cs @@ -19,6 +19,7 @@ private json objJsonResult = new json(); SQLHelper.ClsCN oCN = new SQLHelper.ClsCN(); DataSet ds; + public DAL.ClsGy_QCCheckItem_Ctl BillOld = new DAL.ClsGy_QCCheckItem_Ctl(); #region 妫�楠岄」鐩垪琛ㄦ暟鎹� /// <summary> @@ -254,6 +255,18 @@ long HQCCheckClassID = list[0].HQCCheckClassID; string HDefaultResult = list[0].HDefaultResult; + long HUnitID = list[0].HUnitID; + string HAnalysisMethod = list[0].HAnalysisMethod; + string HDefectLevel = list[0].HDefectLevel; + long HDestructInspect = list[0].HDestructInspect; + long HKeyInspect = list[0].HKeyInspect; + long HQualityStdID = list[0].HQualityStdID; + long HInspectMethodID = list[0].HInspectMethodID; + long HInspectInstruMentID = list[0].HInspectInstruMentID; + long HInspectBasisID = list[0].HInspectBasisID; + long HSampleSchemeID = list[0].HSampleSchemeID; + long HISsystemSet = list[0].HISsystemSet; + if (!DBUtility.ClsPub.AllowNumber(HNumber)) { objJsonResult.code = "0"; @@ -270,9 +283,13 @@ //涓昏〃 oCN.RunProc("Insert Into Gy_QCCheckItem " + "(HNumber,HName,HHelpCode,HShortNumber,HParentID" + - ",HLevel,HEndFlag,HStopflag,HRemark,HUseFlag,HQCCheckClassID,HDefaultResult) " + + ",HLevel,HEndFlag,HStopflag,HRemark,HUseFlag,HQCCheckClassID,HDefaultResult" + + ",HAnalysisMethod,HDefectLevel,HUnitID,HDestructInspect,HKeyInspect,HQualityStdID" + + ",HInspectMethodID,HInspectInstruMentID,HInspectBasisID,HSampleSchemeID,HISsystemSet) " + " values('" + HNumber + "','" + HName + "','" + HHelpCode + "','" + HShortNumber + "','" + HItemID + "'" + - ",'"+ HLevel + "','0','" + Convert.ToString(HStopflag ? 1 : 0) + "','" + HRemark + "','鏈娇鐢�','"+ HQCCheckClassID + "','" + HDefaultResult + "')"); + ",'"+ HLevel + "','0','" + Convert.ToString(HStopflag ? 1 : 0) + "','" + HRemark + "','鏈娇鐢�','"+ HQCCheckClassID + "','" + HDefaultResult + + "','" + HAnalysisMethod + "','" + HDefectLevel + "'," + HUnitID + "," + HDestructInspect + "," + HKeyInspect + "," + HQualityStdID + + "," + HInspectMethodID + "," + HInspectInstruMentID + "," + HInspectBasisID + "," + HSampleSchemeID + "," + HISsystemSet + ")"); //淇敼涓婄骇涓洪潪鏈骇浠g爜 if (list[0].HItemID.ToString() != "") { @@ -345,7 +362,19 @@ string HRemark = list[0].HRemark; bool HStopflag = list[0].HStopflag; bool HUseFlag = list[0].HUseFlag; + string HDefaultResult = list[0].HDefaultResult; + long HUnitID = list[0].HUnitID; + string HAnalysisMethod = list[0].HAnalysisMethod; + string HDefectLevel = list[0].HDefectLevel; + long HDestructInspect = list[0].HDestructInspect; + long HKeyInspect = list[0].HKeyInspect; + long HQualityStdID = list[0].HQualityStdID; + long HInspectMethodID = list[0].HInspectMethodID; + long HInspectInstruMentID = list[0].HInspectInstruMentID; + long HInspectBasisID = list[0].HInspectBasisID; + long HSampleSchemeID = list[0].HSampleSchemeID; + long HISsystemSet = list[0].HISsystemSet; if (!DBUtility.ClsPub.AllowNumber(HNumber)) { @@ -378,6 +407,19 @@ ",HStopflag='" + HStopflag + "'" + ",HQCCheckClassID='" + HQCCheckClassID + "'" + ",HDefaultResult='" + HDefaultResult + "'" + + + ",HAnalysisMethod='" + HAnalysisMethod + "'" + + ",HDefectLevel='" + HDefectLevel + "'" + + ",HUnitID='" + HUnitID + "'" + + ",HDestructInspect='" + HDestructInspect + "'" + + ",HKeyInspect='" + HKeyInspect + "'" + + ",HQualityStdID='" + HQualityStdID + "'" + + ",HInspectMethodID='" + HInspectMethodID + "'" + + ",HInspectInstruMentID='" + HInspectInstruMentID + "'" + + ",HInspectBasisID='" + HInspectBasisID + "'" + + ",HSampleSchemeID='" + HSampleSchemeID + "'" + + ",HISsystemSet='" + HISsystemSet + "'" + + ",HRemark= '" + HRemark + "' Where HItemID=" + HItemID, ref DBUtility.ClsPub.sExeReturnInfo); //淇敼瀛愰」鐩唬鐮� //oCN.RunProc("exec h_p_Gy_UpdateNumber Gy_RepairCheck,'" + HNumber + ".','" + this.HOldNumber + ".'", ref DBUtility.ClsPub.sExeReturnInfo); @@ -434,6 +476,37 @@ } #endregion + #region 妫�楠岄」鐩慨鏀硅幏鍙栫粦瀹氭暟鎹鍥� + /// <summary> + /// 缁翠慨鍒楄〃淇敼鎸夐挳鏂规硶 + ///鍙傛暟锛歴tring sql銆� + ///杩斿洖鍊硷細object銆� + /// </summary> + [Route("Gy_CheckItem/xg_View")] + [HttpGet] + public object xg_View(long HInterID) + { + try + { + ds = oCN.RunProcReturn("select * from h_v_Gy_QCCheckItemList_Edit where HItemID=" + HInterID, "h_v_Gy_QCCheckItemList_Edit"); + + objJsonResult.code = "1"; + objJsonResult.count = 1; + objJsonResult.Message = ""; + objJsonResult.data = ds.Tables[0]; + return objJsonResult; + } + catch (Exception e) + { + objJsonResult.code = "0"; + objJsonResult.count = 0; + objJsonResult.Message = "Exception锛�" + e.ToString(); + objJsonResult.data = null; + return objJsonResult; + } + } + #endregion + #region 妫�楠岄」鐩幏鍙栨爲鍨嬪垪琛ㄦ暟鎹� [Route("Gy_CheckItem/LoadTree")] [HttpGet] @@ -461,5 +534,109 @@ } } #endregion + + #region 妫�楠岄」鐩鏍�/鍙嶅鏍� + [Route("Gy_CheckItem/AuditGy_CheckItem")] + [HttpGet] + public object AuditGy_CheckItem(string HInterID, int Type, string user) + { + try + { + //鍒ゆ柇鏄惁鏈夊鏍告潈闄� + if (!DBUtility.ClsPub.Security_Log("Gy_QCCheckItem_Check", 1, false, user)) + { + objJsonResult.code = "0"; + objJsonResult.count = 0; + objJsonResult.Message = "鏃犳潈闄愬鏍�!"; + objJsonResult.data = null; + return objJsonResult; + } + + if (string.IsNullOrWhiteSpace(HInterID)) + { + objJsonResult.code = "0"; + objJsonResult.count = 0; + objJsonResult.Message = "HInterID涓虹┖锛�"; + objJsonResult.data = null; + return objJsonResult; + } + + ClsPub.CurUserName = user; + oCN.BeginTran();//寮�濮嬩簨鍔� + + //Type 1 瀹℃牳 2 鍙嶅鏍� + if (Type == 1) + { + //鍒ゆ柇鍗曟嵁鏄惁宸茬粡瀹℃牳 + DataSet ds; + string sql = "select * from Gy_QCCheckItem where HItemID = " + HInterID; + ds = oCN.RunProcReturn(sql, BillOld.MvarItemKey); + if (ds.Tables[0].Rows[0]["HCheckEmp"] != null && ds.Tables[0].Rows[0]["HCheckEmp"].ToString() != "") + { + objJsonResult.code = "0"; + objJsonResult.count = 0; + objJsonResult.Message = "鍗曟嵁宸插鏍�!涓嶈兘鍐嶆瀹℃牳锛�"; + objJsonResult.data = null; + return objJsonResult; + } + //瀹℃牳鍗曟嵁 + if (!BillOld.AuditByID2(Int64.Parse(HInterID), ref ClsPub.sExeReturnInfo)) + { + objJsonResult.code = "0"; + objJsonResult.count = 1; + objJsonResult.Message = "瀹℃牳澶辫触!鍘熷洜:" + ClsPub.sExeReturnInfo; + objJsonResult.data = null; + return objJsonResult; + } + } + + else + { + //鍒ゆ柇鍗曟嵁鏄惁宸茬粡鍙嶅鏍� + DataSet ds; + string sql = "select * from Gy_QCCheckItem where HItemID = " + HInterID; + ds = oCN.RunProcReturn(sql, BillOld.MvarItemKey); + if (ds.Tables[0] != null && ds.Tables[0].Rows.Count > 0) + { + if (ds.Tables[0].Rows[0]["HCheckEmp"] == null || ds.Tables[0].Rows[0]["HCheckEmp"].ToString() == "") + { + objJsonResult.code = "0"; + objJsonResult.count = 0; + objJsonResult.Message = "鍗曟嵁鏈鏍�!涓嶉渶瑕佸弽瀹℃牳!"; + objJsonResult.data = null; + return objJsonResult; + } + //鍙嶅鏍稿崟鎹� + if (!BillOld.DeAuditByID2(Int64.Parse(HInterID), ref ClsPub.sExeReturnInfo)) + { + objJsonResult.code = "0"; + objJsonResult.count = 1; + objJsonResult.Message = "鍙嶅鏍稿け璐�!鍘熷洜:" + ClsPub.sExeReturnInfo; + objJsonResult.data = null; + return objJsonResult; + } + } + } + + oCN.Commit();//鎻愪氦浜嬪姟 + + objJsonResult.code = "0"; + objJsonResult.count = 1; + objJsonResult.Message = "鎵ц鎴愬姛锛�"; + objJsonResult.data = null; + return objJsonResult; ; + + } + catch (Exception e) + { + objJsonResult.code = "0"; + objJsonResult.count = 0; + objJsonResult.Message = "鎵ц澶辫触锛�" + e.ToString(); + objJsonResult.data = null; + return objJsonResult; + } + } + #endregion + } } diff --git a/WebAPI/Controllers/CJGL/Cj_StationOutBillController.cs b/WebAPI/Controllers/CJGL/Cj_StationOutBillController.cs index 8442208..4693446 100644 --- a/WebAPI/Controllers/CJGL/Cj_StationOutBillController.cs +++ b/WebAPI/Controllers/CJGL/Cj_StationOutBillController.cs @@ -142,6 +142,10 @@ double HmaterOutqty = list[0].HmaterOutqty;//鐧藉澂鍙戝竷 double HProcPriceRate = list[0].HProcPriceRate;//宸ヤ环绯绘暟 int HTemporaryAreaID = list[0].HTemporaryAreaID;//鏆傛斁鍖� + double HWasterQty_Work = list[0].HWasterQty_Work;//宸ュ簾鏁伴噺 + double HWasterQty_Mater = list[0].HWasterQty_Mater;//鏂欏簾鏁伴噺 + double HBackWorkQty = list[0].HBackWorkQty;//杩斿伐鏁伴噺 + Int64 HShiftsID = list[0].HShiftsID;//鐢熶骇鐝 LogService.Write($"1.瀛楁璧嬪�硷紝鐢ㄦ椂" + sw.Elapsed ); @@ -368,7 +372,7 @@ ",HSupID,HQty,HPrice,HMoney,HBadCount,HCenterID,HProcNo,HOrderProcNO,HSourceNameList" + ",HMainSourceInterID,HMainSourceBillNo,HMainSourceBillType,HLastSubProc" + ",HEmpID2,HEmpID3,HEmpID4,HEmpID5,HDSQty,HChongQty,HPriceRate,HWorkTimes,HQCCheckID,HMainInterID,HPRDOrgID" + - ",HmaterOutqty,HProcPriceRate,HTemporaryAreaID" + + ",HmaterOutqty,HProcPriceRate,HTemporaryAreaID,HWasterQty_Work,HWasterQty_Mater,HBackWorkQty,HShiftsID" + ") " + " values('" + BillType + "','" + (OperationType == "5" ? "SUB" : HBillSubType) + "'," + HInterID + ",'" + HBillNo + "'," + HBillStatus + ",getdate(),'" + HMaker + "',getdate(),'" + HMouldNum + "'" + "," + HYear + "," + HPeriod + ",'" + HRemark + "','" + HSourceName + "'," + HPieceQty + "," + HWasterQty + "," + HPlanPieceQty + "," + HBadPNL + @@ -378,7 +382,8 @@ "," + HSupID + "," + HQty + "," + HPrice + "," + HMoney + "," + HBadCount + "," + HCenterID + "," + HProcNo + ",'" + HOrderProcNO + "'" + ",'" + HSourceNameList + "'" + "," + HMainSourceInterID + ",'" + HMainSourceBillNo + "','" + HMainSourceBillType + "'," + Convert.ToString(HLastSubProc ? 1 : 0) + "," + HEmpID2 + "," + HEmpID3 + "," + HEmpID4 + "," + HEmpID5 + "," + HDSQty + "," + HChongQty + "," + HPriceRate + "," + HWorkTimes + "," + HQCCheckID + "," + HMainInterID + "," + HPRDOrgID + - ","+ HmaterOutqty + "," + HProcPriceRate + ","+ HTemporaryAreaID + ") "); + ","+ HmaterOutqty + "," + HProcPriceRate + ","+ HTemporaryAreaID + "," + HWasterQty_Work + "," + HWasterQty_Mater + "," + HBackWorkQty + + "," + HShiftsID + ") "); LogService.Write($"4.鏂板缁撴潫锛岀敤鏃�" + sw.Elapsed); LogService.Write("鐢ㄦ埛:" + user + ",鏃ユ湡:" + DateTime.Now + ",鏂板宸ュ簭鍑虹珯鍗曟嵁:" + HBillNo); @@ -415,6 +420,10 @@ ",HSourceNameList='" + HSourceNameList + "'" + ",HWasterQty=" + HWasterQty + ",HLastSubProc=" + Convert.ToString(HLastSubProc ? 1 : 0) + + ",HWasterQty_Work=" + HWasterQty_Work + + ",HWasterQty_Mater=" + HWasterQty_Mater + + ",HBackWorkQty=" + HBackWorkQty + + ",HShiftsID=" + HShiftsID + " where HInterID=" + HInterID); LogService.Write("鐢ㄦ埛:" + user + ",鏃ユ湡:" + DateTime.Now + ",淇敼宸ュ簭鍑虹珯鍗曟嵁:" + HBillNo); diff --git a/WebAPI/Controllers/MJGL/Sc_MouldDotCheckRuleBillController.cs b/WebAPI/Controllers/MJGL/Sc_MouldDotCheckRuleBillController.cs index d83a49a..6b503b2 100644 --- a/WebAPI/Controllers/MJGL/Sc_MouldDotCheckRuleBillController.cs +++ b/WebAPI/Controllers/MJGL/Sc_MouldDotCheckRuleBillController.cs @@ -254,7 +254,7 @@ } SQLHelper.ClsCN oCN = new SQLHelper.ClsCN(); //鑾峰彇鐐规椤圭洰缂栬緫鏁版嵁 - string sql = "select 鐐规椤圭洰ID HDotCheckItemID,鐐规椤圭洰浠g爜 HDotCheckItemNumber,鐐规椤圭洰 HDotCheckItem,鐐规閮ㄤ綅 HDotCheckPart,鍏蜂綋瑕佹眰 HClaim,璐熻矗浜篒D HManagerID,璐熻矗浜轰唬鐮� HManagerNumber,璐熻矗浜哄悕绉� HManagerName,瀛愬娉�2 HRemark from h_v_Sc_MouldDotCheckRuleBillSub where 1 = 1 " + Swhere + ""; + string sql = "select * from h_v_Sc_MouldDotCheckRuleBillSub where 1 = 1 " + Swhere + ""; ds = oCN.RunProcReturn(sql, "h_v_Sc_MouldDotCheckRuleBillSub"); ////鑾峰彇閰嶄欢椤圭洰缂栬緫鏁版嵁 //string sql1 = "select 閰嶄欢ID HMaterID,閰嶄欢浠g爜 HMaterNumber,閰嶄欢鍚嶇О HMaterName,鍗曚綅ID HUnitID,璁¢噺鍗曚綅浠g爜 HUnitNumber,璁¢噺鍗曚綅鍚嶇О HUnitName,鐢ㄩ噺 HQty,瀛愬娉�1 HRemark,鏍囧噯鐢ㄩ噺 HQtyMust from h_v_Sc_MouldDotCheckRuleBillSub_Item where 1 = 1 " + Swhere + ""; @@ -266,6 +266,7 @@ objJsonResult.count = 1; objJsonResult.Message = "鑾峰彇淇℃伅鎴愬姛锛�"; objJsonResult.list = list; + objJsonResult.data = ds.Tables[0]; } catch (Exception e) { diff --git a/WebAPI/Controllers/QC_ManagementController.cs b/WebAPI/Controllers/QC_ManagementController.cs index 0bb6da0..ab87089 100644 --- a/WebAPI/Controllers/QC_ManagementController.cs +++ b/WebAPI/Controllers/QC_ManagementController.cs @@ -939,9 +939,9 @@ return new ApiResult<DataSet> { code = -1, msg = "ID涓嶈兘涓虹┖" }; SQLHelper.ClsCN oCN = new SQLHelper.ClsCN(); - var dataSet = oCN.RunProcReturn("select top 1 * from h_v_Gy_QCCheckProjectList_NEW where hmainid= " + HID + " ", "h_v_Gy_QCCheckProjectList_NEW"); + var dataSet = oCN.RunProcReturn("select top 1 * from h_v_Gy_QCCheckProjectList_Edit where hmainid= " + HID + " ", "h_v_Gy_QCCheckProjectList_Edit"); if (dataSet == null || dataSet.Tables[0].Rows.Count == 0) - return new ApiResult<DataSet> { code = -1, msg = "涓嶅瓨鍦ㄧ敓浜ф眹鎶ュ崟鍙�" }; + return new ApiResult<DataSet> { code = -1, msg = "涓嶅瓨鍦ㄦ楠屾柟妗�" }; return new ApiResult<DataSet> { code = 1, msg = "鏌ヨ鎴愬姛", data = dataSet }; } @@ -956,14 +956,12 @@ try { SQLHelper.ClsCN oCN = new SQLHelper.ClsCN(); - ds = oCN.RunProcReturn(string.Format(@"select 娆″簭鍙� HPrjNo,妫�楠岄」鐩甀D HQCCheckItemID,妫�楠岄」鐩唬鐮� HQCCheckItemNumber,妫�楠岄」鐩� HQCCheckItemName, - 妫�楠屾爣鍑� HQCStd,鏈�澶ф楠屾爣鍑� HQCStdMax,妫�楠屽崟浣� HQCUnit,琛ㄤ綋澶囨敞 HRemark from h_v_Gy_QCCheckProjectList_NEW - where hinterid='"+HInterID+"'"), "h_v_Gy_QCCheckProjectList_NEW"); + ds = oCN.RunProcReturn(string.Format(@"select * from h_v_Gy_QCCheckProjectList_Edit where hinterid='" + HInterID+"'"), "h_v_Gy_QCCheckProjectList_Edit"); - objJsonResult.code = "0"; - objJsonResult.count = 1; - objJsonResult.Message = "鑾峰彇淇℃伅鎴愬姛锛�"; - objJsonResult.data = ds.Tables[0]; + objJsonResult.code = "0"; + objJsonResult.count = 1; + objJsonResult.Message = "鑾峰彇淇℃伅鎴愬姛锛�"; + objJsonResult.data = ds.Tables[0]; } catch (Exception e) { @@ -1025,7 +1023,6 @@ oItem.HBillStatus = 0; oItem.HPeriod = 0; oItem.HMaker = ""; - oItem.HStandard = false; oItem.HMainSourceInterID = oItem.HInterID; //oItem.HInterID = DBUtility.ClsPub.CreateBillID_SRMProd("1103", ref DBUtility.ClsPub.sExeReturnInfo); if (DBUtility.ClsPub.isStrNull(oItem.HDate) == "") @@ -1262,6 +1259,109 @@ } #endregion + #region 妫�楠屾柟妗堝鏍�/鍙嶅鏍� + [Route("Gy_QCCheckProject/AuditGy_QCCheckProject")] + [HttpGet] + public object AuditGy_QCCheckProject(string HInterID, int Type, string user) + { + try + { + //鍒ゆ柇鏄惁鏈夊鏍告潈闄� + if (!DBUtility.ClsPub.Security_Log("Gy_QCCheckProject_Check", 1, false, user)) + { + objJsonResult.code = "0"; + objJsonResult.count = 0; + objJsonResult.Message = "鏃犳潈闄愬鏍�!"; + objJsonResult.data = null; + return objJsonResult; + } + + if (string.IsNullOrWhiteSpace(HInterID)) + { + objJsonResult.code = "0"; + objJsonResult.count = 0; + objJsonResult.Message = "HInterID涓虹┖锛�"; + objJsonResult.data = null; + return objJsonResult; + } + DAL.ClsGy_QCCheckProjectMain oBill = new DAL.ClsGy_QCCheckProjectMain(); + ClsPub.CurUserName = user; + oCN.BeginTran();//寮�濮嬩簨鍔� + + //Type 1 瀹℃牳 2 鍙嶅鏍� + if (Type == 1) + { + //鍒ゆ柇鍗曟嵁鏄惁宸茬粡瀹℃牳 + DataSet ds; + string sql = "select * from Gy_QCCheckProjectMain where HInterID = " + HInterID; + ds = oCN.RunProcReturn(sql, oBill.MvarItemKey); + if (ds.Tables[0].Rows[0]["HChecker"] != null && ds.Tables[0].Rows[0]["HChecker"].ToString() != "") + { + objJsonResult.code = "0"; + objJsonResult.count = 0; + objJsonResult.Message = "鍗曟嵁宸插鏍�!涓嶈兘鍐嶆瀹℃牳锛�"; + objJsonResult.data = null; + return objJsonResult; + } + //瀹℃牳鍗曟嵁 + if (!oBill.CheckBill(Int64.Parse(HInterID), ref ClsPub.sExeReturnInfo)) + { + objJsonResult.code = "0"; + objJsonResult.count = 1; + objJsonResult.Message = "瀹℃牳澶辫触!鍘熷洜:" + ClsPub.sExeReturnInfo; + objJsonResult.data = null; + return objJsonResult; + } + } + + else + { + //鍒ゆ柇鍗曟嵁鏄惁宸茬粡鍙嶅鏍� + DataSet ds; + string sql = "select * from Gy_QCCheckProjectMain where HInterID = " + HInterID; + ds = oCN.RunProcReturn(sql, oBill.MvarItemKey); + if (ds.Tables[0] != null && ds.Tables[0].Rows.Count > 0) + { + if (ds.Tables[0].Rows[0]["HChecker"] == null || ds.Tables[0].Rows[0]["HChecker"].ToString() == "") + { + objJsonResult.code = "0"; + objJsonResult.count = 0; + objJsonResult.Message = "鍗曟嵁鏈鏍�!涓嶉渶瑕佸弽瀹℃牳!"; + objJsonResult.data = null; + return objJsonResult; + } + //鍙嶅鏍稿崟鎹� + if (!oBill.AbandonCheck(Int64.Parse(HInterID), ref ClsPub.sExeReturnInfo)) + { + objJsonResult.code = "0"; + objJsonResult.count = 1; + objJsonResult.Message = "鍙嶅鏍稿け璐�!鍘熷洜:" + ClsPub.sExeReturnInfo; + objJsonResult.data = null; + return objJsonResult; + } + } + } + + oCN.Commit();//鎻愪氦浜嬪姟 + + objJsonResult.code = "0"; + objJsonResult.count = 1; + objJsonResult.Message = "鎵ц鎴愬姛锛�"; + objJsonResult.data = null; + return objJsonResult; ; + + } + catch (Exception e) + { + objJsonResult.code = "0"; + objJsonResult.count = 0; + objJsonResult.Message = "鎵ц澶辫触锛�" + e.ToString(); + objJsonResult.data = null; + return objJsonResult; + } + } + #endregion + #region 鏉ユ枡妫�楠� /// <summary> /// 淇濆瓨鏉ユ枡妫�楠屽崟 diff --git a/WebAPI/Controllers/SBGL/Sb_EquipDotCheckPlanBillController.cs b/WebAPI/Controllers/SBGL/Sb_EquipDotCheckPlanBillController.cs index 7adee46..6cd3ed2 100644 --- a/WebAPI/Controllers/SBGL/Sb_EquipDotCheckPlanBillController.cs +++ b/WebAPI/Controllers/SBGL/Sb_EquipDotCheckPlanBillController.cs @@ -380,7 +380,7 @@ SQLHelper.ClsCN oCN = new SQLHelper.ClsCN(); if (sqlWhere == null || sqlWhere.Equals("")) { - ds = oCN.RunProcReturn("select 鐐规椤圭洰ID HDotCheckItemID,鐐规椤圭洰浠g爜 HDotCheckCode ,鐐规椤圭洰 HDotCheckItem,鐐规閮ㄤ綅 HDotCheckPart ,鍏蜂綋瑕佹眰 HClaim,琛ㄤ綋澶囨敞 HRemark,璐熻矗浜篒D HManagerID,璐熻矗浜轰唬鐮� HManagerCode,璐熻矗浜� HManagerName from h_v_Sb_EquipDotCheckPlanBillList", "h_v_Sb_EquipDotCheckPlanBillList"); + ds = oCN.RunProcReturn("select * from h_v_Sb_EquipDotCheckPlanBill_Edit", "h_v_Sb_EquipDotCheckPlanBill_Edit"); objJsonResult.code = "0"; objJsonResult.count = 1; objJsonResult.Message = "鑾峰彇淇℃伅鎴愬姛锛�"; @@ -388,9 +388,9 @@ } else { - string sql1 = "select 鐐规椤圭洰ID HDotCheckItemID,鐐规椤圭洰浠g爜 HDotCheckCode ,鐐规椤圭洰 HDotCheckItem,鐐规閮ㄤ綅 HDotCheckPart ,鍏蜂綋瑕佹眰 HClaim,琛ㄤ綋澶囨敞 HRemark,璐熻矗浜篒D HManagerID,璐熻矗浜轰唬鐮� HManagerCode,璐熻矗浜� HManagerName from h_v_Sb_EquipDotCheckPlanBillList where 1 = 1 "; + string sql1 = "select * from h_v_Sb_EquipDotCheckPlanBill_Edit where 1 = 1 "; string sql = sql1 + sqlWhere; - ds = oCN.RunProcReturn(sql, "h_v_Sb_EquipDotCheckPlanBillList"); + ds = oCN.RunProcReturn(sql, "h_v_Sb_EquipDotCheckPlanBill_Edit"); objJsonResult.code = "0"; objJsonResult.count = 1; objJsonResult.Message = "鑾峰彇淇℃伅鎴愬姛锛�"; diff --git a/WebAPI/Controllers/Sc_MouldRepairInBillListController.cs b/WebAPI/Controllers/Sc_MouldRepairInBillListController.cs index a73f3e8..e622a38 100644 --- a/WebAPI/Controllers/Sc_MouldRepairInBillListController.cs +++ b/WebAPI/Controllers/Sc_MouldRepairInBillListController.cs @@ -1836,10 +1836,10 @@ oCN.BeginTran(); //閿�鍞嚭搴撳垹闄ゅ洖濉攢鍞鍗曞叧鑱旀暟閲� - //oCN.RunProc("exec h_p_Xs_UpDateRelation_SeOrderToSellOut_Delete " + HInterID); + oCN.RunProc("exec h_p_Xs_UpDateRelation_SeOrderToSellOut_Delete " + HInterID); //閿�鍞嚭搴撳垹闄ゅ洖濉敹璐ч�氱煡鍗曞叧鑱旀暟閲� - //oCN.RunProc("exec h_p_Xs_UpDateRelation_SeOutStockToPOStockIn_Del " + HInterID); + oCN.RunProc("exec h_p_Xs_UpDateRelation_SeOutStockToPOStockIn_Del " + HInterID); //oCN.RunProc("Delete From Kf_ICStockBillMain where HInterID = " + HInterID); @@ -6133,8 +6133,7 @@ { SQLHelper.ClsCN oCN = new SQLHelper.ClsCN(); //鑾峰彇鐐规椤圭洰缂栬緫鏁版嵁 - ds = oCN.RunProcReturn(@"select a.HDotCheckItemID,HDotCheckItem, HDotCheckPart , HClaim, a.HRemark,a.HManagerID,e.HNumber HManagerCode,e.HName HManagerName from Sc_MouldDotCheckPlanBillSub a - left join Gy_Employee e on a.HManagerID=e.HItemID + ds = oCN.RunProcReturn(@"select * from h_v_Sc_MouldDotCheckPlanBill_Edit where 1=1 " + sqlWhere, "Sc_MouldDotCheckPlanBillSub"); ////鑾峰彇閰嶄欢椤圭洰缂栬緫鏁版嵁 //ds1 = oCN.RunProcReturn(@"select b.HMaterID, mt.Hnumber HMaterNumber ,mt.HName HMaterName, b.HUnitID @@ -6147,7 +6146,7 @@ objJsonResult.code = "0"; objJsonResult.count = 1; objJsonResult.Message = "鑾峰彇淇℃伅鎴愬姛锛�"; - objJsonResult.data = null; + objJsonResult.data = ds.Tables[0]; objJsonResult.list = list; } catch (Exception e) diff --git a/WebAPI/Controllers/WebAPIController.cs b/WebAPI/Controllers/WebAPIController.cs index 31c8db2..681f05e 100644 --- a/WebAPI/Controllers/WebAPIController.cs +++ b/WebAPI/Controllers/WebAPIController.cs @@ -2909,7 +2909,7 @@ /// <summary> - /// 涓嶅紓甯哥被鍨嬪垹闄ゅ姛鑳� + /// 寮傚父绫诲瀷鍒犻櫎鍔熻兘 /// </summary> /// <returns></returns> [Route("DeltetGy_ErrType")] @@ -2969,6 +2969,108 @@ } } + #region 寮傚父绫诲瀷瀹℃牳/鍙嶅鏍� + [Route("Gy_ErrType/AuditGy_ErrType")] + [HttpGet] + public object AuditGy_ErrType(string HInterID, int Type, string user) + { + try + { + //鍒ゆ柇鏄惁鏈夊鏍告潈闄� + if (!DBUtility.ClsPub.Security_Log("Gy_ErrType_Check", 1, false, user)) + { + objJsonResult.code = "0"; + objJsonResult.count = 0; + objJsonResult.Message = "鏃犳潈闄愬鏍�!"; + objJsonResult.data = null; + return objJsonResult; + } + + if (string.IsNullOrWhiteSpace(HInterID)) + { + objJsonResult.code = "0"; + objJsonResult.count = 0; + objJsonResult.Message = "HInterID涓虹┖锛�"; + objJsonResult.data = null; + return objJsonResult; + } + DAL.ClsGy_ErrType_Ctl oBill = new DAL.ClsGy_ErrType_Ctl(); + ClsPub.CurUserName = user; + oCN.BeginTran();//寮�濮嬩簨鍔� + + //Type 1 瀹℃牳 2 鍙嶅鏍� + if (Type == 1) + { + //鍒ゆ柇鍗曟嵁鏄惁宸茬粡瀹℃牳 + DataSet ds; + string sql = "select * from Gy_ErrType where HItemID = " + HInterID; + ds = oCN.RunProcReturn(sql, oBill.MvarItemKey); + if (ds.Tables[0].Rows[0]["HCheckEmp"] != null && ds.Tables[0].Rows[0]["HCheckEmp"].ToString() != "") + { + objJsonResult.code = "0"; + objJsonResult.count = 0; + objJsonResult.Message = "鍗曟嵁宸插鏍�!涓嶈兘鍐嶆瀹℃牳锛�"; + objJsonResult.data = null; + return objJsonResult; + } + //瀹℃牳鍗曟嵁 + if (!oBill.AuditByID2(Int64.Parse(HInterID), ref ClsPub.sExeReturnInfo)) + { + objJsonResult.code = "0"; + objJsonResult.count = 1; + objJsonResult.Message = "瀹℃牳澶辫触!鍘熷洜:" + ClsPub.sExeReturnInfo; + objJsonResult.data = null; + return objJsonResult; + } + } + + else + { + //鍒ゆ柇鍗曟嵁鏄惁宸茬粡鍙嶅鏍� + DataSet ds; + string sql = "select * from Gy_ErrType where HItemID = " + HInterID; + ds = oCN.RunProcReturn(sql, oBill.MvarItemKey); + if (ds.Tables[0] != null && ds.Tables[0].Rows.Count > 0) + { + if (ds.Tables[0].Rows[0]["HCheckEmp"] == null || ds.Tables[0].Rows[0]["HCheckEmp"].ToString() == "") + { + objJsonResult.code = "0"; + objJsonResult.count = 0; + objJsonResult.Message = "鍗曟嵁鏈鏍�!涓嶉渶瑕佸弽瀹℃牳!"; + objJsonResult.data = null; + return objJsonResult; + } + //鍙嶅鏍稿崟鎹� + if (!oBill.DeAuditByID2(Int64.Parse(HInterID), ref ClsPub.sExeReturnInfo)) + { + objJsonResult.code = "0"; + objJsonResult.count = 1; + objJsonResult.Message = "鍙嶅鏍稿け璐�!鍘熷洜:" + ClsPub.sExeReturnInfo; + objJsonResult.data = null; + return objJsonResult; + } + } + } + + oCN.Commit();//鎻愪氦浜嬪姟 + + objJsonResult.code = "0"; + objJsonResult.count = 1; + objJsonResult.Message = "鎵ц鎴愬姛锛�"; + objJsonResult.data = null; + return objJsonResult; ; + + } + catch (Exception e) + { + objJsonResult.code = "0"; + objJsonResult.count = 0; + objJsonResult.Message = "鎵ц澶辫触锛�" + e.ToString(); + objJsonResult.data = null; + return objJsonResult; + } + } + #endregion /// <summary> /// 涓嶈壇绫诲瀷鑾峰彇淇℃伅 @@ -11645,11 +11747,11 @@ //鏈夌殑鍗曞瓙婧愬崟鍒嗕负绾㈣摑鍗� 0浠h〃钃濆崟 1浠h〃绾㈠崟 if (Num==0) { //婧愬崟涓鸿摑鍗� - oDs = oCn.RunProcReturn("select * from Xt_BillSourceSet where HName='" + HName + "' HRedBlueFlag ='"+ Num+"' ", "Xt_BillSourceSet"); + oDs = oCn.RunProcReturn("select * from Xt_BillSourceSet where HName='" + HName + "'and HRedBlueFlag ='"+ Num+"' ", "Xt_BillSourceSet"); } else if (Num==1) { //婧愬崟涓虹孩鍗� - oDs = oCn.RunProcReturn("select * from Xt_BillSourceSet where HName='" + HName + "' HRedBlueFlag ='" + Num + "' ", "Xt_BillSourceSet"); + oDs = oCn.RunProcReturn("select * from Xt_BillSourceSet where HName='" + HName + "' and HRedBlueFlag ='" + Num + "' ", "Xt_BillSourceSet"); } else if(Num==2) { //涓嶅垎绾㈣摑鍗� diff --git a/WebAPI/Controllers/XSGL/Xs_ReceivableBillController.cs b/WebAPI/Controllers/XSGL/Xs_ReceivableBillController.cs index 128b977..abc342f 100644 --- a/WebAPI/Controllers/XSGL/Xs_ReceivableBillController.cs +++ b/WebAPI/Controllers/XSGL/Xs_ReceivableBillController.cs @@ -363,24 +363,20 @@ oCN.BeginTran(); - //ds = oCN.RunProcReturn("select * from h_v_Xs_ReceivableBillList_Query where hmainid=" + HInterID, "h_v_Xs_ReceivableBillList_Query"); - //foreach (DataRow row in ds.Tables[0].Rows) - //{ - // // 鑾峰彇褰撳墠琛岀殑 HSourceBillType 鍊� - // string hSourceBillType = row["HSourceBillType"].ToString(); + ds = oCN.RunProcReturn("select * from h_v_Xs_ReceivableBillList_Query where hmainid=" + HInterID, "h_v_Xs_ReceivableBillList_Query"); + string hSourceBillType = ds.Tables[0].Rows[0]["HSourceBillType"].ToString(); + if (hSourceBillType == "1401") + { + //搴旀敹鍗� 鍒犻櫎鍥炲~ 閿�鍞鍗� 鍏宠仈鏁伴噺 + oCN.RunProc("exec h_p_Xs_UpDateRelation_SeOrderToPOStockIn_Del " + HInterID); + } + else if (hSourceBillType == "1205") + { + //搴旀敹鍗� 鍒犻櫎鍥炲~ 閿�鍞嚭搴撳崟 鍏宠仈鏁伴噺 + oCN.RunProc("exec h_p_Xs_UpDateRelation_ICStockoPOStockIn_Del " + HInterID); + } - // if (hSourceBillType == "1401") - // { - // //搴旀敹鍗� 鍒犻櫎鍥炲~ 閿�鍞鍗� 鍏宠仈鏁伴噺 - // oCN.RunProc("exec h_p_Xs_UpDateRelation_SeOrderToPOStockIn_Del " + HInterID); - // } - // else if (hSourceBillType == "1205") - // { - // //搴旀敹鍗� 鍒犻櫎鍥炲~ 閿�鍞嚭搴撳崟 鍏宠仈鏁伴噺 - // oCN.RunProc("exec h_p_Xs_UpDateRelation_ICStockoPOStockIn_Del " + HInterID); - // } - //} - + oCN.RunProc("delete from Xs_ReceivableBillMain where HInterID = " + HInterID); oCN.RunProc("delete from Xs_ReceivableBillSub where HInterID= " + HInterID); diff --git a/WebAPI/Controllers/XSGL/Xs_SeOrderBillController.cs b/WebAPI/Controllers/XSGL/Xs_SeOrderBillController.cs index 134f9dc..9812528 100644 --- a/WebAPI/Controllers/XSGL/Xs_SeOrderBillController.cs +++ b/WebAPI/Controllers/XSGL/Xs_SeOrderBillController.cs @@ -87,12 +87,12 @@ if (sWhere == null || sWhere.Equals("")) { - ds = oCN.RunProcReturn("select * from h_v_IF_SeOrderBillList order by hmainid desc", "h_v_IF_SeOrderBillList"); + ds = oCN.RunProcReturn("select * from h_v_IF_SeOrderBillList order by hmainid desc,hsubid asc", "h_v_IF_SeOrderBillList"); } else { string sql1 = "select * from h_v_IF_SeOrderBillList where 1 = 1 "; - string sql = sql1 + sWhere+ " order by hmainid desc"; + string sql = sql1 + sWhere+ " order by hmainid desc,hsubid asc"; ds = oCN.RunProcReturn(sql, "h_v_IF_SeOrderBillList"); } @@ -1268,7 +1268,7 @@ try { - ds = oCN.RunProcReturn("select * from h_v_IF_SeOrderBillList where hmainid =" + HInterID, "h_v_IF_SeOrderBillList"); + ds = oCN.RunProcReturn("select * from h_v_IF_SeOrderBillList where hmainid =" + HInterID + " order by hsubid asc", "h_v_IF_SeOrderBillList"); if (ds == null || ds.Tables[0].Rows.Count == 0) { objJsonResult.code = "0"; diff --git a/WebAPI/Controllers/XSGL/Xs_SeOutStockBillController.cs b/WebAPI/Controllers/XSGL/Xs_SeOutStockBillController.cs index b9f0333..b64a9ce 100644 --- a/WebAPI/Controllers/XSGL/Xs_SeOutStockBillController.cs +++ b/WebAPI/Controllers/XSGL/Xs_SeOutStockBillController.cs @@ -144,8 +144,8 @@ oCN.BeginTran(); var ds = oCN.RunProcReturn("select * from Xs_SeOutStockBillMain where HInterID=" + HInterID, "Xs_SeOutStockBillMain"); - - var dss = oCN.RunProcReturn("exec h_p_Xs_SeOutStockBillMain_Delete " + HQty + ", '" + HSourceInterID + "', '" + HSourceEntryID + "','" + user + " '", "h_p_Xs_SeOutStockBillMain_Delete"); + //鍒犻櫎鎾ら攢 鍙戣揣閫氱煡鍗� 鍙嶅啓 閿�鍞鍗� + oCN.RunProcReturn("exec h_p_Xs_SeOutStockBillMain_Delete " + HInterID, "h_p_Xs_SeOutStockBillMain_Delete"); //鍒犻櫎鍓嶆帶鍒� DataSet BeforeDs = oCN.RunProcReturn("Exec h_p_Xs_SeOutStockBill_BeforeDelCtrl " + HInterID.ToString() + ",'" + user + "'", "h_p_Xs_SeOutStockBill_BeforeDelCtrl"); if (BeforeDs == null || BeforeDs.Tables[0].Rows.Count == 0) @@ -362,6 +362,27 @@ } else if (OperationType == 3 || ds.Tables[0].Rows.Count != 0) { //淇敼 + + DataSet dss; + dss = oCN.RunProcReturn("select * from h_v_IF_SeOutStockBillList where hmainid=" + HInterID + " and 鍗曟嵁鍙�='" + HBillNo + "'", "h_v_IF_SeOutStockBillList"); + //鍒ゆ柇鏄惁鍙紪杈� + if (dss.Tables[0].Rows[0]["瀹℃牳浜�"].ToString() != "" && dss.Tables[0].Rows[0]["瀹℃牳浜�"] != null) + { + objJsonResult.code = "0"; + objJsonResult.count = 0; + objJsonResult.Message = "姝ゅ崟鎹凡缁忚瀹℃牳锛屼笉鍏佽淇敼锛�"; + objJsonResult.data = 1; + return objJsonResult; + } + if (dss.Tables[0].Rows[0]["鐘舵��"].ToString() != "鍒涘缓") + { + objJsonResult.code = "0"; + objJsonResult.count = 0; + objJsonResult.Message = "姝ゅ崟鎹浜庝笉鍙紪杈戠姸鎬侊紝涓嶅厑璁镐慨鏀癸紒"; + objJsonResult.data = 1; + return objJsonResult; + } + string sql = $@"update Xs_SeOutStockBillMain set " + "HRemark='" + HRemark + "', HUpDater='" + HMaker + "', HUpDateDate=getdate()" + ",HCusID='" + HCusID + "', HCurID='" + HCurID + "', HWHID = '" + HWHID @@ -369,15 +390,21 @@ + "',HAddress='" + HAddress + "',HProjectID='"+ HProjectID + "' where HInterID=" + HInterID; oCN.RunProc(sql); + //鍒犻櫎 鎾ら攢鍙戣揣閫氱煡鍗� 鍙嶅啓 閿�鍞鍗� + oCN.RunProcReturn("exec h_p_Xs_SeOutStockBillMain_Delete " + HInterID, "h_p_Xs_SeOutStockBillMain_Delete"); + //鍒犻櫎瀛愯〃 oCN.RunProc("delete from Xs_SeOutStockBillSub where HInterID='" + HInterID + "'"); } //淇濆瓨瀛愯〃 objJsonResult = AddBillSub(msg3, HInterID, OperationType,user); + //鍙戣揣閫氱煡鐨� 鍙嶅啓 鏁伴噺鍒� 閿�鍞鍗� 鍏宠仈鏁伴噺 + oCN.RunProcReturn("exec h_p_Xs_SeOutStockBillMain " + HInterID, "h_p_Xs_SeOutStockBillMain"); + //淇濆瓨鍚庢帶鍒�========================================= - ds = oCN.RunProcReturn("Exec h_p_Xs_SeOutStockBill_AfterSaveCtrl " + HInterID.ToString() + ", '" + HBillNo + "',1 ", "h_p_Xs_SeOutStockBill_AfterSaveCtrl"); + ds = oCN.RunProcReturn("Exec h_p_Xs_SeOutStockBill_AfterSaveCtrl " + HInterID.ToString() + ", '" + HBillNo + "',1 ", "h_p_Xs_SeOutStockBill_AfterSaveCtrl"); if (ds == null || ds.Tables.Count == 0 || ds.Tables[0].Rows.Count == 0) { objJsonResult.code = "0"; @@ -487,7 +514,6 @@ oCN.RunProc(sql); - ds = oCN.RunProcReturn("exec h_p_Xs_SeOutStockBillMain " + oSub.HQty + ", '" + oSub.HSourceInterID + "', '" + oSub.HSourceEntryID + "','" + user + " '", "h_p_Xs_SeOutStockBillMain"); } objJsonResult.code = "1"; diff --git "a/WebAPI/Controllers/\344\273\223\345\255\230\347\256\241\347\220\206/\350\260\203\346\213\250\347\233\230\347\202\271/Kf_MoveStockRequestBillController.cs" "b/WebAPI/Controllers/\344\273\223\345\255\230\347\256\241\347\220\206/\350\260\203\346\213\250\347\233\230\347\202\271/Kf_MoveStockRequestBillController.cs" index 9ec37d6..c5a0407 100644 --- "a/WebAPI/Controllers/\344\273\223\345\255\230\347\256\241\347\220\206/\350\260\203\346\213\250\347\233\230\347\202\271/Kf_MoveStockRequestBillController.cs" +++ "b/WebAPI/Controllers/\344\273\223\345\255\230\347\256\241\347\220\206/\350\260\203\346\213\250\347\233\230\347\202\271/Kf_MoveStockRequestBillController.cs" @@ -15,6 +15,7 @@ { public DBUtility.ClsPub.Enum_BillStatus BillStatus;//鍗曟嵁鐘舵�侊紙鏂板锛屼慨鏀癸紝娴忚锛屾洿鏂板崟浠凤紝鍙樻洿锛� private json objJsonResult = new json(); + public DAL.ClsSc_ICMOBill BillOld = new DAL.ClsSc_ICMOBill(); public DataSet ds = new DataSet(); public SQLHelper.ClsCN oCn = new SQLHelper.ClsCN(); @@ -170,7 +171,7 @@ ,HSTOCKINORGID,HSTOCKOUTORGID,HStockStyle ,HOWNERTYPEHEADID,HTRANSTYPE,HOWNERTYPEINID,HBUSINESSTYPE) values(" + HInterID + ",'" + HBillNo + "','" + HDate + "','" + 1243 + "','" + - HBillSubType + "'," + HBillStatus + "," + DateTime.Now.Year + "," + DateTime.Now.Month + "," + HSupID + + 1243 + "'," + HBillStatus + "," + DateTime.Now.Year + "," + DateTime.Now.Month + "," + HSupID + "," + HWHID + "," + HSCWHID + "," + HEmpID + "," + HMangerID + "," + HSecManagerID + "," + HKeeperID + "," + HDeptID + ",'" + HMaker + "','" + HMakeDate + "','" + HChecker + "','" + HCheckDate + "','" + HUpDater + "','" + HUpDateDate + "','" + HDeleteMan + "','" + HDeleteDate + "','" + HCloseMan + "','" + HCloseDate + "','" @@ -383,5 +384,435 @@ return objJsonResult; } } + + #region 璋冩嫧鐢宠鍗� 瀹℃牳/鍙嶅鏍� + /// <summary> + /// + /// </summary> + /// <param name="HInterID">鍗曟嵁ID</param> + /// <param name="IsAudit">瀹℃牳(0),鍙嶅鏍�(1)</param> + /// <param name="CurUserName">瀹℃牳浜�</param> + /// <returns></returns> + [Route("Kf_MoveStockRequestBill/AuditKf_MoveStockRequestBill")] + [HttpGet] + public object AuditKf_MoveStockRequestBill(string HInterID, int Type, string user) + { + try + { + //鍒ゆ柇鏄惁鏈夊鏍告潈闄� + if (!DBUtility.ClsPub.Security_Log("Kf_MoveStockRequestBill_Check", 1, false, user)) + { + objJsonResult.code = "0"; + objJsonResult.count = 0; + objJsonResult.Message = "鏃犳潈闄愬鏍�!"; + objJsonResult.data = null; + return objJsonResult; + } + + if (string.IsNullOrWhiteSpace(HInterID)) + { + objJsonResult.code = "0"; + objJsonResult.count = 0; + objJsonResult.Message = "HInterID涓虹┖锛�"; + objJsonResult.data = null; + return objJsonResult; + } + + ClsPub.CurUserName = user; + BillOld.MvarItemKey = "Kf_MoveStockRequestBillMain"; + oCn.BeginTran();//寮�濮嬩簨鍔� + + //Type 1 瀹℃牳 2 鍙嶅鏍� + if (Type == 1) + { + //鍒ゆ柇鍗曟嵁鏄惁宸茬粡瀹℃牳 + DataSet ds; + string sql = "select * from " + BillOld.MvarItemKey + " where HinterID = " + HInterID; + ds = oCn.RunProcReturn(sql, BillOld.MvarItemKey); + if (ds == null || ds.Tables[0].Rows.Count == 0) + { + objJsonResult.code = "0"; + objJsonResult.count = 0; + objJsonResult.Message = "鍗曟嵁涓嶅瓨鍦紒"; + objJsonResult.data = null; + return objJsonResult; + } + if (ds.Tables[0] != null && ds.Tables[0].Rows.Count > 0) + { + if (ds.Tables[0].Rows[0]["HCloseMan"] != null && ds.Tables[0].Rows[0]["HCloseMan"].ToString() != "") + { + objJsonResult.code = "0"; + objJsonResult.count = 0; + objJsonResult.Message = "鍗曟嵁宸插叧闂�!涓嶈兘鍐嶆瀹℃牳锛�"; + objJsonResult.data = null; + return objJsonResult; + } + if (ds.Tables[0].Rows[0]["HDeleteMan"] != null && ds.Tables[0].Rows[0]["HDeleteMan"].ToString() != "") + { + objJsonResult.code = "0"; + objJsonResult.count = 0; + objJsonResult.Message = "鍗曟嵁宸蹭綔搴�!涓嶈兘鍐嶆瀹℃牳锛�"; + objJsonResult.data = null; + return objJsonResult; + } + if (ds.Tables[0].Rows[0]["HChecker"] != null && ds.Tables[0].Rows[0]["HChecker"].ToString() != "") + { + objJsonResult.code = "0"; + objJsonResult.count = 0; + objJsonResult.Message = "鍗曟嵁宸插鏍�!涓嶈兘鍐嶆瀹℃牳锛�"; + objJsonResult.data = null; + return objJsonResult; + } + //瀹℃牳鍗曟嵁 + if (!BillOld.CheckBill(Int64.Parse(HInterID), ref ClsPub.sExeReturnInfo)) + { + objJsonResult.code = "0"; + objJsonResult.count = 1; + objJsonResult.Message = "瀹℃牳澶辫触!鍘熷洜:" + ClsPub.sExeReturnInfo; + objJsonResult.data = null; + return objJsonResult; + } + } + } + else + { + //鍒ゆ柇鍗曟嵁鏄惁宸茬粡鍙嶅鏍� + DataSet ds; + string sql = "select * from " + BillOld.MvarItemKey + " where HinterID = " + HInterID; + ds = oCn.RunProcReturn(sql, BillOld.MvarItemKey); + if (ds.Tables[0] != null && ds.Tables[0].Rows.Count > 0) + { + if (ds.Tables[0].Rows[0]["HCloseMan"] != null && ds.Tables[0].Rows[0]["HCloseMan"].ToString() != "") + { + objJsonResult.code = "0"; + objJsonResult.count = 0; + objJsonResult.Message = "鍗曟嵁宸插叧闂�!涓嶈兘杩涜鍙嶅鏍革紒"; + objJsonResult.data = null; + return objJsonResult; + } + if (ds.Tables[0].Rows[0]["HDeleteMan"] != null && ds.Tables[0].Rows[0]["HDeleteMan"].ToString() != "") + { + objJsonResult.code = "0"; + objJsonResult.count = 0; + objJsonResult.Message = "鍗曟嵁宸蹭綔搴�!涓嶈兘杩涜鍙嶅鏍革紒"; + objJsonResult.data = null; + return objJsonResult; + } + if (ds.Tables[0].Rows[0]["HChecker"] == null || ds.Tables[0].Rows[0]["HChecker"].ToString() == "") + { + objJsonResult.code = "0"; + objJsonResult.count = 0; + objJsonResult.Message = "鍗曟嵁鏈鏍�!涓嶉渶瑕佸弽瀹℃牳!"; + objJsonResult.data = null; + return objJsonResult; + } + //鍙嶅鏍稿崟鎹� + if (!BillOld.AbandonCheck(Int64.Parse(HInterID), ref ClsPub.sExeReturnInfo)) + { + objJsonResult.code = "0"; + objJsonResult.count = 1; + objJsonResult.Message = "鍙嶅鏍稿け璐�!鍘熷洜:" + ClsPub.sExeReturnInfo; + objJsonResult.data = null; + return objJsonResult; + } + } + } + + oCn.Commit();//鎻愪氦浜嬪姟 + + objJsonResult.code = "0"; + objJsonResult.count = 1; + objJsonResult.Message = "鎵ц鎴愬姛锛�"; + objJsonResult.data = null; + return objJsonResult; ; + + } + catch (Exception e) + { + objJsonResult.code = "0"; + objJsonResult.count = 0; + objJsonResult.Message = "鎵ц澶辫触锛�" + e.ToString(); + objJsonResult.data = null; + return objJsonResult; + } + } + #endregion + + #region 璋冩嫧鐢宠鍗� 鍏抽棴/鍙嶅叧闂姛鑳� + [Route("Kf_MoveStockRequestBill/CloseKf_MoveStockRequestBill")] + [HttpGet] + public object CloseKf_MoveStockRequestBill(string HInterID, int Type, string user) + { + try + { + //鍒ゆ柇鏄惁鏈夊垹闄ゆ潈闄� + if (!DBUtility.ClsPub.Security_Log("Kf_MoveStockRequestBill_Close", 1, false, user)) + { + objJsonResult.code = "0"; + objJsonResult.count = 0; + objJsonResult.Message = "鏃犳潈闄愬叧闂�!"; + objJsonResult.data = null; + return objJsonResult; + } + + if (string.IsNullOrWhiteSpace(HInterID)) + { + objJsonResult.code = "0"; + objJsonResult.count = 0; + objJsonResult.Message = "HInterID涓虹┖锛�"; + objJsonResult.data = null; + return objJsonResult; + } + + ClsPub.CurUserName = user; + BillOld.MvarItemKey = "Kf_MoveStockRequestBillMain"; + oCn.BeginTran();//寮�濮嬩簨鍔� + + //Type 1 鍏抽棴 2 鍙嶅叧闂� + if (Type == 1) + { + //鍒ゆ柇鍗曟嵁鏄惁宸茬粡鍏抽棴 + DataSet ds; + string sql = "select * from " + BillOld.MvarItemKey + " where HinterID = " + HInterID; + ds = oCn.RunProcReturn(sql, BillOld.MvarItemKey); + if (ds == null || ds.Tables[0].Rows.Count == 0) + { + objJsonResult.code = "0"; + objJsonResult.count = 0; + objJsonResult.Message = "鍗曟嵁涓嶅瓨鍦紒"; + objJsonResult.data = null; + return objJsonResult; + } + if (ds.Tables[0] != null && ds.Tables[0].Rows.Count > 0) + { + if (ds.Tables[0].Rows[0]["HDeleteMan"] != null && ds.Tables[0].Rows[0]["HDeleteMan"].ToString() != "") + { + objJsonResult.code = "0"; + objJsonResult.count = 0; + objJsonResult.Message = "鍗曟嵁宸蹭綔搴�!涓嶈兘杩涜鍏抽棴!"; + objJsonResult.data = null; + return objJsonResult; + } + if (ds.Tables[0].Rows[0]["HChecker"] == null || ds.Tables[0].Rows[0]["HChecker"].ToString() == "") + { + objJsonResult.code = "0"; + objJsonResult.count = 0; + objJsonResult.Message = "鍗曟嵁鏈鏍�!涓嶈兘杩涜鍏抽棴!"; + objJsonResult.data = null; + return objJsonResult; + } + + if (ds.Tables[0].Rows[0]["HCloseMan"] != null && ds.Tables[0].Rows[0]["HCloseMan"].ToString() != "") + { + objJsonResult.code = "0"; + objJsonResult.count = 0; + objJsonResult.Message = "鍗曟嵁宸插叧闂�!涓嶈兘鍐嶆鍏抽棴!"; + objJsonResult.data = null; + return objJsonResult; + } + //鍏抽棴鍗曟嵁 + if (!BillOld.CloseBill(Int64.Parse(HInterID), ref ClsPub.sExeReturnInfo)) + { + objJsonResult.code = "0"; + objJsonResult.count = 1; + objJsonResult.Message = "鍏抽棴澶辫触!鍘熷洜:" + ClsPub.sExeReturnInfo; + objJsonResult.data = null; + return objJsonResult; + } + } + } + else + { + //鍒ゆ柇鍗曟嵁鏄惁宸茬粡鍙嶅叧闂� + DataSet ds; + string sql = "select * from " + BillOld.MvarItemKey + " where HinterID = " + HInterID; + ds = oCn.RunProcReturn(sql, BillOld.MvarItemKey); + if (ds.Tables[0] != null && ds.Tables[0].Rows.Count > 0) + { + if (ds.Tables[0].Rows[0]["HDeleteMan"] != null && ds.Tables[0].Rows[0]["HDeleteMan"].ToString() != "") + { + objJsonResult.code = "0"; + objJsonResult.count = 0; + objJsonResult.Message = "鍗曟嵁宸蹭綔搴�!涓嶈兘杩涜鍏抽棴!"; + objJsonResult.data = null; + return objJsonResult; + } + if (ds.Tables[0].Rows[0]["HChecker"] == null || ds.Tables[0].Rows[0]["HChecker"].ToString() == "") + { + objJsonResult.code = "0"; + objJsonResult.count = 0; + objJsonResult.Message = "鍗曟嵁鏈鏍�!涓嶈兘杩涜鍏抽棴!"; + objJsonResult.data = null; + return objJsonResult; + } + if (ds.Tables[0].Rows[0]["HCloseMan"] == null || ds.Tables[0].Rows[0]["HCloseMan"].ToString() == "") + { + objJsonResult.code = "0"; + objJsonResult.count = 0; + objJsonResult.Message = "鍗曟嵁鏈叧闂�!涓嶉渶瑕佸啀鍙嶅叧闂�!"; + objJsonResult.data = null; + return objJsonResult; + } + //鍙嶅叧闂崟鎹� + if (!BillOld.CancelClose(Int64.Parse(HInterID), ref ClsPub.sExeReturnInfo)) + { + objJsonResult.code = "0"; + objJsonResult.count = 1; + objJsonResult.Message = "鍙嶅叧闂け璐�!鍘熷洜:" + ClsPub.sExeReturnInfo; + objJsonResult.data = null; + return objJsonResult; + } + } + } + + oCn.Commit();//鎻愪氦浜嬪姟 + + objJsonResult.code = "0"; + objJsonResult.count = 1; + objJsonResult.Message = "鎵ц鎴愬姛锛�"; + objJsonResult.data = null; + return objJsonResult; ; + + } + catch (Exception e) + { + objJsonResult.code = "0"; + objJsonResult.count = 0; + objJsonResult.Message = "鎵ц澶辫触锛�" + e.ToString(); + objJsonResult.data = null; + return objJsonResult; + } + } + #endregion + + #region 璋冩嫧鐢宠鍗� 浣滃簾/鍙嶄綔搴熷姛鑳� + [Route("Kf_MoveStockRequestBill/DropKf_MoveStockRequestBill")] + [HttpGet] + public object DropKf_MoveStockRequestBill(string HInterID, int Type, string user) + { + try + { + //鍒ゆ柇鏄惁鏈変綔搴熸潈闄� + if (!DBUtility.ClsPub.Security_Log("Kf_MoveStockRequestBill_Delete", 1, false, user)) + { + objJsonResult.code = "0"; + objJsonResult.count = 0; + objJsonResult.Message = "鏃犳潈闄愪綔搴�!"; + objJsonResult.data = null; + return objJsonResult; + } + + if (string.IsNullOrWhiteSpace(HInterID)) + { + objJsonResult.code = "0"; + objJsonResult.count = 0; + objJsonResult.Message = "HInterID涓虹┖锛�"; + objJsonResult.data = null; + return objJsonResult; + } + + ClsPub.CurUserName = user; + BillOld.MvarItemKey = "Kf_MoveStockRequestBillMain"; + oCn.BeginTran();//寮�濮嬩簨鍔� + + //Type 1 浣滃簾 2 鍙嶄綔搴� + if (Type == 1) + { + //鍒ゆ柇鍗曟嵁鏄惁宸茬粡浣滃簾 + DataSet ds; + string sql = "select * from " + BillOld.MvarItemKey + " where HinterID = " + HInterID; + ds = oCn.RunProcReturn(sql, BillOld.MvarItemKey); + if (ds == null || ds.Tables[0].Rows.Count == 0) + { + objJsonResult.code = "0"; + objJsonResult.count = 0; + objJsonResult.Message = "鍗曟嵁涓嶅瓨鍦紒"; + objJsonResult.data = null; + return objJsonResult; + } + if (ds.Tables[0] != null && ds.Tables[0].Rows.Count > 0) + { + if (ds.Tables[0].Rows[0]["HChecker"] != null && ds.Tables[0].Rows[0]["HChecker"].ToString() != "") + { + objJsonResult.code = "0"; + objJsonResult.count = 0; + objJsonResult.Message = "鍗曟嵁宸插鏍�!涓嶈兘杩涜浣滃簾!"; + objJsonResult.data = null; + return objJsonResult; + } + if (ds.Tables[0].Rows[0]["HDeleteMan"] != null && ds.Tables[0].Rows[0]["HDeleteMan"].ToString() != "") + { + objJsonResult.code = "0"; + objJsonResult.count = 0; + objJsonResult.Message = "鍗曟嵁宸蹭綔搴�!涓嶉渶瑕佸啀浣滃簾!"; + objJsonResult.data = null; + return objJsonResult; + } + //浣滃簾鍗曟嵁 + if (!BillOld.Cancelltion(Int64.Parse(HInterID), ref ClsPub.sExeReturnInfo)) + { + objJsonResult.code = "0"; + objJsonResult.count = 1; + objJsonResult.Message = "浣滃簾澶辫触!鍘熷洜:" + ClsPub.sExeReturnInfo; + objJsonResult.data = null; + return objJsonResult; + } + } + } + else + { + //鍒ゆ柇鍗曟嵁鏄惁宸茬粡鍙嶄綔搴� + DataSet ds; + string sql = "select * from " + BillOld.MvarItemKey + " where HinterID = " + HInterID; + ds = oCn.RunProcReturn(sql, BillOld.MvarItemKey); + if (ds.Tables[0] != null && ds.Tables[0].Rows.Count > 0) + { + if (ds.Tables[0].Rows[0]["HChecker"] != null && ds.Tables[0].Rows[0]["HChecker"].ToString() != "") + { + objJsonResult.code = "0"; + objJsonResult.count = 0; + objJsonResult.Message = "鍗曟嵁宸插鏍�!涓嶈兘杩涜浣滃簾!"; + objJsonResult.data = null; + return objJsonResult; + } + if (ds.Tables[0].Rows[0]["HDeleteMan"] == null || ds.Tables[0].Rows[0]["HDeleteMan"].ToString() == "") + { + objJsonResult.code = "0"; + objJsonResult.count = 0; + objJsonResult.Message = "鍗曟嵁鏈綔搴�!涓嶉渶瑕佸啀鍙嶄綔搴�!"; + objJsonResult.data = null; + return objJsonResult; + } + //鍙嶄綔搴熷崟鎹� + if (!BillOld.AbandonCancelltion(Int64.Parse(HInterID), ref ClsPub.sExeReturnInfo)) + { + objJsonResult.code = "0"; + objJsonResult.count = 1; + objJsonResult.Message = "鍙嶄綔搴熷け璐�!鍘熷洜:" + ClsPub.sExeReturnInfo; + objJsonResult.data = null; + return objJsonResult; + } + } + } + + oCn.Commit();//鎻愪氦浜嬪姟 + + objJsonResult.code = "0"; + objJsonResult.count = 1; + objJsonResult.Message = "鎵ц鎴愬姛锛�"; + objJsonResult.data = null; + return objJsonResult; ; + + } + catch (Exception e) + { + objJsonResult.code = "0"; + objJsonResult.count = 0; + objJsonResult.Message = "鎵ц澶辫触锛�" + e.ToString(); + objJsonResult.data = null; + return objJsonResult; + } + } + #endregion } } \ No newline at end of file diff --git "a/WebAPI/Controllers/\345\223\201\350\264\250\347\256\241\347\220\206/\345\267\245\345\272\217\346\243\200\351\252\214\345\215\225/QC_ProcessCheckBillController.cs" "b/WebAPI/Controllers/\345\223\201\350\264\250\347\256\241\347\220\206/\345\267\245\345\272\217\346\243\200\351\252\214\345\215\225/QC_ProcessCheckBillController.cs" index b960379..09e616b 100644 --- "a/WebAPI/Controllers/\345\223\201\350\264\250\347\256\241\347\220\206/\345\267\245\345\272\217\346\243\200\351\252\214\345\215\225/QC_ProcessCheckBillController.cs" +++ "b/WebAPI/Controllers/\345\223\201\350\264\250\347\256\241\347\220\206/\345\267\245\345\272\217\346\243\200\351\252\214\345\215\225/QC_ProcessCheckBillController.cs" @@ -778,6 +778,8 @@ BillNew.omodel.HQCSchemeID = ClsPub.isLong(mainList[0].HQCSchemeID); BillNew.omodel.HBillStatus = 1; BillNew.omodel.HProcID = ClsPub.isLong(mainList[0].HProcID); + BillNew.omodel.HShiftsID = ClsPub.isLong(mainList[0].HShiftsID); + BillNew.omodel.HErrTreatment = ClsPub.isStrNull(mainList[0].HErrTreatment); List<Model.ClsQC_ProcessCheckBillSub> subList = Newtonsoft.Json.JsonConvert.DeserializeObject<List<Model.ClsQC_ProcessCheckBillSub>>(msg3); BillNew.DetailColl = new List<Model.ClsQC_ProcessCheckBillSub>(); for (int i = 0; i < subList.ToArray().Length; i++) diff --git "a/WebAPI/Controllers/\345\223\201\350\264\250\347\256\241\347\220\206/\351\246\226\344\273\266\346\243\200\351\252\214\345\215\225/QC_FirstPieceCheckBillController.cs" "b/WebAPI/Controllers/\345\223\201\350\264\250\347\256\241\347\220\206/\351\246\226\344\273\266\346\243\200\351\252\214\345\215\225/QC_FirstPieceCheckBillController.cs" index e39b759..217a3a1 100644 --- "a/WebAPI/Controllers/\345\223\201\350\264\250\347\256\241\347\220\206/\351\246\226\344\273\266\346\243\200\351\252\214\345\215\225/QC_FirstPieceCheckBillController.cs" +++ "b/WebAPI/Controllers/\345\223\201\350\264\250\347\256\241\347\220\206/\351\246\226\344\273\266\346\243\200\351\252\214\345\215\225/QC_FirstPieceCheckBillController.cs" @@ -200,6 +200,8 @@ BillNew.omodel.HMainSourceBillType = ClsPub.isStrNull(mainList[0].HMainSourceBillType); BillNew.omodel.HQCSchemeID = ClsPub.isLong(mainList[0].HQCSchemeID); BillNew.omodel.HBillStatus = 1; + BillNew.omodel.HShiftsID = ClsPub.isLong(mainList[0].HShiftsID); + BillNew.omodel.HErrTreatment = ClsPub.isStrNull(mainList[0].HErrTreatment); List<Model.ClsQC_FirstPieceCheckBillSub> subList = Newtonsoft.Json.JsonConvert.DeserializeObject<List<Model.ClsQC_FirstPieceCheckBillSub>>(msg3); BillNew.DetailColl = new List<Model.ClsQC_FirstPieceCheckBillSub>(); for (int i = 0; i < subList.ToArray().Length; i++) diff --git "a/WebAPI/Controllers/\345\237\272\347\241\200\350\265\204\346\226\231/\345\237\272\347\241\200\350\265\204\346\226\231/Gy_DotCheckBillController.cs" "b/WebAPI/Controllers/\345\237\272\347\241\200\350\265\204\346\226\231/\345\237\272\347\241\200\350\265\204\346\226\231/Gy_DotCheckBillController.cs" index 59ba13f..2a4ac0d 100644 --- "a/WebAPI/Controllers/\345\237\272\347\241\200\350\265\204\346\226\231/\345\237\272\347\241\200\350\265\204\346\226\231/Gy_DotCheckBillController.cs" +++ "b/WebAPI/Controllers/\345\237\272\347\241\200\350\265\204\346\226\231/\345\237\272\347\241\200\350\265\204\346\226\231/Gy_DotCheckBillController.cs" @@ -132,7 +132,7 @@ { try { - ds = oCN.RunProcReturn("select * from Gy_DotCheck where HItemID=" + HInterID, "Gy_DotCheck"); + ds = oCN.RunProcReturn("select * from h_v_Gy_DotCheck_Edit where HItemID=" + HInterID, "h_v_Gy_DotCheck_Edit"); objJsonResult.code = "1"; objJsonResult.count = 1; @@ -178,6 +178,7 @@ string HRemark = list[0].HRemark; bool HStopflag = list[0].HStopflag; string HUseFlag = list[0].HUseFlag; + Int64 HDotCheckItemClassID = list[0].HDotCheckItemClassID; //鍒ゆ柇鏉冮檺 if (!ClsPub.Security_Log("Gy_DotCheck_Edit", 1, false, msg3)) @@ -218,6 +219,7 @@ ",HShortNumber='" + HShortNumber + "'" + ",HHelpCode='" + HHelpCode + "'" + ",HStopflag='" + HStopflag + "'" + + ",HDotCheckItemClassID=" + HDotCheckItemClassID + ",HRemark= '" + HRemark + "' Where HItemID=" + HItemID, ref DBUtility.ClsPub.sExeReturnInfo); //淇敼瀛愰」鐩唬鐮� //oCN.RunProc("exec h_p_Gy_UpdateNumber Gy_RepairCheck,'" + HNumber + ".','" + this.HOldNumber + ".'", ref DBUtility.ClsPub.sExeReturnInfo); @@ -268,7 +270,7 @@ bool HStopflag = list[0].HStopflag; string HUseFlag = list[0].HUseFlag; bool HEndFlag = list[0].HEndFlag; - + Int64 HDotCheckItemClassID = list[0].HDotCheckItemClassID; //鍒ゆ柇鏉冮檺 if (!ClsPub.Security_Log("Gy_DotCheck_Edit", 1, false, msg3)) { @@ -295,9 +297,9 @@ //涓昏〃 oCN.RunProc("Insert into Gy_DotCheck " + " (HNumber,HName,HHelpCode,HShortNumber" + - ",HLevel,HEndFlag,HStopflag,HRemark,HParentID) " + + ",HLevel,HEndFlag,HStopflag,HRemark,HParentID,HDotCheckItemClassID ) " + " Values('" + HNumber + "','" + HName + "','" + HHelpCode + "','" + HShortNumber + "'," + - +HLevel + ",1," + Convert.ToString(HStopflag ? 1 : 0) + ",'" + HRemark + "',0)", ref DBUtility.ClsPub.sExeReturnInfo); + +HLevel + ",1," + Convert.ToString(HStopflag ? 1 : 0) + ",'" + HRemark + "',0," + HDotCheckItemClassID + ")", ref DBUtility.ClsPub.sExeReturnInfo); //淇敼涓婄骇涓洪潪鏈骇浠g爜 //oCN.RunProc("Update Gy_MouldType set HEndflag=0 where HItemID=" + HParentID, ref DBUtility.ClsPub.sExeReturnInfo); oCN.Commit(); diff --git "a/WebAPI/Controllers/\345\237\272\347\241\200\350\265\204\346\226\231/\345\237\272\347\241\200\350\265\204\346\226\231/Gy_DotCheckItemClassController.cs" "b/WebAPI/Controllers/\345\237\272\347\241\200\350\265\204\346\226\231/\345\237\272\347\241\200\350\265\204\346\226\231/Gy_DotCheckItemClassController.cs" new file mode 100644 index 0000000..2764735 --- /dev/null +++ "b/WebAPI/Controllers/\345\237\272\347\241\200\350\265\204\346\226\231/\345\237\272\347\241\200\350\265\204\346\226\231/Gy_DotCheckItemClassController.cs" @@ -0,0 +1,379 @@ +锘縰sing DBUtility; +using Newtonsoft.Json; +using Newtonsoft.Json.Linq; +using System; +using System.Collections.Generic; +using System.Data; +using System.Linq; +using System.Net; +using System.Net.Http; +using System.Web.Http; +using WebAPI.Models; + + +namespace WebAPI.Controllers.鍩虹璧勬枡.鍩虹璧勬枡 +{ + public class Gy_DotCheckItemClassController : ApiController + { + private json objJsonResult = new json(); + SQLHelper.ClsCN oCN = new SQLHelper.ClsCN(); + DataSet ds; + public DAL.ClsGy_DotCheckItemClass_Ctl BillOld = new DAL.ClsGy_DotCheckItemClass_Ctl(); + + #region 鐐规椤圭洰鍒嗙被鍒楄〃鏁版嵁 + [Route("Gy_DotCheckItemClass/GetDotCheckItemClassList")] + [HttpGet] + public object GetDotCheckItemClassList(string sWhere, string user) + { + try + { + List<object> columnNameList = new List<object>(); + if (!DBUtility.ClsPub.Security_Log("Gy_DotCheckItemClass_Query", 1, false, user)) + { + objJsonResult.code = "0"; + objJsonResult.count = 0; + objJsonResult.Message = "娌℃湁鏌ョ湅鏉冮檺"; + objJsonResult.data = null; + return objJsonResult; + } + ds = oCN.RunProcReturn("select * from h_v_Gy_DotCheckItemClassList where 1=1 " + sWhere + " order by HItemID", "h_v_Gy_DotCheckItemClassList"); + + //娣诲姞鍒楀悕 + foreach (DataColumn col in ds.Tables[0].Columns) + { + Type dataType = col.DataType; + string ColmString = "{\"ColmCols\":\"" + col.ColumnName + "\",\"ColmType\":\"" + dataType.Name + "\"}"; + columnNameList.Add(JsonConvert.DeserializeObject(ColmString));//鑾峰彇鍒癉ataColumn鍒楀璞$殑鍒楀悕 + } + + objJsonResult.code = "1"; + objJsonResult.count = 1; + objJsonResult.Message = "Sucess锛�"; + objJsonResult.data = ds.Tables[0]; + objJsonResult.list = columnNameList; + return objJsonResult; + + } + catch (Exception e) + { + objJsonResult.code = "0"; + objJsonResult.count = 0; + objJsonResult.Message = "Exception锛�" + e.ToString(); + objJsonResult.data = null; + return objJsonResult; + } + } + #endregion + + #region 淇敼鐐规椤圭洰鍒嗙被鑾峰彇缁戝畾鏁版嵁 + [Route("Gy_DotCheckItemClass/EditDotCheckItemClass")] + [HttpGet] + public object EditDotCheck(long HInterID) + { + try + { + ds = oCN.RunProcReturn("select * from h_v_Gy_DotCheckItemClass_Edit where HItemID=" + HInterID, "h_v_Gy_DotCheckItemClass_Edit"); + + objJsonResult.code = "1"; + objJsonResult.count = 1; + objJsonResult.Message = ""; + objJsonResult.data = ds.Tables[0]; + return objJsonResult; + } + catch (Exception e) + { + objJsonResult.code = "0"; + objJsonResult.count = 0; + objJsonResult.Message = "Exception锛�" + e.ToString(); + objJsonResult.data = null; + return objJsonResult; + } + } + #endregion + + #region 鐐规椤圭洰鍒嗙被淇濆瓨鏂规硶 + [Route("Gy_DotCheckItemClass/SaveGy_DotCheckItemClassList")] + [HttpPost] + public object SaveGy_DotCheckItemClassList([FromBody] JObject msg) + { + DataSet ds; + var _value = msg["msg"].ToString(); + string msg3 = _value.ToString(); + string[] sArray = msg3.Split(new string[] { ";" }, StringSplitOptions.RemoveEmptyEntries); + string msg1 = sArray[0].ToString(); + string msg_HUserName = sArray[1].ToString(); + string msg_HCreateORGID = sArray[2].ToString(); + string msg_OperationType = sArray[3].ToString(); + + Int64 HItemID = 0; + SQLHelper.ClsCN oCN = new SQLHelper.ClsCN(); + + //缂栬緫鏉冮檺 + if (!DBUtility.ClsPub.Security_Log_second("Gy_DotCheckItemClass_Edit", 1, false, msg_HUserName)) + { + objJsonResult.code = "0"; + objJsonResult.count = 0; + objJsonResult.Message = "鏃犱繚瀛樻潈闄愶紒"; + objJsonResult.data = null; + return objJsonResult; + } + + //鑾峰彇鏈�澶D鍊艰祴鍊� + DataSet Maxds = oCN.RunProcReturn("select MAX(HItemID) HItemID from Gy_DotCheckItemClass ", "Gy_DotCheckItemClass"); + if ((Maxds != null || Maxds.Tables[0].Rows.Count > 0) && ( Maxds.Tables[0].Rows[0]["HItemID"] != null && Maxds.Tables[0].Rows[0]["HItemID"].ToString() != "" && Maxds.Tables[0].Rows[0]["HItemID"].ToString() != "undefined") ) + { + var maxid = Convert.ToInt32(Maxds.Tables[0].Rows[0]["HItemID"]); + maxid += 1; + HItemID = maxid; + } + else + { + HItemID = 1; + } + ListModels oListModels = new ListModels(); + + try + { + DAL.ClsGy_DotCheckItemClass_Ctl oBill = new DAL.ClsGy_DotCheckItemClass_Ctl(); + List<Model.ClsGy_DotCheckItemClass_Model> lsmain = new List<Model.ClsGy_DotCheckItemClass_Model>(); + msg1 = msg1.Replace("\\", ""); + msg1 = msg1.Replace("\n", ""); //\n + lsmain = oListModels.getObjectByJson_Gy_DotCheckItemClass(msg1); + foreach (Model.ClsGy_DotCheckItemClass_Model oItem in lsmain) + { + if (oItem.HNumber.Trim() == "") + { + objJsonResult.code = "0"; + objJsonResult.count = 0; + objJsonResult.Message = "淇濆瓨澶辫触锛佷唬鐮佷笉鑳戒负绌猴紒"; + objJsonResult.data = 1; + return objJsonResult; + } + if (oItem.HName.Trim() == "") + { + objJsonResult.code = "0"; + objJsonResult.count = 0; + objJsonResult.Message = "淇濆瓨澶辫触锛佸悕绉颁笉鑳戒负绌猴紒"; + objJsonResult.data = 1; + return objJsonResult; + } + + //鏌ヨ鏁版嵁涓槸鍚﹀瓨鍦ㄩ噸澶嶄唬鐮� + ds = oCN.RunProcReturn("select * from Gy_DotCheckItemClass where HStopflag = 0 and HNumber = '" + oItem.HNumber.Trim() + "'", "Gy_DotCheckItemClass"); + + //寰楀埌鐭唬鐮� + string sShortNumber; + sShortNumber = DBUtility.ClsPub.GetShortNumber(oItem.HNumber.Trim()); + if (sShortNumber.Trim() == "") + { + objJsonResult.code = "0"; + objJsonResult.count = 0; + objJsonResult.Message = "淇濆瓨澶辫触锛佺煭浠g爜涓虹┖锛�"; + objJsonResult.data = 1; + return objJsonResult; + } + oItem.HUSEORGID = Convert.ToInt32(msg_HCreateORGID); //缁勭粐id + oItem.HShortNumber = sShortNumber;//鐭唬鐮� + oItem.HEndFlag = true;//鏈骇鏍囧織 + oItem.HLevel = DBUtility.ClsPub.GetLevel(oItem.HNumber.Trim()); //绛夌骇 + oItem.HMakeEmp = msg_HUserName; //鍒跺崟浜� + oItem.HCREATEORGID = Convert.ToInt32(msg_HCreateORGID); //鍒涘缓缁勭粐 + oBill.oModel = oItem; + } + //淇濆瓨 + //淇濆瓨瀹屾瘯鍚庡鐞� + bool bResult; + if (msg_OperationType == 1.ToString() || msg_OperationType == 2.ToString()) + { + bResult = oBill.AddNew(); + } + else + { + bResult = oBill.ModifyByID(oBill.oModel.HItemID); + } + if (bResult) + { + objJsonResult.code = "1"; + objJsonResult.count = 1; + objJsonResult.Message = "淇濆瓨鎴愬姛锛�"; + objJsonResult.data = ""; + return objJsonResult; + } + else + { + objJsonResult.code = "0"; + objJsonResult.count = 0; + objJsonResult.Message = "淇濆瓨澶辫触锛�" + DBUtility.ClsPub.sExeReturnInfo; + objJsonResult.data = ""; + return objJsonResult; + } + } + catch (Exception e) + { + objJsonResult.code = "0"; + objJsonResult.count = 0; + objJsonResult.Message = "淇濆瓨澶辫触锛�" + e.ToString(); + objJsonResult.data = ""; + return objJsonResult; + } + } + #endregion + + #region 鐐规椤圭洰鍒嗙被鍒犻櫎 + [Route("Gy_DotCheckItemClass/DeleteDotCheckItemClass")] + [HttpGet] + public object DeleteDotCheckItemClass(long HItemID, string User) + { + + try + { + if (!DBUtility.ClsPub.Security_Log("Gy_DotCheckItemClass_Delete", 1, false, User)) + { + objJsonResult.code = "0"; + objJsonResult.count = 0; + objJsonResult.Message = "娌℃湁鍒犻櫎鏉冮檺"; + objJsonResult.data = null; + return objJsonResult; + } + + ds = oCN.RunProcReturn("Select * from Gy_DotCheckItemClass Where HItemID='" + HItemID + "'", "Gy_DotCheckItemClass", ref DBUtility.ClsPub.sExeReturnInfo); + if (ds.Tables[0].Rows.Count != 0) + { + ds = oCN.RunProcReturn("Delete from Gy_DotCheckItemClass Where HItemID='" + HItemID + "'", "Gy_DotCheckItemClass", ref DBUtility.ClsPub.sExeReturnInfo); + objJsonResult.code = "1"; + objJsonResult.count = 1; + objJsonResult.Message = "鍒犻櫎鎴愬姛"; + objJsonResult.data = null; + return objJsonResult; + } + else + { + objJsonResult.code = "0"; + objJsonResult.count = 0; + objJsonResult.Message = "鍗曟嵁涓嶅瓨鍦�"; + objJsonResult.data = null; + return objJsonResult; + } + } + catch (Exception e) + { + objJsonResult.code = "0"; + objJsonResult.count = 0; + objJsonResult.Message = "Exception锛�" + e.ToString(); + objJsonResult.data = null; + return objJsonResult; + } + } + #endregion + + #region 鐐规椤圭洰鍒嗙被瀹℃牳銆佸弽瀹℃牳 + /// <summary> + /// + /// </summary> + /// <param name="HInterID">鍗曟嵁ID</param> + /// <param name="IsAudit">瀹℃牳(0),鍙嶅鏍�(1)</param> + /// <param name="CurUserName">瀹℃牳浜�</param> + /// <returns></returns> + [Route("Gy_DotCheckItemClass/AuditGy_DotCheckItemClass")] + [HttpGet] + public object AuditGy_DotCheckItemClass(string HInterID, int Type, string user) + { + try + { + //瀹℃牳鏉冮檺 + if (!DBUtility.ClsPub.Security_Log_second("Gy_DotCheckItemClass_Check", 1, false, user)) + { + objJsonResult.code = "0"; + objJsonResult.count = 0; + objJsonResult.Message = "瀹℃牳澶辫触锛佹棤鏉冮檺锛�"; + objJsonResult.data = null; + return objJsonResult; + } + + if (string.IsNullOrWhiteSpace(HInterID)) + { + objJsonResult.code = "0"; + objJsonResult.count = 0; + objJsonResult.Message = "HInterID涓虹┖锛�"; + objJsonResult.data = null; + return objJsonResult; + } + + ClsPub.CurUserName = user; + oCN.BeginTran();//寮�濮嬩簨鍔� + + //Type 1 瀹℃牳 2 鍙嶅鏍� + if (Type == 1) + { + //鍒ゆ柇鍗曟嵁鏄惁宸茬粡瀹℃牳 + DataSet ds; + string sql = "select * from Gy_DotCheckItemClass where HItemID = " + HInterID; + ds = oCN.RunProcReturn(sql, BillOld.MvarItemKey); + if (ds.Tables[0].Rows[0]["HCheckEmp"] != null && ds.Tables[0].Rows[0]["HCheckEmp"].ToString() != "") + { + objJsonResult.code = "0"; + objJsonResult.count = 0; + objJsonResult.Message = "鍗曟嵁宸插鏍�!涓嶈兘鍐嶆瀹℃牳锛�"; + objJsonResult.data = null; + return objJsonResult; + } + //瀹℃牳鍗曟嵁 + if (!BillOld.AuditByID2(Int64.Parse(HInterID), ref ClsPub.sExeReturnInfo)) + { + objJsonResult.code = "0"; + objJsonResult.count = 1; + objJsonResult.Message = "瀹℃牳澶辫触!鍘熷洜:" + ClsPub.sExeReturnInfo; + objJsonResult.data = null; + return objJsonResult; + } + } + else + { + //鍒ゆ柇鍗曟嵁鏄惁宸茬粡鍙嶅鏍� + DataSet ds; + string sql = "select * from Gy_DotCheckItemClass where HItemID = " + HInterID; + ds = oCN.RunProcReturn(sql, BillOld.MvarItemKey); + if (ds.Tables[0] != null && ds.Tables[0].Rows.Count > 0) + { + if (ds.Tables[0].Rows[0]["HCheckEmp"] == null || ds.Tables[0].Rows[0]["HCheckEmp"].ToString() == "") + { + objJsonResult.code = "0"; + objJsonResult.count = 0; + objJsonResult.Message = "鍗曟嵁鏈鏍�!涓嶉渶瑕佸弽瀹℃牳!"; + objJsonResult.data = null; + return objJsonResult; + } + //鍙嶅鏍稿崟鎹� + if (!BillOld.DeAuditByID2(Int64.Parse(HInterID), ref ClsPub.sExeReturnInfo)) + { + objJsonResult.code = "0"; + objJsonResult.count = 1; + objJsonResult.Message = "鍙嶅鏍稿け璐�!鍘熷洜:" + ClsPub.sExeReturnInfo; + objJsonResult.data = null; + return objJsonResult; + } + } + } + + oCN.Commit();//鎻愪氦浜嬪姟 + + objJsonResult.code = "0"; + objJsonResult.count = 1; + objJsonResult.Message = "鎵ц鎴愬姛锛�"; + objJsonResult.data = null; + return objJsonResult; ; + } + catch (Exception e) + { + oCN.RollBack(); + objJsonResult.code = "0"; + objJsonResult.count = 0; + objJsonResult.Message = "瀹℃牳澶辫触鎴栬�呭弽瀹℃牳澶辫触锛�" + e.ToString(); + objJsonResult.data = null; + return objJsonResult; + } + } + #endregion + + } +} diff --git "a/WebAPI/Controllers/\345\237\272\347\241\200\350\265\204\346\226\231/\345\237\272\347\241\200\350\265\204\346\226\231/Gy_DotCheckItemMethodController.cs" "b/WebAPI/Controllers/\345\237\272\347\241\200\350\265\204\346\226\231/\345\237\272\347\241\200\350\265\204\346\226\231/Gy_DotCheckItemMethodController.cs" new file mode 100644 index 0000000..c4c949e --- /dev/null +++ "b/WebAPI/Controllers/\345\237\272\347\241\200\350\265\204\346\226\231/\345\237\272\347\241\200\350\265\204\346\226\231/Gy_DotCheckItemMethodController.cs" @@ -0,0 +1,379 @@ +锘縰sing DBUtility; +using Newtonsoft.Json; +using Newtonsoft.Json.Linq; +using System; +using System.Collections.Generic; +using System.Data; +using System.Linq; +using System.Net; +using System.Net.Http; +using System.Web.Http; +using WebAPI.Models; + + +namespace WebAPI.Controllers.鍩虹璧勬枡.鍩虹璧勬枡 +{ + public class Gy_DotCheckItemMethodController : ApiController + { + private json objJsonResult = new json(); + SQLHelper.ClsCN oCN = new SQLHelper.ClsCN(); + DataSet ds; + public DAL.ClsGy_DotCheckItemMethod_Ctl BillOld = new DAL.ClsGy_DotCheckItemMethod_Ctl(); + + #region 鐐规鏂规硶鍒楄〃鏁版嵁 + [Route("Gy_DotCheckItemMethod/GetDotCheckItemMethodList")] + [HttpGet] + public object GetDotCheckItemMethodList(string sWhere, string user) + { + try + { + List<object> columnNameList = new List<object>(); + if (!DBUtility.ClsPub.Security_Log("Gy_DotCheckItemMethod_Query", 1, false, user)) + { + objJsonResult.code = "0"; + objJsonResult.count = 0; + objJsonResult.Message = "娌℃湁鏌ョ湅鏉冮檺"; + objJsonResult.data = null; + return objJsonResult; + } + ds = oCN.RunProcReturn("select * from h_v_Gy_DotCheckItemMethodList where 1=1 " + sWhere + " order by HItemID", "h_v_Gy_DotCheckItemMethodList"); + + //娣诲姞鍒楀悕 + foreach (DataColumn col in ds.Tables[0].Columns) + { + Type dataType = col.DataType; + string ColmString = "{\"ColmCols\":\"" + col.ColumnName + "\",\"ColmType\":\"" + dataType.Name + "\"}"; + columnNameList.Add(JsonConvert.DeserializeObject(ColmString));//鑾峰彇鍒癉ataColumn鍒楀璞$殑鍒楀悕 + } + + objJsonResult.code = "1"; + objJsonResult.count = 1; + objJsonResult.Message = "Sucess锛�"; + objJsonResult.data = ds.Tables[0]; + objJsonResult.list = columnNameList; + return objJsonResult; + + } + catch (Exception e) + { + objJsonResult.code = "0"; + objJsonResult.count = 0; + objJsonResult.Message = "Exception锛�" + e.ToString(); + objJsonResult.data = null; + return objJsonResult; + } + } + #endregion + + #region 淇敼鐐规鏂规硶鑾峰彇缁戝畾鏁版嵁 + [Route("Gy_DotCheckItemMethod/EditDotCheckItemMethod")] + [HttpGet] + public object EditDotCheckItemMethod(long HInterID) + { + try + { + ds = oCN.RunProcReturn("select * from h_v_Gy_DotCheckItemMethod_Edit where HItemID=" + HInterID, "h_v_Gy_DotCheckItemMethod_Edit"); + + objJsonResult.code = "1"; + objJsonResult.count = 1; + objJsonResult.Message = ""; + objJsonResult.data = ds.Tables[0]; + return objJsonResult; + } + catch (Exception e) + { + objJsonResult.code = "0"; + objJsonResult.count = 0; + objJsonResult.Message = "Exception锛�" + e.ToString(); + objJsonResult.data = null; + return objJsonResult; + } + } + #endregion + + #region 鐐规鏂规硶淇濆瓨鏂规硶 + [Route("Gy_DotCheckItemMethod/SaveGy_DotCheckItemMethodList")] + [HttpPost] + public object SaveGy_DotCheckItemMethodList([FromBody] JObject msg) + { + DataSet ds; + var _value = msg["msg"].ToString(); + string msg3 = _value.ToString(); + string[] sArray = msg3.Split(new string[] { ";" }, StringSplitOptions.RemoveEmptyEntries); + string msg1 = sArray[0].ToString(); + string msg_HUserName = sArray[1].ToString(); + string msg_HCreateORGID = sArray[2].ToString(); + string msg_OperationType = sArray[3].ToString(); + + Int64 HItemID = 0; + SQLHelper.ClsCN oCN = new SQLHelper.ClsCN(); + + //缂栬緫鏉冮檺 + if (!DBUtility.ClsPub.Security_Log_second("Gy_DotCheckItemMethod_Edit", 1, false, msg_HUserName)) + { + objJsonResult.code = "0"; + objJsonResult.count = 0; + objJsonResult.Message = "鏃犱繚瀛樻潈闄愶紒"; + objJsonResult.data = null; + return objJsonResult; + } + + //鑾峰彇鏈�澶D鍊艰祴鍊� + DataSet Maxds = oCN.RunProcReturn("select MAX(HItemID) HItemID from Gy_DotCheckItemMethod ", "Gy_DotCheckItemMethod"); + if ((Maxds != null || Maxds.Tables[0].Rows.Count > 0) && (Maxds.Tables[0].Rows[0]["HItemID"] != null && Maxds.Tables[0].Rows[0]["HItemID"].ToString() != "" && Maxds.Tables[0].Rows[0]["HItemID"].ToString() != "undefined")) + { + var maxid = Convert.ToInt32(Maxds.Tables[0].Rows[0]["HItemID"]); + maxid += 1; + HItemID = maxid; + } + else + { + HItemID = 1; + } + ListModels oListModels = new ListModels(); + + try + { + DAL.ClsGy_DotCheckItemMethod_Ctl oBill = new DAL.ClsGy_DotCheckItemMethod_Ctl(); + List<Model.ClsGy_DotCheckItemMethod_Model> lsmain = new List<Model.ClsGy_DotCheckItemMethod_Model>(); + msg1 = msg1.Replace("\\", ""); + msg1 = msg1.Replace("\n", ""); //\n + lsmain = oListModels.getObjectByJson_Gy_DotCheckItemMethod(msg1); + foreach (Model.ClsGy_DotCheckItemMethod_Model oItem in lsmain) + { + if (oItem.HNumber.Trim() == "") + { + objJsonResult.code = "0"; + objJsonResult.count = 0; + objJsonResult.Message = "淇濆瓨澶辫触锛佷唬鐮佷笉鑳戒负绌猴紒"; + objJsonResult.data = 1; + return objJsonResult; + } + if (oItem.HName.Trim() == "") + { + objJsonResult.code = "0"; + objJsonResult.count = 0; + objJsonResult.Message = "淇濆瓨澶辫触锛佸悕绉颁笉鑳戒负绌猴紒"; + objJsonResult.data = 1; + return objJsonResult; + } + + //鏌ヨ鏁版嵁涓槸鍚﹀瓨鍦ㄩ噸澶嶄唬鐮� + ds = oCN.RunProcReturn("select * from Gy_DotCheckItemMethod where HStopflag =0 and HNumber = '" + oItem.HNumber.Trim() + "'", "Gy_DotCheckItemMethod"); + + //寰楀埌鐭唬鐮� + string sShortNumber; + sShortNumber = DBUtility.ClsPub.GetShortNumber(oItem.HNumber.Trim()); + if (sShortNumber.Trim() == "") + { + objJsonResult.code = "0"; + objJsonResult.count = 0; + objJsonResult.Message = "淇濆瓨澶辫触锛佺煭浠g爜涓虹┖锛�"; + objJsonResult.data = 1; + return objJsonResult; + } + oItem.HUSEORGID = Convert.ToInt32(msg_HCreateORGID); //缁勭粐id + oItem.HShortNumber = sShortNumber;//鐭唬鐮� + oItem.HEndFlag = true;//鏈骇鏍囧織 + oItem.HLevel = DBUtility.ClsPub.GetLevel(oItem.HNumber.Trim()); //绛夌骇 + oItem.HMakeEmp = msg_HUserName; //鍒跺崟浜� + oItem.HCREATEORGID = Convert.ToInt32(msg_HCreateORGID); //鍒涘缓缁勭粐 + oBill.oModel = oItem; + } + //淇濆瓨 + //淇濆瓨瀹屾瘯鍚庡鐞� + bool bResult; + if (msg_OperationType == 1.ToString() || msg_OperationType == 2.ToString()) + { + bResult = oBill.AddNew(); + } + else + { + bResult = oBill.ModifyByID(oBill.oModel.HItemID); + } + if (bResult) + { + objJsonResult.code = "1"; + objJsonResult.count = 1; + objJsonResult.Message = "淇濆瓨鎴愬姛锛�"; + objJsonResult.data = ""; + return objJsonResult; + } + else + { + objJsonResult.code = "0"; + objJsonResult.count = 0; + objJsonResult.Message = "淇濆瓨澶辫触锛�" + DBUtility.ClsPub.sExeReturnInfo; + objJsonResult.data = ""; + return objJsonResult; + } + } + catch (Exception e) + { + objJsonResult.code = "0"; + objJsonResult.count = 0; + objJsonResult.Message = "淇濆瓨澶辫触锛�" + e.ToString(); + objJsonResult.data = ""; + return objJsonResult; + } + } + #endregion + + #region 鐐规鏂规硶鍒犻櫎 + [Route("Gy_DotCheckItemMethod/DeleteDotCheckItemMethod")] + [HttpGet] + public object DeleteDotCheckItemMethod(long HItemID, string User) + { + + try + { + if (!DBUtility.ClsPub.Security_Log("Gy_DotCheckItemMethod_Delete", 1, false, User)) + { + objJsonResult.code = "0"; + objJsonResult.count = 0; + objJsonResult.Message = "娌℃湁鍒犻櫎鏉冮檺"; + objJsonResult.data = null; + return objJsonResult; + } + + ds = oCN.RunProcReturn("Select * from Gy_DotCheckItemMethod Where HItemID='" + HItemID + "'", "Gy_DotCheckItemMethod", ref DBUtility.ClsPub.sExeReturnInfo); + if (ds.Tables[0].Rows.Count != 0) + { + ds = oCN.RunProcReturn("Delete from Gy_DotCheckItemMethod Where HItemID='" + HItemID + "'", "Gy_DotCheckItemMethod", ref DBUtility.ClsPub.sExeReturnInfo); + objJsonResult.code = "1"; + objJsonResult.count = 1; + objJsonResult.Message = "鍒犻櫎鎴愬姛"; + objJsonResult.data = null; + return objJsonResult; + } + else + { + objJsonResult.code = "0"; + objJsonResult.count = 0; + objJsonResult.Message = "鍗曟嵁涓嶅瓨鍦�"; + objJsonResult.data = null; + return objJsonResult; + } + } + catch (Exception e) + { + objJsonResult.code = "0"; + objJsonResult.count = 0; + objJsonResult.Message = "Exception锛�" + e.ToString(); + objJsonResult.data = null; + return objJsonResult; + } + } + #endregion + + #region 鐐规鏂规硶瀹℃牳銆佸弽瀹℃牳 + /// <summary> + /// + /// </summary> + /// <param name="HInterID">鍗曟嵁ID</param> + /// <param name="IsAudit">瀹℃牳(0),鍙嶅鏍�(1)</param> + /// <param name="CurUserName">瀹℃牳浜�</param> + /// <returns></returns> + [Route("Gy_DotCheckItemMethod/AuditGy_DotCheckItemMethod")] + [HttpGet] + public object AuditGy_DotCheckItemMethod(string HInterID, int Type, string user) + { + try + { + //瀹℃牳鏉冮檺 + if (!DBUtility.ClsPub.Security_Log_second("Gy_DotCheckItemMethod_Check", 1, false, user)) + { + objJsonResult.code = "0"; + objJsonResult.count = 0; + objJsonResult.Message = "瀹℃牳澶辫触锛佹棤鏉冮檺锛�"; + objJsonResult.data = null; + return objJsonResult; + } + + if (string.IsNullOrWhiteSpace(HInterID)) + { + objJsonResult.code = "0"; + objJsonResult.count = 0; + objJsonResult.Message = "HInterID涓虹┖锛�"; + objJsonResult.data = null; + return objJsonResult; + } + + ClsPub.CurUserName = user; + oCN.BeginTran();//寮�濮嬩簨鍔� + + //Type 1 瀹℃牳 2 鍙嶅鏍� + if (Type == 1) + { + //鍒ゆ柇鍗曟嵁鏄惁宸茬粡瀹℃牳 + DataSet ds; + string sql = "select * from Gy_DotCheckItemMethod where HItemID = " + HInterID; + ds = oCN.RunProcReturn(sql, BillOld.MvarItemKey); + if (ds.Tables[0].Rows[0]["HCheckEmp"] != null && ds.Tables[0].Rows[0]["HCheckEmp"].ToString() != "") + { + objJsonResult.code = "0"; + objJsonResult.count = 0; + objJsonResult.Message = "鍗曟嵁宸插鏍�!涓嶈兘鍐嶆瀹℃牳锛�"; + objJsonResult.data = null; + return objJsonResult; + } + //瀹℃牳鍗曟嵁 + if (!BillOld.AuditByID2(Int64.Parse(HInterID), ref ClsPub.sExeReturnInfo)) + { + objJsonResult.code = "0"; + objJsonResult.count = 1; + objJsonResult.Message = "瀹℃牳澶辫触!鍘熷洜:" + ClsPub.sExeReturnInfo; + objJsonResult.data = null; + return objJsonResult; + } + } + else + { + //鍒ゆ柇鍗曟嵁鏄惁宸茬粡鍙嶅鏍� + DataSet ds; + string sql = "select * from Gy_DotCheckItemMethod where HItemID = " + HInterID; + ds = oCN.RunProcReturn(sql, BillOld.MvarItemKey); + if (ds.Tables[0] != null && ds.Tables[0].Rows.Count > 0) + { + if (ds.Tables[0].Rows[0]["HCheckEmp"] == null || ds.Tables[0].Rows[0]["HCheckEmp"].ToString() == "") + { + objJsonResult.code = "0"; + objJsonResult.count = 0; + objJsonResult.Message = "鍗曟嵁鏈鏍�!涓嶉渶瑕佸弽瀹℃牳!"; + objJsonResult.data = null; + return objJsonResult; + } + //鍙嶅鏍稿崟鎹� + if (!BillOld.DeAuditByID2(Int64.Parse(HInterID), ref ClsPub.sExeReturnInfo)) + { + objJsonResult.code = "0"; + objJsonResult.count = 1; + objJsonResult.Message = "鍙嶅鏍稿け璐�!鍘熷洜:" + ClsPub.sExeReturnInfo; + objJsonResult.data = null; + return objJsonResult; + } + } + } + + oCN.Commit();//鎻愪氦浜嬪姟 + + objJsonResult.code = "0"; + objJsonResult.count = 1; + objJsonResult.Message = "鎵ц鎴愬姛锛�"; + objJsonResult.data = null; + return objJsonResult; ; + } + catch (Exception e) + { + oCN.RollBack(); + objJsonResult.code = "0"; + objJsonResult.count = 0; + objJsonResult.Message = "瀹℃牳澶辫触鎴栬�呭弽瀹℃牳澶辫触锛�" + e.ToString(); + objJsonResult.data = null; + return objJsonResult; + } + } + #endregion + + } +} diff --git "a/WebAPI/Controllers/\351\241\271\347\233\256\347\256\241\347\220\206/\345\267\245\344\275\234\344\273\273\345\212\241/PM_WorkTaskBillController.cs" "b/WebAPI/Controllers/\351\241\271\347\233\256\347\256\241\347\220\206/\345\267\245\344\275\234\344\273\273\345\212\241/PM_WorkTaskBillController.cs" index 844703b..e6009d5 100644 --- "a/WebAPI/Controllers/\351\241\271\347\233\256\347\256\241\347\220\206/\345\267\245\344\275\234\344\273\273\345\212\241/PM_WorkTaskBillController.cs" +++ "b/WebAPI/Controllers/\351\241\271\347\233\256\347\256\241\347\220\206/\345\267\245\344\275\234\344\273\273\345\212\241/PM_WorkTaskBillController.cs" @@ -66,6 +66,7 @@ public string HMainSourceBillNo; public string HMainSourceBillType; public int HOrderLevID; + public int HTaskClassID; } #endregion @@ -184,7 +185,7 @@ string HMainSourceBillNo = mainList[0].HMainSourceBillNo; string HMainSourceBillType = mainList[0].HMainSourceBillType; int HOrderLevID = mainList[0].HOrderLevID; - + int HTaskClassID = mainList[0].HTaskClassID; if (OperationType == 2) @@ -206,7 +207,7 @@ { string sql = "insert into PM_WorkTaskBillMain" + "(HYear,HPeriod,HBillType,HBillSubType,HInterID,HBillNo,HProjectID,HProNumber,HProjectStageID,HName,HDate,HTaskNote,HPlanTimes" + - ",HSelfTimes,HLastDate,HSendEmp,HReceiveEmp,HType,HCopyEmp,HRemark,HOrgID,HMaker,HMakeDate,HMainSourceInterID,HMainSourceEntryID,HMainSourceBillNo,HMainSourceBillType,HOrderLevID)" + + ",HSelfTimes,HLastDate,HSendEmp,HReceiveEmp,HType,HCopyEmp,HRemark,HOrgID,HMaker,HMakeDate,HMainSourceInterID,HMainSourceEntryID,HMainSourceBillNo,HMainSourceBillType,HOrderLevID,HTaskClassID)" + "values(" + "" + HYear + "," + HPeriod + @@ -236,6 +237,7 @@ ",'" + HMainSourceBillNo + "','" + HMainSourceBillType + "','" + HOrderLevID + + "','"+ HTaskClassID+ "')"; //涓昏〃 @@ -273,6 +275,7 @@ ",HMainSourceBillNo = '" + HMainSourceBillNo + "',HMainSourceBillType = '" + HMainSourceBillType + "',HOrderLevID = '" + HOrderLevID + + "',HTaskClassID = '" + HTaskClassID + "' where HInterID = " + HInterID; oCN.RunProc(sql); diff --git "a/WebAPI/Controllers/\351\241\271\347\233\256\347\256\241\347\220\206/\345\267\245\347\250\213\351\241\271\347\233\256/PM_ProjectBillController.cs" "b/WebAPI/Controllers/\351\241\271\347\233\256\347\256\241\347\220\206/\345\267\245\347\250\213\351\241\271\347\233\256/PM_ProjectBillController.cs" index 82f7912..1205101 100644 --- "a/WebAPI/Controllers/\351\241\271\347\233\256\347\256\241\347\220\206/\345\267\245\347\250\213\351\241\271\347\233\256/PM_ProjectBillController.cs" +++ "b/WebAPI/Controllers/\351\241\271\347\233\256\347\256\241\347\220\206/\345\267\245\347\250\213\351\241\271\347\233\256/PM_ProjectBillController.cs" @@ -34,6 +34,12 @@ public DAL.ClsPM_ProjectMoneyBillMain BillNew4 = new DAL.ClsPM_ProjectMoneyBillMain(); //椤圭洰璐圭敤鍗曞搴斿崟鎹被 public DAL.ClsPM_ProjectMoneyBillMain BillOld4 = new DAL.ClsPM_ProjectMoneyBillMain(); + public DAL.ClsPM_ProjectBeginBillMain BillNew5 = new DAL.ClsPM_ProjectBeginBillMain(); //椤圭洰鍚姩鍗曞搴斿崟鎹被 + public DAL.ClsPM_ProjectBeginBillMain BillOld5 = new DAL.ClsPM_ProjectBeginBillMain(); + + public DAL.ClsPM_ProjectEndBillMain BillNew6 = new DAL.ClsPM_ProjectEndBillMain(); //椤圭洰楠屾敹鍗曞搴斿崟鎹被 + public DAL.ClsPM_ProjectEndBillMain BillOld6 = new DAL.ClsPM_ProjectEndBillMain(); + #region 宸ョ▼椤圭洰 鏂板/缂栬緫 #region 宸ョ▼椤圭洰 琛ㄥご鏁版嵁 public class PM_ProjectBill_Main @@ -3255,7 +3261,7 @@ if (refSav == "Add") { //鍗曟嵁鍙锋槸鍚﹂噸澶� - if (BillNew1.IsExistBillNo(ref ClsPub.sExeReturnInfo, oItem.HBillNo, BillStatus, BillOld.omodel.HInterID)) + if (BillNew5.IsExistBillNo(ref ClsPub.sExeReturnInfo, oItem.HBillNo, BillStatus, BillOld.omodel.HInterID)) { objJsonResult.code = "0"; objJsonResult.count = 0; @@ -3266,7 +3272,7 @@ } if (refSav == "Update") { - if (BillOld1.ShowBill(oItem.HInterID, ref s) == false) + if (BillOld5.ShowBill(oItem.HInterID, ref s) == false) { objJsonResult.code = "0"; objJsonResult.count = 0; @@ -3275,7 +3281,7 @@ return objJsonResult; } //鍒ゆ柇鏄惁鍙紪杈� - if (BillOld1.omodel.HChecker != "" && BillOld1.omodel.HChecker != null) + if (BillOld5.omodel.HChecker != "" && BillOld5.omodel.HChecker != null) { objJsonResult.code = "0"; objJsonResult.count = 0; @@ -3283,7 +3289,7 @@ objJsonResult.data = 1; return objJsonResult; } - if (BillOld1.omodel.HBillStatus > 1) + if (BillOld5.omodel.HBillStatus > 1) { objJsonResult.code = "0"; objJsonResult.count = 0; @@ -3893,7 +3899,7 @@ if (refSav == "Add") { //鍗曟嵁鍙锋槸鍚﹂噸澶� - if (BillNew1.IsExistBillNo(ref ClsPub.sExeReturnInfo, oItem.HBillNo, BillStatus, BillOld.omodel.HInterID)) + if (BillNew6.IsExistBillNo(ref ClsPub.sExeReturnInfo, oItem.HBillNo, BillStatus, BillOld.omodel.HInterID)) { objJsonResult.code = "0"; objJsonResult.count = 0; @@ -3904,7 +3910,7 @@ } if (refSav == "Update") { - if (BillOld1.ShowBill(oItem.HInterID, ref s) == false) + if (BillOld6.ShowBill(oItem.HInterID, ref s) == false) { objJsonResult.code = "0"; objJsonResult.count = 0; @@ -3913,7 +3919,7 @@ return objJsonResult; } //鍒ゆ柇鏄惁鍙紪杈� - if (BillOld1.omodel.HChecker != "" && BillOld1.omodel.HChecker != null) + if (BillOld6.omodel.HChecker != "" && BillOld6.omodel.HChecker != null) { objJsonResult.code = "0"; objJsonResult.count = 0; @@ -3921,7 +3927,7 @@ objJsonResult.data = 1; return objJsonResult; } - if (BillOld1.omodel.HBillStatus > 1) + if (BillOld6.omodel.HBillStatus > 1) { objJsonResult.code = "0"; objJsonResult.count = 0; diff --git a/WebAPI/DLL/ClsGy_Material_Ctl.cs b/WebAPI/DLL/ClsGy_Material_Ctl.cs index af9c685..4a988b6 100644 --- a/WebAPI/DLL/ClsGy_Material_Ctl.cs +++ b/WebAPI/DLL/ClsGy_Material_Ctl.cs @@ -27,7 +27,7 @@ ",HSubjoin,HSubjoin2,HColor,HVersion,HEngName,HEngModel,HPropertyTypeID,HSPGroupID,HSPID,HMinPickQty,HUSEORGID,HERPItemID" + ",HSALEUNITID,HSALEPRICEUNITID,HBASEUNITID,HSTOREUNITID,HCHECKINCOMING,HCHECKPRODUCT,HPERUNITSTANDHOUR" + ",HSTDLABORPREPARETIME,HSTDMACHINEPREPARETIME,HWidth,HWeight,HColorRemark,HQCSchemeID_Fst,HQCSchemeID_Proc,HQCSchemeID_Patrol" + - ",HMaterRuleType,HColorNo,HPieceMaxQty,HCommonUseFlag,HAvgStockPrice,HFootPrice,HTaxCost,HNoTaxCost) " + + ",HMaterRuleType,HColorNo,HPieceMaxQty,HCommonUseFlag,HAvgStockPrice,HFootPrice,HTaxCost,HNoTaxCost,HOnceRightRate) " + " Values('" + oModel.HNumber + "','" + oModel.HName + "','" + oModel.HHelpCode + "','" + oModel.HShortNumber + "'," + oModel.HParentID.ToString() + ", " + oModel.HLevel.ToString() + "," + Convert.ToString(oModel.HEndFlag ? 1 : 0) + "," + Convert.ToString(oModel.HStopflag ? 1 : 0) + ",'" + oModel.HRemark + "'" + ",'" + oModel.HModel + "'," + oModel.HUnitID.ToString() + "," + oModel.HMaterClsID.ToString() + "," + oModel.HMaterTypeID.ToString() + "," + oModel.HUnitGroupID.ToString() + @@ -36,7 +36,7 @@ ", " + oModel.HKeepDays.ToString() + "," + oModel.HPlanPrice.ToString() + "," + oModel.HstdPrice.ToString() + "," + oModel.HQtyMin.ToString() + "," + oModel.HQtyMax.ToString() + ",'" + oModel.HSubjoin + "','" + oModel.HSubjoin2 + "','" + oModel.HColor + "','" + oModel.HVersion + "','" + oModel.HEngName + "','" + oModel.HEngModel + "'," + oModel.HPropertyTypeID.ToString() + "," + oModel.HSPGroupID.ToString() + "," + oModel.HSPID.ToString() + "," + oModel.HMinPickQty.ToString() + "," + oModel.HUSEORGID + "," + oModel.HERPItemID + "," + oModel.HSALEUNITID + "," + oModel.HSALEPRICEUNITID + "," + oModel.HBASEUNITID + "," + oModel.HSTOREUNITID + "," + oModel.HCHECKINCOMING + "," + oModel.HCHECKPRODUCT + "," + oModel.HPERUNITSTANDHOUR + "," + oModel.HSTDLABORPREPARETIME + "," + oModel.HSTDMACHINEPREPARETIME + ","+ oModel.HWidth + "," + oModel.HWeight + ",'"+ oModel.HColorRemark + "'," + oModel.HQCSchemeID_Fst + "," + oModel.HQCSchemeID_Proc + "," + oModel.HQCSchemeID_Patrol + "" + - ",'"+ oModel.HMaterRuleType + "','"+ oModel.HColorNo + "','" + oModel.HPieceMaxQty.ToString() + "','" + oModel.HCommonUseFlag.ToString() + "','" + oModel.HAvgStockPrice.ToString() + "','" + oModel.HFootPrice.ToString() + "','" + oModel.HTaxCost.ToString() + "','" + oModel.HNoTaxCost.ToString() + "')", ref DBUtility.ClsPub.sExeReturnInfo); + ",'"+ oModel.HMaterRuleType + "','"+ oModel.HColorNo + "','" + oModel.HPieceMaxQty.ToString() + "','" + oModel.HCommonUseFlag.ToString() + "','" + oModel.HAvgStockPrice.ToString() + "','" + oModel.HFootPrice.ToString() + "','" + oModel.HTaxCost.ToString() + "','" + oModel.HNoTaxCost.ToString() + "'," + oModel.HOnceRightRate + ")", ref DBUtility.ClsPub.sExeReturnInfo); //淇敼涓婄骇涓洪潪鏈骇浠g爜 oCn.RunProc("Update " + MvarItemKey + " set HEndflag=0 where HItemID=" + oModel.HParentID, ref DBUtility.ClsPub.sExeReturnInfo); oCn.Commit(); @@ -154,6 +154,7 @@ ",HFootPrice=" + oModel.HFootPrice.ToString() + ",HTaxCost=" + oModel.HTaxCost.ToString() + ",HNoTaxCost=" + oModel.HNoTaxCost.ToString() + + ",HOnceRightRate=" + oModel.HOnceRightRate.ToString() + ",HSTDMACHINEPREPARETIME=" + oModel.HSTDMACHINEPREPARETIME.ToString() + "Where HItemID=" + sItemID, ref DBUtility.ClsPub.sExeReturnInfo); //淇敼瀛愰」鐩唬鐮� oCn.RunProc("exec h_p_Gy_UpdateNumber '" + MvarItemKey + "','" + oModel.HNumber + ".','" + this.HOldNumber + ".'", ref DBUtility.ClsPub.sExeReturnInfo); diff --git a/WebAPI/DLL/ClsQC_PatrolProcCheckBill.cs b/WebAPI/DLL/ClsQC_PatrolProcCheckBill.cs index 8372902..e8511ee 100644 --- a/WebAPI/DLL/ClsQC_PatrolProcCheckBill.cs +++ b/WebAPI/DLL/ClsQC_PatrolProcCheckBill.cs @@ -94,6 +94,8 @@ //",HMaterID=" + omodel.HMaterID.ToString() + ",HFirstCheckEmp=" + omodel.HFirstCheckEmp.ToString() + ",HMainProcID=" + omodel.HMainProcID.ToString() + + ",HShiftsID=" + omodel.HShiftsID.ToString() + + ",HErrTreatment='" + omodel.HErrTreatment + "'" + " where HInterID=" + lngBillKey.ToString(); //鏇存柊涓昏〃 oCn.RunProc(sqlerro); @@ -223,12 +225,12 @@ "(HBillType,HBillSubType,HInterID,HBillNo,HBillStatus,HDate,HMaker,HMakeDate" + ",HYear,HPeriod,HRemark" + ",HSourceID,HICMOInterID,HICMOBillNo,HICMOQty,HProcExchInterID,HProcExchEntryID" + - ",HProcExchBillNo,HProcExchQty,HMaterID,HFirstCheckEmp,HMainProcID,HLastResult" + + ",HProcExchBillNo,HProcExchQty,HMaterID,HFirstCheckEmp,HMainProcID,HLastResult,HShiftsID,HErrTreatment" + ") " + " values('" + this.BillType + "','" + this.HBillSubType + "'," + omodel.HInterID.ToString() + ",'" + omodel.HBillNo + "'," + omodel.HBillStatus.ToString() + ",'" + omodel.HDate + "','" + omodel.HMaker + "',getdate()" + "," + omodel.HYear.ToString() + "," + omodel.HPeriod.ToString() + ",'" + omodel.HRemark + "'" + "," + omodel.HSourceID.ToString() + "," + omodel.HICMOInterID.ToString() + ",'" + omodel.HICMOBillNo + "'," + omodel.HICMOQty.ToString() + "," + omodel.HProcExchInterID.ToString() + "," + omodel.HProcExchEntryID.ToString() + - ",'" + omodel.HProcExchBillNo + "'," + omodel.HProcExchQty.ToString() + "," + omodel.HMaterID.ToString() + "," + omodel.HFirstCheckEmp.ToString() + "," + omodel.HMainProcID +" ,"+ omodel.HLastResult + + ",'" + omodel.HProcExchBillNo + "'," + omodel.HProcExchQty.ToString() + "," + omodel.HMaterID.ToString() + "," + omodel.HFirstCheckEmp.ToString() + "," + omodel.HMainProcID +" ,"+ omodel.HLastResult + "," + omodel.HShiftsID + ",'" + omodel.HErrTreatment + "'" + ") "); //鎻掑叆瀛愯〃 foreach (Model.ClsQC_PatrolProcCheckBillSub oSub in DetailColl) diff --git a/WebAPI/DLL/ClsSb_EquipDotCheckRuleBill.cs b/WebAPI/DLL/ClsSb_EquipDotCheckRuleBill.cs index b02339f..7d74108 100644 --- a/WebAPI/DLL/ClsSb_EquipDotCheckRuleBill.cs +++ b/WebAPI/DLL/ClsSb_EquipDotCheckRuleBill.cs @@ -57,13 +57,13 @@ "HCloseMan,HEntryCloseDate,HCloseType,HRemark," + "HSourceInterID,HSourceEntryID,HSourceBillNo,HSourceBillType,HRelationQty,HRelationMoney," + "HDotCheckItemID,HDotCheckItem,HDotCheckPart,HClaim," + - "HManagerID" + + "HManagerID,HDotCheckItemClassID,HDotCheckItemMethodID" + ") values(" + omodel.HInterID.ToString() + "," + oSub.HEntryID.ToString() + ",'" + oSub.HCloseMan + "','" + oSub.HEntryCloseDate + "'," + Convert.ToString(oSub.HCloseType ? 1 : 0) + ",'" + oSub.HRemark + "'" + "," + oSub.HSourceInterID.ToString() + "," + oSub.HSourceEntryID.ToString() + ",'" + oSub.HSourceBillNo + "','" + oSub.HSourceBillType + "'," + oSub.HRelationQty.ToString() + "," + oSub.HRelationMoney.ToString() + ",'" + oSub.HDotCheckItemID + "','" + oSub.HDotCheckItem + "','" + oSub.HDotCheckPart + "','" + oSub.HClaim + - "'," + oSub.HManagerID.ToString() + + "'," + oSub.HManagerID.ToString() + "," + oSub.HDotCheckItemClassID + "," + oSub.HDotCheckItemMethodID + ") "); } sReturn = "淇敼鍗曟嵁鎴愬姛锛�"; @@ -104,13 +104,13 @@ "HCloseMan,HEntryCloseDate,HCloseType,HRemark," + "HSourceInterID,HSourceEntryID,HSourceBillNo,HSourceBillType,HRelationQty,HRelationMoney," + "HDotCheckItemID,HDotCheckItem,HDotCheckPart,HClaim," + - "HManagerID" + + "HManagerID,HDotCheckItemClassID,HDotCheckItemMethodID" + ") values(" + omodel.HInterID.ToString() + "," + oSub.HEntryID.ToString() + ",'" + oSub.HCloseMan + "','" + oSub.HEntryCloseDate + "'," + Convert.ToString(oSub.HCloseType ? 1 : 0) + ",'" + oSub.HRemark + "'" + "," + oSub.HSourceInterID.ToString() + "," + oSub.HSourceEntryID.ToString() + ",'" + oSub.HSourceBillNo + "','" + oSub.HSourceBillType + "'," + oSub.HRelationQty.ToString() + "," + oSub.HRelationMoney.ToString() + ",'" + oSub.HDotCheckItemID + "','" + oSub.HDotCheckItem + "','" + oSub.HDotCheckPart + "','" + oSub.HClaim + - "'," + oSub.HManagerID.ToString() + + "'," + oSub.HManagerID.ToString() + "," + oSub.HDotCheckItemClassID + "," + oSub.HDotCheckItemMethodID + ") "); } sReturn = "鏂板鍗曟嵁鎴愬姛锛�"; diff --git a/WebAPI/ListModels.cs b/WebAPI/ListModels.cs index 1d17cd2..b4c6991 100644 --- a/WebAPI/ListModels.cs +++ b/WebAPI/ListModels.cs @@ -1796,6 +1796,30 @@ } /// <summary> + /// 澶勭悊鏂板鐐规椤圭洰鍒嗙被琛ㄧ殑json + /// </summary> + /// <param name="jsonString"></param> + /// <returns></returns> + public List<Model.ClsGy_DotCheckItemClass_Model> getObjectByJson_Gy_DotCheckItemClass(string jsonString) + { + jsonString = "[" + jsonString.ToString() + "]"; + List<Model.ClsGy_DotCheckItemClass_Model> list = Newtonsoft.Json.JsonConvert.DeserializeObject<List<Model.ClsGy_DotCheckItemClass_Model>>(jsonString); + return list; + } + + /// <summary> + /// 澶勭悊鏂板鐐规鏂规硶琛ㄧ殑json + /// </summary> + /// <param name="jsonString"></param> + /// <returns></returns> + public List<Model.ClsGy_DotCheckItemMethod_Model> getObjectByJson_Gy_DotCheckItemMethod(string jsonString) + { + jsonString = "[" + jsonString.ToString() + "]"; + List<Model.ClsGy_DotCheckItemMethod_Model> list = Newtonsoft.Json.JsonConvert.DeserializeObject<List<Model.ClsGy_DotCheckItemMethod_Model>>(jsonString); + return list; + } + + /// <summary> /// 澶勭悊鏂板鏉$爜鎷嗙爜鐨刯son /// </summary> /// <param name="jsonString"></param> diff --git a/WebAPI/Models/CheckItem.cs b/WebAPI/Models/CheckItem.cs index fadcbf3..628b405 100644 --- a/WebAPI/Models/CheckItem.cs +++ b/WebAPI/Models/CheckItem.cs @@ -27,5 +27,17 @@ public string HQCCheckClassName { get; set; }//妫�楠岄」鐩被鍒� public string HDefaultResult { get; set; }//榛樿缁撹 + + public long HUnitID { get; set; } // + public string HAnalysisMethod { get; set; } // + public string HDefectLevel { get; set; } // + public long HDestructInspect { get; set; } // + public long HKeyInspect { get; set; } // + public long HQualityStdID { get; set; } // + public long HInspectMethodID { get; set; } // + public long HInspectInstruMentID { get; set; } // + public long HInspectBasisID { get; set; } // + public long HSampleSchemeID { get; set; } // + public long HISsystemSet { get; set; } // } } \ No newline at end of file diff --git a/WebAPI/Models/ClsGy_DotCheck.cs b/WebAPI/Models/ClsGy_DotCheck.cs index 9f84d7c..280788c 100644 --- a/WebAPI/Models/ClsGy_DotCheck.cs +++ b/WebAPI/Models/ClsGy_DotCheck.cs @@ -19,5 +19,6 @@ public string HRemark; //澶囨敞 public string HUseFlag = "鏈娇鐢�"; + public Int64 HDotCheckItemClassID; //鐐规椤圭洰鍒嗙被 } } \ No newline at end of file diff --git a/WebAPI/Models/ClsGy_Material_Model.cs b/WebAPI/Models/ClsGy_Material_Model.cs index ad2b096..77107ef 100644 --- a/WebAPI/Models/ClsGy_Material_Model.cs +++ b/WebAPI/Models/ClsGy_Material_Model.cs @@ -75,5 +75,6 @@ public double HNoTaxCost; // 涓嶅惈绋庢垚鏈环 + public double HOnceRightRate; //涓�娆″悎鏍肩巼鏍囧噯鍊� } } \ No newline at end of file diff --git a/WebAPI/Models/ClsSb_EquipDotCheckRuleBillSub.cs b/WebAPI/Models/ClsSb_EquipDotCheckRuleBillSub.cs index 005d6f0..d940b04 100644 --- a/WebAPI/Models/ClsSb_EquipDotCheckRuleBillSub.cs +++ b/WebAPI/Models/ClsSb_EquipDotCheckRuleBillSub.cs @@ -12,5 +12,8 @@ public string HDotCheckPart;// varchar(100) --鐐规閮ㄤ綅 public string HClaim;// varchar(100) --鍏蜂綋瑕佹眰 public int HManagerID;// int --璐熻矗浜篿d(鑱屽憳琛�) + + public Int64 HDotCheckItemClassID;//鐐规椤圭洰鍒嗙被id + public Int64 HDotCheckItemMethodID;//鐐规鏂规硶id } } \ No newline at end of file diff --git a/WebAPI/Models/StationBill.cs b/WebAPI/Models/StationBill.cs index 6a49935..9b047c6 100644 --- a/WebAPI/Models/StationBill.cs +++ b/WebAPI/Models/StationBill.cs @@ -81,5 +81,10 @@ public long HMainSourceInterID { get; set; } public long HMainSourceEntryID { get; set; } public string HMainSourceBillNo { get; set; } + + public double HWasterQty_Work { get; set; } + public double HWasterQty_Mater { get; set; } + public double HBackWorkQty { get; set; } + public Int64 HShiftsID { get; set; } } } \ No newline at end of file diff --git a/WebAPI/WebAPI.csproj b/WebAPI/WebAPI.csproj index b39d31c..8f86aab 100644 --- a/WebAPI/WebAPI.csproj +++ b/WebAPI/WebAPI.csproj @@ -524,6 +524,8 @@ <Compile Include="Controllers\鍩虹璧勬枡\鍩虹璧勬枡\Gy_CardTypeController.cs" /> <Compile Include="Controllers\鍩虹璧勬枡\鍩虹璧勬枡\Gy_COMMONCONTACTBillController.cs" /> <Compile Include="Controllers\鍩虹璧勬枡\鍩虹璧勬枡\Gy_CustLocationController.cs" /> + <Compile Include="Controllers\鍩虹璧勬枡\鍩虹璧勬枡\Gy_DotCheckItemMethodController.cs" /> + <Compile Include="Controllers\鍩虹璧勬枡\鍩虹璧勬枡\Gy_DotCheckItemClassController.cs" /> <Compile Include="Controllers\鍩虹璧勬枡\鍩虹璧勬枡\Gy_DutyBillController.cs" /> <Compile Include="Controllers\鍩虹璧勬枡\鍩虹璧勬枡\Gy_EquipStatusController.cs" /> <Compile Include="Controllers\鍩虹璧勬枡\鍩虹璧勬枡\Gy_MatePriceSupController.cs" /> -- Gitblit v1.9.1