From e03ff94e4ec510f5cc1af2ecf11f486bf6819496 Mon Sep 17 00:00:00 2001
From: 沈泽 <211959439@qq.com>
Date: 星期四, 28 十月 2021 16:28:04 +0800
Subject: [PATCH] 1

---
 DAL/车间管理/ClsSc_ProcessExchangeBill.cs |   72 ++++++++++++++++++++++++++++++++++-
 1 files changed, 69 insertions(+), 3 deletions(-)

diff --git "a/DAL/\350\275\246\351\227\264\347\256\241\347\220\206/ClsSc_ProcessExchangeBill.cs" "b/DAL/\350\275\246\351\227\264\347\256\241\347\220\206/ClsSc_ProcessExchangeBill.cs"
index a6c3598..59e7baa 100644
--- "a/DAL/\350\275\246\351\227\264\347\256\241\347\220\206/ClsSc_ProcessExchangeBill.cs"
+++ "b/DAL/\350\275\246\351\227\264\347\256\241\347\220\206/ClsSc_ProcessExchangeBill.cs"
@@ -63,6 +63,7 @@
                 " HBillNo='" + omodel.HBillNo + "'" +  //鍥哄畾璧嬪��===============
                 ",HDate='" + omodel.HDate + "'" +
                 ",HYear='" + omodel.HYear.ToString() + "'" +
+                ",HPRDORGID='" + omodel.HPRDORGID.ToString() + "'" +
                 ",HPeriod='" + omodel.HPeriod.ToString() + "'" +
                 ",HRemark='" + omodel.HRemark + "'" +
                 ",HUpDater='" + DBUtility.ClsPub.CurUserName + "'" +
@@ -287,7 +288,7 @@
                 ",HProdMaterName,HCusName,HWorkRemark,HImportNote,HMaterNumber_A" +
                 ",HMaterNumber_B,HMaterNumber_C,HMaterNumber_D,HProdType,HMaterShortName" +
                 ",HMaterIDA,HMaterIDB,HMaterIDC,HMaterIDD,HICMOEntryID" +
-                ",HPicNumVer,HPicNumAssemble,HMaterTexture,HProductNum,HVerNum" +
+                ",HPicNumVer,HPicNumAssemble,HMaterTexture,HProductNum,HVerNum,HPRDORGID" +
                 ") " +
                 " values('" + this.BillType + "','" + this.HBillSubType + "'," + omodel.HInterID.ToString() + ",'" + omodel.HBillNo + "','" + omodel.HDate + "','" + omodel.HMaker + "',getdate()," + "" + (omodel.HPrevMainSourceInterID == 0 ? omodel.HInterID : omodel.HPrevMainSourceInterID) +
                 "," + omodel.HYear.ToString() + "," + omodel.HPeriod.ToString() + ",'" + omodel.HRemark + "','" + omodel.HBatchNo + "'," + omodel.HMainMaterID.ToString() + "," + omodel.HKeyMaterID.ToString() + "," + omodel.HNo.ToString() + ",'" + omodel.HOrderProcNO + "'" +
@@ -299,11 +300,76 @@
                 ",'" + omodel.HProdMaterName + "','" + omodel.HCusName + "','" + omodel.HWorkRemark + "','" + omodel.HImportNote + "','" + omodel.HMaterNumber_A + "'" +
                 ",'" + omodel.HMaterNumber_B + "','" + omodel.HMaterNumber_C + "','" + omodel.HMaterNumber_D + "','" + omodel.HProdType + "','" + omodel.HMaterShortName + "'" +
                 ",'" + omodel.HMaterIDA + "','" + omodel.HMaterIDB + "','" + omodel.HMaterIDC + "','" + omodel.HMaterIDD + "'," + omodel.HICMOEntryID +
