yxj
2023-03-24 cf436637560b8d4864b955c06f850b17ee9b3dbb
新增条码生成时同步生成条码出入库记录调用方法
2个文件已修改
57 ■■■■■ 已修改文件
CLOUDWEB/WebService1.asmx.cs 57 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
DLL/Pub_Class.dll 补丁 | 查看 | 原始文档 | blame | 历史
CLOUDWEB/WebService1.asmx.cs
@@ -50124,6 +50124,63 @@
            }
        }
        #region 条码生成时同步生成条码出入库记录
        [WebMethod]
        public bool set_BarCodeAutoWMS(Int64 HInterID, string HSourceBillType, Int64 HStockOrgID, ref string sErrMsg)
        {
            //获取系统参数
            Pub_Class.ClsXt_SystemParameter oSystemParameter = new Pub_Class.ClsXt_SystemParameter();
            if (oSystemParameter.ShowBillByOrgID(HStockOrgID, ref sErrMsg) == false)
            {
                sErrMsg = "获取系统参数失败! " + sErrMsg;
                return false;
            }
            string sAutoWMS = "N";   //条码生成时是否同步生成条码出入库记录('Y'为同步生成)
            if (HSourceBillType == "1201" && oSystemParameter.omodel.BarCode_AutoPOStockInBillWMS == "Y")
            {
                //采购入库单
                sAutoWMS = "Y";
            }
            else if (HSourceBillType == "1202" && oSystemParameter.omodel.BarCode_AutoProductInBillWMS == "Y")
            {
                //生产入库单
                sAutoWMS = "Y";
            }
            else if (HSourceBillType == "1244" && oSystemParameter.omodel.BarCode_AutoMateOutBackBillWMS == "Y")
            {
                //生产退料单
                sAutoWMS = "Y";
            }
            else if (HSourceBillType == "1247" && oSystemParameter.omodel.BarCode_AutoSellOutBackBillWMS == "Y")
            {
                //销售退货单
                sAutoWMS = "Y";
            }
            else
            {
                sAutoWMS = "N";
            }
            if (sAutoWMS == "Y")
            {
                try
                {
                    SQLHelper.ClsCN oCn = new SQLHelper.ClsCN();
                    oCn.RunProc("exec h_p_Kf_ICStockBillSub_WMS_Insert_AutoBarCode  " + HInterID.ToString() + "", ref DBUtility.ClsPub.sExeReturnInfo);
                    return true;
                }
                catch (Exception e)
                {
                    sErrMsg = "生成条码时同步生成条码出入库记录失败,未生成对应条码出入库记录!" + e.Message;
                    return false;
                }
            }
            return true;
        }
        #endregion
        #endregion
DLL/Pub_Class.dll
Binary files differ