wtt
2024-07-03 8e404ab3b2d6542f32e9eaea2591f7439c013e19
DAL/²É¹º¹ÜÀí/ClsCg_PayableBill.cs
@@ -32,10 +32,35 @@
        #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")                      //采购入库单
@@ -94,7 +119,7 @@
                    ",HCurID = " + omodel.HCurID + "" +
                    ",HExRate = " + omodel.HExRate + "" +
                    ",HEmpID = " + omodel.HEmpID + "" +
                    ",HManagerID = " + omodel.HManagerID + "" +
                    ",HMangerID = " + omodel.HMangerID + "" +
                    ",HDeptID = " + omodel.HDeptID + "" +
                    ",HExplanation = '" + omodel.HExplanation + "'" +
                    ",HInnerBillNo = '" + omodel.HInnerBillNo + "'" +
@@ -225,7 +250,7 @@
                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 + "'" +
@@ -247,7 +272,7 @@
                    "," + omodel.HCurID + "" +
                    "," + omodel.HExRate + "" +
                    "," + omodel.HEmpID + "" +
                    "," + omodel.HManagerID + "" +
                    "," + omodel.HMangerID + "" +
                    "," + omodel.HDeptID + "" +
                    ",'" + omodel.HExplanation + "'" +
                    ",'" + omodel.HInnerBillNo + "'" +
@@ -383,7 +408,7 @@
                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"]);