-                ",'" + omodel.HPicNumVer + "','" + omodel.HPicNumAssemble + "','" + omodel.HMaterTexture + "','" + omodel.HProductNum + "','" + omodel.HVerNum + "'" +
+                ",'" + omodel.HPicNumVer + "','" + omodel.HPicNumAssemble + "','" + omodel.HMaterTexture + "','" + omodel.HProductNum + "','" + omodel.HVerNum + "','"+ omodel.HPRDORGID+ "'" +
                 ") ");
                 //鎻掑叆瀛愯〃
                 foreach (Model.ClsSc_ProcessExchangeBillSub oSub in DetailColl)
                 {
+
+                    string HInterID = omodel.HInterID.ToString();
+                    string HEntryID = oSub.HEntryID.ToString();
+                    string HBillNo = omodel.HBillNo;
+                    string HCloseMan = oSub.HCloseMan;
+                    string HEntryCloseDate = oSub.HEntryCloseDate.ToString();
+                    string HCloseType = Convert.ToString(oSub.HCloseType ? 1 : 0);
+                    string HRemark = oSub.HRemark;
+                    string HSourceInterID = oSub.HSourceInterID.ToString();
+                    string HSourceEntryID = oSub.HSourceEntryID.ToString();
+                    string HSourceBillNo = oSub.HSourceBillNo;
+                    string HSourceBillType = oSub.HSourceBillType;
+                    string HRelationQty = oSub.HRelationQty.ToString();
+                    string HRelationMoney = oSub.HRelationMoney.ToString();
+                    string HProcNo = oSub.HProcNo.ToString();
+                    string HProcID = oSub.HProcID.ToString();
+                    string HProcNumber = oSub.HProcNumber;
+                    string HWorkRemark = oSub.HWorkRemark;
+                    string HCenterID = oSub.HCenterID.ToString();
+                    string HDeptID = oSub.HDeptID.ToString();
+                    string HDeptNumber = oSub.HDeptNumber;
+                    string HGroupID = oSub.HGroupID.ToString();
+                    string HGroupNumber = oSub.HGroupNumber;
+                    string HWorkerID = oSub.HWorkerID.ToString();
+                    string HWorkerNumber = oSub.HWorkerNumber;
+                    string HSourceID = oSub.HSourceID.ToString();
+                    string HQty = oSub.HQty.ToString();
+                    string HTimeUnit = oSub.HTimeUnit;
+                    string HPlanWorkTimes = oSub.HPlanWorkTimes.ToString();
+                    string HPlanBeginDate = oSub.HPlanBeginDate.ToShortDateString();
+                    string HPlanEndDate = oSub.HPlanEndDate.ToShortDateString();
+                    string HRelBeginDate = oSub.HRelBeginDate.ToShortDateString();
+                    string HRelEndDate = oSub.HRelEndDate.ToShortDateString();
+                    string HReadyTime = oSub.HReadyTime.ToString();
+                    string HQueueTime = oSub.HQueueTime.ToString();
+                    string HMoveTime = oSub.HMoveTime.ToString();
+                    string HBeginDayQty = oSub.HBeginDayQty.ToString();
+                    string HBeginFixQty = oSub.HBeginFixQty.ToString();
+                    string HFixWorkDays = oSub.HFixWorkDays.ToString();
+                    string HTrunWorkDays = oSub.HTrunWorkDays.ToString();
+                    string HReadyTimes = oSub.HReadyTimes.ToString();
+                    string HMyWorkDays = oSub.HMyWorkDays.ToString();
+                    string HOutPrice = oSub.HOutPrice.ToString();
+                    string HOutMoney = oSub.HOutMoney.ToString();
+                    string HPassRate = oSub.HPassRate.ToString();
+                    string HLastProc = oSub.HLastProc;
+                    string HKeyProc = oSub.HKeyProc;
+                    string HFstProc = oSub.HFstProc;
+                    string HICMOInterID = oSub.HICMOInterID.ToString();
+                    string HICMOBillNo = oSub.HICMOBillNo;
+                    string HWWOrderInterID = oSub.HWWOrderInterID.ToString();
+                    string HWWOrderEntryID = oSub.HWWOrderEntryID.ToString();
+                    string HWWOrderBillNo = oSub.HWWOrderBillNo;
+                    string HReportQty = oSub.HReportQty.ToString();
+                    string HBackProc = Convert.ToString(oSub.HBackProc ? 1 : 0);
+                    string HSupID = oSub.HSupID.ToString();
+                    string HSupFlag = Convert.ToString(oSub.HSupFlag ? 1 : 0);
+                    string HOverRate = oSub.HOverRate.ToString();
+                    string HMaxQty = oSub.HMaxQty.ToString();
+                    string HTechnologyParameter = oSub.HTechnologyParameter;
+                    string HProcCheckNote = oSub.HProcCheckNote;
+                    string HPicNum = oSub.HPicNum;
+                    string HMouldNo = oSub.HMouldNo.ToString();
+                    string HProcWorkNum = oSub.HProcWorkNum.ToString();
+
                     oCn.RunProc("Insert into Sc_ProcessExchangeBillSub " +
                       " (HInterID,HEntryID,HBillNo_bak," +
                       "HCloseMan,HEntryCloseDate,HCloseType,HRemark," +
@@ -391,7 +457,7 @@
             {
                 //鏌ヨ涓昏〃
                 DataSet Ds;
-                Ds = oCn.RunProcReturn("Select * from Sc_ProcessExchangeBillMain Where HInterID=" + lngBillKey.ToString(), "Sc_ProcessExchangeBillMain");
+                Ds = oCn.RunProcReturn("Select * from Sc_ProcessExchangeBillMain Where HInterID=" + lngBillKey.ToString()+" and HPRDORGID=" + DBUtility.ClsPub.HOrgID + " ", "Sc_ProcessExchangeBillMain");
                 if (Ds.Tables[0].Rows.Count == 0)
                 {
                     sReturn = "鍗曟嵁鏈壘鍒帮紒";

--
Gitblit v1.9.1