yxj
2022-06-30 b63dd864e092dbeab2ffdd3c246a95112a18680e
森楷其他入库增加多源单扫码功能
2个文件已修改
98 ■■■■ 已修改文件
CLOUDWEB/WebService1.asmx.cs 98 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
DLL/Pub_Class.dll 补丁 | 查看 | 原始文档 | blame | 历史
CLOUDWEB/WebService1.asmx.cs
@@ -5906,10 +5906,9 @@
        [WebMethod]
        public bool set_SaveMoveBill_CLD(Model.ClsKf_MoveStockBillMain oMain, string sHSourceType, Pub_Class.ClsXt_SystemParameterMain oSystemParameterMain, ref string sErrMsg)
        {
            //领料调拨(源单:生产任务单-投料)
            if (sHSourceType == "3720")
            if (sHSourceType == "3720")//生产用料清单
            {
                if (SaveMoveMaterOut_CLD(oMain, oSystemParameterMain, ref sErrMsg))
                if (SaveMoveStockBill_PPBom_CLD(oMain, sHSourceType, oSystemParameterMain, ref sErrMsg))
                {
                    //"保存成功!";
                    sErrMsg = "保存成功!" + oMain.HBillNo;
@@ -5919,10 +5918,26 @@
                {
                    //"保存失败!";
                    sErrMsg = "单据号:" + oMain.HBillNo + ",单据ID:" + oMain.HInterID + ";" + sErrMsg;
                    //sErrMsg = sErrMsg;
                    return false;
                }
            }
            ////领料调拨(源单:生产任务单-投料)
            //if (sHSourceType == "3720")
            //{
            //    if (SaveMoveMaterOut_CLD(oMain, oSystemParameterMain, ref sErrMsg))
            //    {
            //        //"保存成功!";
            //        sErrMsg = "保存成功!" + oMain.HBillNo;
            //        return true;
            //    }
            //    else
            //    {
            //        //"保存失败!";
            //        sErrMsg = "单据号:" + oMain.HBillNo + ",单据ID:" + oMain.HInterID + ";" + sErrMsg;
            //        //sErrMsg = sErrMsg;
            //        return false;
            //    }
            //}
            //发货调拨(源单:发货通知单)
            else if (sHSourceType == "1402")
            {
@@ -7416,6 +7431,13 @@
                    //审核单据
                    oCn.RunProc("Update Kf_ICStockBillMain Set HChecker='" + oMain.HMaker + "',HCheckDate=convert(varchar(10),getdate(),120) where HInterID= " + oMain.HInterID.ToString());
                }
                if (oSystemParameterMain.WMS_MouldManagerCtl == "Y") //系统参数  启用器具管理
                {
                    string HMouldBillType = "3814";
                    oCn.RunProc("EXEC h_p_Sc_MouldStockBill_Insert_New " + oMain.HInterID.ToString() + ",'" + oMain.HBillType + "','" + HMouldBillType + "'," + oMain.HSupID.ToString() + "," + oMain.HKeeperID.ToString() + "," + oMain.HSecManagerID.ToString() + "," + oMain.HDeptID.ToString() + ",3");
                }
                //根据TMP表 返回 子表信息
                DataSet Ds;
@@ -33775,7 +33797,7 @@
            //蓝字产品入库、外购入库、委外入库、生产汇报,根据物料条码得到对应源单信息,非多源单模式
            //未扫描源单的情况下,第一次扫描物料条码获取源单信息并存入临时表
            //采购入库(1201)、产品入库(1202)、其他入库(1203)、委外入库(1210)、生产汇报(3711)
            if (SourceFlag == false && (HBillType == "1201" || HBillType == "1202" || HBillType == "1203" || HBillType == "1210" || HBillType == "3711"))
            if (SourceFlag == false && (HBillType == "1201" || HBillType == "1202" || HBillType == "1210" || HBillType == "3711"))
            {
                if (HSourceBillType != "-1")
                {
@@ -34289,6 +34311,44 @@
                        }
                        else
                        {
                            if (HBillType == "1203")
                            {
                                HSourceBillNo = DBUtility.ClsPub.isStrNull(dsTBarCode.Tables[0].Rows[0]["HSourceBillNo"]);
                                HSourceBillType = DBUtility.ClsPub.isStrNull(dsTBarCode.Tables[0].Rows[0]["HSourceBillType"]);
                                //oBar = get_SourceBarCode_OtherIn(HBillID, HBillNo, HBillType, HSourceBillNo, HSourceBillType, HMaker, HOWNERID, ref sErrMsg);
                                //if (oBar == null)
                                //{
                                //    return null;
                                //}
                                //SourceFlag = true;
                                Int64 sMulSourceFlag = 0;   //多源单标志(0为非多源单模式,1为多源单模式)
                                if (oSystemParameter.omodel.Kf_OtherInBill_MulSourceBill.ToUpper() == "Y") //系统参数  其他入库单-多源单模式
                                {
                                    sMulSourceFlag = 1;
                                }
                                //将源单信息存入条码出入库临时表
                                DataSet dsyd = oCn.RunProcReturn("exec h_p_WMS_AddSourceBarCode_OtherIn " + HBillID.ToString() + ",'" + HBillNo + "','" + HBillType + "','" + HSourceBillNo + "','" + HSourceBillType + "'," + sMulSourceFlag.ToString() + ",'" + HMaker + "'," + HOWNERID.ToString(), "h_p_WMS_AddSourceBarCode_OtherIn");
                                if (dsyd == null || dsyd.Tables[0].Rows.Count == 0)
                                {
                                    sErrMsg = "单据号:" + HBillNo + ",单据ID:" + HBillID + ";将条码对应源单信息存入条码出入库临时表失败!";
                                    return null;
                                }
                                else
                                {
                                    if (DBUtility.ClsPub.isLong(dsyd.Tables[0].Rows[0][0]) == 0)
                                    {
                                        SourceFlag = true;
                                    }
                                    else
                                    {
                                        sErrMsg = "单据号:" + HBillNo + ",单据ID:" + HBillID + ";" + DBUtility.ClsPub.isStrNull(dsyd.Tables[0].Rows[0]["HRemark"]);
                                        return null;
                                    }
                                }
                            }
                            for (int i = 0; i < dsTBarCode.Tables[0].Rows.Count; i++)
                            {
                                sBarCode_New = DBUtility.ClsPub.isStrNull(dsTBarCode.Tables[0].Rows[i]["HBarCode"]);
@@ -34300,10 +34360,6 @@
                                    oBar.HSupName = sHSupName;
                                    oBar.HDeptID = sHDeptID;
                                    oBar.HDeptName = sHDeptName;
                                    if (HBillType == "1203")
                                    {
                                        SourceFlag = true;
                                    }
                                }
                                else
                                {
@@ -35706,18 +35762,18 @@
            Model.ClsKf_ICStockBill_WMS oBar = new Model.ClsKf_ICStockBill_WMS();
            Int64 sMulSourceFlag = 0;   //多源单标志(0为非多源单模式,1为多源单模式)
            ////获取系统参数
            //Pub_Class.ClsXt_SystemParameter oSystemParameter = new Pub_Class.ClsXt_SystemParameter();
            //if (oSystemParameter.ShowBill(ref sErrMsg) == false)
            //{
            //    sErrMsg = "单据号:" + HBillNo + ",单据ID:" + HInterID + ";扫描源单时获取系统参数失败! " + sErrMsg;
            //    return null;
            //}
            //获取系统参数
            Pub_Class.ClsXt_SystemParameter oSystemParameter = new Pub_Class.ClsXt_SystemParameter();
            if (oSystemParameter.ShowBill(ref sErrMsg) == false)
            {
                sErrMsg = "单据号:" + HBillNo + ",单据ID:" + HInterID + ";扫描源单时获取系统参数失败! " + sErrMsg;
                return null;
            }
            //if (oSystemParameter.omodel.Kf_OtherInBill_MulSourceBill.ToUpper() == "Y") //系统参数  其他入库单-多源单模式
            //{
            //    sMulSourceFlag = 1;
            //}
            if (oSystemParameter.omodel.Kf_OtherInBill_MulSourceBill.ToUpper() == "Y") //系统参数  其他入库单-多源单模式
            {
                sMulSourceFlag = 1;
            }
            //将源单信息存入条码出入库临时表
            DataSet ds1 = oCn.RunProcReturn("exec h_p_WMS_AddSourceBarCode_OtherIn " + HInterID.ToString() + ",'" + HBillNo + "','" + HBillType + "','" + HSourceBillNo + "','" + HSourceBillType + "'," + sMulSourceFlag.ToString() + ",'" + HMaker + "'," + HOWNERID.ToString(), "h_p_WMS_AddSourceBarCode_OtherIn");
@@ -37384,6 +37440,8 @@
        #endregion
        #endregion
DLL/Pub_Class.dll
Binary files differ