| | |
| | | select hmainid HInterID, åæ®å· HBillNO from h_v_IF_MateOutBillList_Search where hmainid = {mainList[0].HInterID} |
| | | ", "h_v_IF_MateOutBillList_Search"); |
| | | |
| | | // if (ds1.Tables[0].Rows.Count > 0 && ds1.Tables[0].Rows[0]["HInterID"] != null) { |
| | | // if(string.Equals(ds1.Tables[0].Rows[0]["HBillNo"].ToString(), mainList[0].HBillNo, StringComparison.OrdinalIgnoreCase)){ |
| | | // string sql = string.Empty; |
| | | // sql = $"delete Kf_ICStockBillMain where HinterID = {mainList[0].HInterID}"; |
| | | // oCn.RunProc(sql); |
| | | // sql = $"delete Kf_ICStockBillSub where HinterID = {mainList[0].HInterID}"; |
| | | // oCn.RunProc(sql); |
| | | // } |
| | | // else |
| | | // { |
| | | // // éæ°ç³è¯·HInterID |
| | | // var HInterID_Exch = DBUtility.ClsPub.CreateBillID("1204", ref DBUtility.ClsPub.sExeReturnInfo); |
| | | // mainList[0].HInterID = HInterID_Exch; |
| | | // |
| | | // foreach(var oSub in subList) |
| | | // { |
| | | // oSub.HInterID = HInterID_Exch; |
| | | // } |
| | | // |
| | | // } |
| | | // } |
| | | string sql = string.Empty; |
| | | sql = $"delete Kf_ICStockBillMain where HinterID = {mainList[0].HInterID}"; |
| | | oCn.RunProc(sql); |
| | | sql = $"delete Kf_ICStockBillSub where HinterID = {mainList[0].HInterID}"; |
| | | oCn.RunProc(sql); |
| | | if (ds1.Tables[0].Rows.Count > 0 && ds1.Tables[0].Rows[0]["HInterID"] != null) { |
| | | if(string.Equals(ds1.Tables[0].Rows[0]["HBillNo"].ToString(), mainList[0].HBillNo, StringComparison.OrdinalIgnoreCase)){ |
| | | string sql = string.Empty; |
| | | sql = $"delete Kf_ICStockBillMain where HinterID = {mainList[0].HInterID}"; |
| | | oCn.RunProc(sql); |
| | | sql = $"delete Kf_ICStockBillSub where HinterID = {mainList[0].HInterID}"; |
| | | oCn.RunProc(sql); |
| | | } |
| | | else |
| | | { |
| | | // éæ°ç³è¯·HInterID |
| | | var HInterID_Exch = DBUtility.ClsPub.CreateBillID("1204", ref DBUtility.ClsPub.sExeReturnInfo); |
| | | mainList[0].HInterID = HInterID_Exch; |
| | | |
| | | foreach(var oSub in subList) |
| | | { |
| | | oSub.HInterID = HInterID_Exch; |
| | | } |
| | | |
| | | } |
| | | } |
| | | // string sql = string.Empty; |
| | | // sql = $"delete Kf_ICStockBillMain where HinterID = {mainList[0].HInterID}"; |
| | | // oCn.RunProc(sql); |
| | | // sql = $"delete Kf_ICStockBillSub where HinterID = {mainList[0].HInterID}"; |
| | | // oCn.RunProc(sql); |
| | | // 主表 |
| | | oCn.RunProc($@"Insert Into Kf_ICStockBillMain |
| | | ( |