From 152a02e90a7da2d431d2ea75499c1d07ef495e1b Mon Sep 17 00:00:00 2001
From: yangle <admin@YINMOU>
Date: 星期四, 23 三月 2023 09:27:33 +0800
Subject: [PATCH] Merge branch 'master' of http://101.37.171.70:10101/r/MES-WEB-API

---
 DAL/生产管理/设备管理/ClsSb_EquipMaintainPlanBill.cs |   39 +++++++++++++++++++++------------------
 1 files changed, 21 insertions(+), 18 deletions(-)

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_EquipMaintainPlanBill.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_EquipMaintainPlanBill.cs"
index 5c55163..b4c6d51 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_EquipMaintainPlanBill.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_EquipMaintainPlanBill.cs"
@@ -41,7 +41,6 @@
                 //鏇存柊涓昏〃
                 oCn.RunProc("UpDate Sb_EquipMaintainPlanBillMain set  " +
                 " HBillNo='" + omodel.HBillNo + "'" +  //鍥哄畾璧嬪��===============
-                ",HDate='" + omodel.HDate + "'" +
                 ",HYear='" + omodel.HYear.ToString() + "'" +
                 ",HPeriod='" + omodel.HPeriod.ToString() + "'" +
                 ",HRemark='" + omodel.HRemark + "'" +
@@ -52,6 +51,7 @@
                 ",HBeginDate='" + omodel.HBeginDate + "'" +
                 ",HEndDate='" + omodel.HEndDate+"'" +
                 ",HCycleUnit='" + omodel.HCycleUnit + "'" +
+                ",HMouldMaintainRuleID='" + omodel.HMouldMaintainRuleID + "'" +
                 ",HCheckCycle=" + omodel.HCheckCycle.ToString() +
                 ",HExplanation='" + omodel.HExplanation+"'" +
                 ",HInnerBillNo='" + omodel.HInnerBillNo+"'" +
@@ -121,28 +121,31 @@
                 oCn.RunProc("Insert Into Sb_EquipMaintainPlanBillMain   " +
                 "(HBillType,HBillSubType,HInterID,HBillNo,HDate,HMaker,HMakeDate" +
                 ",HYear,HPeriod,HRemark,HEquipID" +
-                ",HBeginDate,HEndDate,HCheckCycle,HCycleUnit,HExplanation,HInnerBillNo" +
+                ",HBeginDate,HEndDate,HCheckCycle,HCycleUnit,HExplanation,HInnerBillNo,HMouldMaintainRuleID" +
                 ") "+
                 " values('" + this.BillType + "','"  + this.HBillSubType + "'," +omodel.HInterID.ToString() + ",'" + omodel.HBillNo + "','" + omodel.HDate + "','" + omodel.HMaker + "',getdate()" +
                 "," + omodel.HYear.ToString() + "," + omodel.HPeriod.ToString() + ",'" + omodel.HRemark + "'," + omodel.HEquipID.ToString() +
-                ",'" + omodel.HBeginDate +"','" +omodel.HEndDate + "'," + omodel.HCheckCycle.ToString() +",'"+ omodel.HCycleUnit + "','" + omodel.HExplanation + "','" + omodel.HInnerBillNo +"'" +
+                ",'" + omodel.HBeginDate +"','" +omodel.HEndDate + "'," + omodel.HCheckCycle.ToString() +",'"+ omodel.HCycleUnit + "','" + omodel.HExplanation + "','" + omodel.HInnerBillNo +"','" + omodel.HMouldMaintainRuleID + "'" +
                 ") ");
-                //鎻掑叆閰嶄欢瀛愯〃
-                foreach (Model.ClsSb_EquipMaintainPlanBillSub oSub in DetailColl)
+                if (DetailColl != null)
                 {
-                    oCn.RunProc("Insert into Sb_EquipMaintainPlanBillSub " +
-                      " (HInterID,HEntryID," +
-                      "HCloseMan,HEntryCloseDate,HCloseType,HRemark," +
-                      "HSourceInterID,HSourceEntryID,HSourceBillNo,HSourceBillType,HRelationQty,HRelationMoney," +
-                      "HQty,HMaterID,HMaterNumber,HUnitID,HUnitNumber,HQtyMust" +
-                      "HManagerID,HManagerNumber" +
-                      ") 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.HQty.ToString() + "," + oSub.HMaterID.ToString() + ",'" + oSub.HMaterNumber + "'," + oSub.HUnitID.ToString() + ",'" + oSub.HUnitNumber + "'," + oSub.HQtyMust.ToString() +
-                        "," + oSub.HManagerID.ToString() + ",'" + oSub.HManagerNumber + "'" +
-                      ") ");
+                    //鎻掑叆閰嶄欢瀛愯〃
+                    foreach (Model.ClsSb_EquipMaintainPlanBillSub oSub in DetailColl)
+                    {
+                        oCn.RunProc("Insert into Sb_EquipMaintainPlanBillSub " +
+                          " (HInterID,HEntryID," +
+                          "HCloseMan,HEntryCloseDate,HCloseType,HRemark," +
+                          "HSourceInterID,HSourceEntryID,HSourceBillNo,HSourceBillType,HRelationQty,HRelationMoney," +
+                          "HQty,HMaterID,HMaterNumber,HUnitID,HUnitNumber,HQtyMust," +
+                          "HManagerID" +
+                          ") 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.HQty.ToString() + "," + oSub.HMaterID.ToString() + ",'" + oSub.HMaterNumber + "'," + oSub.HUnitID.ToString() + ",'" + oSub.HUnitNumber + "'," + oSub.HQtyMust.ToString() +
+                            "," + oSub.HManagerID.ToString() +
+                          ") ");
+                    }
                 }
                 //鎻掑叆淇濆吇椤瑰瓙琛�
                 foreach (Model.ClsSc_EquipMaintainPlanBillSub_Item Item in DetailCol)

--
Gitblit v1.9.1