| | |
| | | #endregion |
| | | #endregion |
| | | |
| | | //å é¤å
³è |
| | | public override void DeleteRelation(ref string sReturn, Int64 lngBillKey) |
| | | { |
| | | //éè´å
¥åºå éè´è®¢å å
³èæ°é |
| | | try |
| | | { |
| | | if (DetailColl[0].HSourceBillType == "1201") //éè´å
¥åºå |
| | | { |
| | | oCn.RunProc("exec h_p_Cg_UpDateRelation_POStockInToPayable_Del " + lngBillKey.ToString()); |
| | | } |
| | | else if (DetailColl[0].HSourceBillType == "1102") //éè´è®¢å |
| | | { |
| | | oCn.RunProc("exec h_p_Cg_UpDateRelation_POOrderToPayable_Del " + lngBillKey.ToString()); |
| | | } |
| | | else |
| | | { |
| | | |
| | | } |
| | | } |
| | | catch (Exception e) |
| | | { |
| | | throw (e); |
| | | } |
| | | } |
| | | |
| | | //æ°å¢å
³è |
| | | public override void AddNewRelation(ref string sReturn, Int64 lngBillKey) |
| | | { |
| | | //æ¶æéç¥å éæéç¥å å
³èæ°é |
| | | //éè´å
¥åºå éè´è®¢å å
³èæ°é |
| | | try |
| | | { |
| | | if (DetailColl[0].HSourceBillType == "1201") //éè´å
¥åºå |
| | |
| | | ",HCurID = " + omodel.HCurID + "" + |
| | | ",HExRate = " + omodel.HExRate + "" + |
| | | ",HEmpID = " + omodel.HEmpID + "" + |
| | | ",HManagerID = " + omodel.HManagerID + "" + |
| | | ",HMangerID = " + omodel.HMangerID + "" + |
| | | ",HDeptID = " + omodel.HDeptID + "" + |
| | | ",HExplanation = '" + omodel.HExplanation + "'" + |
| | | ",HInnerBillNo = '" + omodel.HInnerBillNo + "'" + |
| | |
| | | string mainSql = "insert into Cg_PayableBillMain" + |
| | | "(HInterID,HBillNo,HDate,HYear,HPeriod,HBillType,HBillSubType" + |
| | | ",HMainSourceInterID,HMainSourceEntryID,HMainSourceBillNo,HMainSourceBillType" + |
| | | ",HMaker,HMakeDate,HSSID,HPSStyleID,HReceiveDate,HSupID,HCurID,HExRate,HEmpID,HManagerID,HDeptID,HExplanation,HInnerBillNo,HRemark) " + |
| | | ",HMaker,HMakeDate,HSSID,HPSStyleID,HReceiveDate,HSupID,HCurID,HExRate,HEmpID,HMangerID,HDeptID,HExplanation,HInnerBillNo,HRemark) " + |
| | | "values(" + |
| | | "" + omodel.HInterID + "" + |
| | | ",'" + omodel.HBillNo + "'" + |
| | |
| | | "," + omodel.HCurID + "" + |
| | | "," + omodel.HExRate + "" + |
| | | "," + omodel.HEmpID + "" + |
| | | "," + omodel.HManagerID + "" + |
| | | "," + omodel.HMangerID + "" + |
| | | "," + omodel.HDeptID + "" + |
| | | ",'" + omodel.HExplanation + "'" + |
| | | ",'" + omodel.HInnerBillNo + "'" + |
| | |
| | | omodel.HCurID = DBUtility.ClsPub.isLong(Ds.Tables[0].Rows[0]["HCurID"]); |
| | | omodel.HExRate = DBUtility.ClsPub.isDoule(Ds.Tables[0].Rows[0]["HExRate"]); |
| | | omodel.HEmpID = DBUtility.ClsPub.isLong(Ds.Tables[0].Rows[0]["HEmpID"]); |
| | | omodel.HManagerID = DBUtility.ClsPub.isLong(Ds.Tables[0].Rows[0]["HManagerID"]); |
| | | omodel.HMangerID = DBUtility.ClsPub.isLong(Ds.Tables[0].Rows[0]["HMangerID"]); |
| | | omodel.HDeptID = DBUtility.ClsPub.isLong(Ds.Tables[0].Rows[0]["HDeptID"]); |
| | | |
| | | omodel.HExplanation = DBUtility.ClsPub.isStrNull(Ds.Tables[0].Rows[0]["HExplanation"]); |