1
duhe
2023-09-18 00d2dab9f1367067b27906be93a43949beb43aa7
WebAPI/Controllers/ÌõÂë¹ÜÀí/WEBSController.cs
@@ -115,17 +115,423 @@
            }
        }
        /// <summary>
        /// æ‰«ç è¿”回仓库信息
        /// </summary>
        /// <returns></returns>
        [Route("WEBSController/GetWarehouse_Json")]
        [HttpGet]
        public object GetWarehouse_Json(string HBarCode, Int64 HStockOrgID)
        {
            try
            {
                Int64 HWhID = 0;
                HWhID = DBUtility.ClsPub.isLong(HBarCode.Replace("HWH", ""));
                ds = oCn.RunProcReturn("select HItemID,HNumber,HName,HSPFlag from Gy_Warehouse with(nolock) where HStopflag=0 and HItemID=" + HWhID.ToString() + " and HUSEORGID = " + HStockOrgID.ToString(), "Gy_Warehouse");
                if (ds == null || ds.Tables[0].Rows.Count == 0)
                {
                    objJsonResult.code = "0";
                    objJsonResult.count = 0;
                    objJsonResult.Message = "没有返回任何记录,请确认所扫仓库条码是否属于该组织,且为非禁用状态!";
                    objJsonResult.data = null;
                    return objJsonResult;
                }
                else
                {
                    objJsonResult.code = "0";
                    objJsonResult.count = 1;
                    objJsonResult.Message = "成功!";
                    objJsonResult.data = ds.Tables[0];
                    return objJsonResult;
                }
            }
            catch (Exception e)
            {
                objJsonResult.code = "0";
                objJsonResult.count = 0;
                objJsonResult.Message = "返回仓库信息失败!" + e.ToString();
                objJsonResult.data = null;
                return objJsonResult;
            }
        }
        #endregion
        #region ä»“位资料
        /// <summary>
        /// æ‰«ç è¿”回仓位信息
        /// </summary>
        /// <returns></returns>
        [Route("WEBSController/GetStockPlace_Json")]
        [HttpGet]
        public object GetStockPlace_Json(string HBarCode, Int64 HWhID, Int64 HStockOrgID)
        {
            try
            {
                Int64 sHSPID = 0;
                Int64 sHWhID = 0;
                if (HBarCode.Contains(";"))
                {
                    string[] sArray = HBarCode.Replace("HSP", "").Split(';');
                    sHSPID = DBUtility.ClsPub.isLong(sArray[1]);
                    sHWhID = DBUtility.ClsPub.isLong(sArray[0]);
                }
                if(HWhID==0)
                {
                    ds = oCn.RunProcReturn("select HItemID,HNumber,HName,HWHID,HWhNumber,HWhName from h_v_IF_StockPlace where HStopflag=0 and HItemID=" + sHSPID.ToString() + " and HWHID=" + sHWhID.ToString() + " and HUSEORGID = " + HStockOrgID.ToString(), "h_v_IF_StockPlace");
                    if (ds == null || ds.Tables[0].Rows.Count == 0)
                    {
                        objJsonResult.code = "0";
                        objJsonResult.count = 0;
                        objJsonResult.Message = "没有返回任何记录,请确认所扫仓位条码是否属于该组织,且为非禁用状态!";
                        objJsonResult.data = null;
                        return objJsonResult;
                    }
                    else
                    {
                        objJsonResult.code = "0";
                        objJsonResult.count = 1;
                        objJsonResult.Message = "成功!";
                        objJsonResult.data = ds.Tables[0];
                        return objJsonResult;
                    }
                }
                else
                {
                    ds = oCn.RunProcReturn("select HItemID,HNumber,HName,HWHID,HWhNumber,HWhName from h_v_IF_StockPlace where HStopflag=0 and HItemID=" + sHSPID.ToString() + " and HWHID=" + HWhID.ToString() + " and HUSEORGID = " + HStockOrgID.ToString(), "h_v_IF_StockPlace");
                    if (ds == null || ds.Tables[0].Rows.Count == 0)
                    {
                        DataSet ds2 = oCn.RunProcReturn("select HItemID,HNumber,HName,HWHID,HWhNumber,HWhName from h_v_IF_StockPlace where HStopflag=0 and HItemID=" + sHSPID.ToString() + " and HWHID=" + sHWhID.ToString() + " and HUSEORGID = " + HStockOrgID.ToString(), "h_v_IF_StockPlace");
                        if (ds2 == null || ds2.Tables[0].Rows.Count == 0)
                        {
                            objJsonResult.code = "0";
                            objJsonResult.count = 0;
                            objJsonResult.Message = "没有返回任何记录,请确认所扫仓位条码是否属于该组织,且为非禁用状态!";
                            objJsonResult.data = null;
                            return objJsonResult;
                        }
                        else
                        {
                            objJsonResult.code = "0";
                            objJsonResult.count = 1;
                            objJsonResult.Message = "成功!";
                            objJsonResult.data = ds2.Tables[0];
                            return objJsonResult;
                        }
                    }
                    else
                    {
                        objJsonResult.code = "0";
                        objJsonResult.count = 1;
                        objJsonResult.Message = "成功!";
                        objJsonResult.data = ds.Tables[0];
                        return objJsonResult;
                    }
                }
            }
            catch (Exception e)
            {
                objJsonResult.code = "0";
                objJsonResult.count = 0;
                objJsonResult.Message = "返回仓位信息失败!" + e.ToString();
                objJsonResult.data = null;
                return objJsonResult;
            }
        }
        /// <summary>
        /// èŽ·å–ä»“ä½åˆ—è¡¨ä¿¡æ¯
        /// </summary>
        /// <returns></returns>
        [Route("WEBSController/GetStockPlaceList_Json")]
        [HttpGet]
        public object GetStockPlaceList_Json(string StockPlace, Int64 HWhID, Int64 HStockOrgID)
        {
            try
            {
                //界面上未选择仓库 æˆ– ä»“位选择列表界面输入过滤条件
                if (HWhID == 0)
                {
                    ds = oCn.RunProcReturn("select HItemID,HNumber,HName,HWHID,HWhNumber,HWhName from h_v_IF_StockPlace where HStopflag=0 and HUSEORGID=" + HStockOrgID.ToString() + " and (HNumber like '%" + StockPlace + "%' or HName like '%" + StockPlace + "%')", "h_v_IF_StockPlace");
                    if (ds == null || ds.Tables[0].Rows.Count == 0)
                    {
                        objJsonResult.code = "0";
                        objJsonResult.count = 0;
                        objJsonResult.Message = "没有返回任何仓位记录!";
                        objJsonResult.data = null;
                        return objJsonResult;
                    }
                    else
                    {
                        objJsonResult.code = "0";
                        objJsonResult.count = 1;
                        objJsonResult.Message = "成功!";
                        objJsonResult.data = ds.Tables[0];
                        return objJsonResult;
                    }
                }
                //界面上已选仓库
                else
                {
                    ds = oCn.RunProcReturn("select HItemID,HNumber,HName,HWHID,HWhNumber,HWhName from h_v_IF_StockPlace where HStopflag=0 and HUSEORGID=" + HStockOrgID.ToString() + " and HWHID=" + HWhID.ToString() + " and (HNumber like '%" + StockPlace + "%' or HName like '%" + StockPlace + "%')", "h_v_IF_StockPlace");
                    if (ds == null || ds.Tables[0].Rows.Count == 0)
                    {
                        DataSet ds2 = oCn.RunProcReturn("select HItemID,HNumber,HName,HWHID,HWhNumber,HWhName from h_v_IF_StockPlace where HStopflag=0 and HUSEORGID = " + HStockOrgID.ToString() + " and (HNumber like '%" + StockPlace + "%' or HName like '%" + StockPlace + "%')", "h_v_IF_StockPlace");
                        if (ds2 == null || ds2.Tables[0].Rows.Count == 0)
                        {
                            objJsonResult.code = "0";
                            objJsonResult.count = 0;
                            objJsonResult.Message = "没有返回任何仓位记录!";
                            objJsonResult.data = null;
                            return objJsonResult;
                        }
                        else
                        {
                            objJsonResult.code = "0";
                            objJsonResult.count = 1;
                            objJsonResult.Message = "成功!";
                            objJsonResult.data = ds2.Tables[0];
                            return objJsonResult;
                        }
                    }
                    else
                    {
                        objJsonResult.code = "0";
                        objJsonResult.count = 1;
                        objJsonResult.Message = "成功!";
                        objJsonResult.data = ds.Tables[0];
                        return objJsonResult;
                    }
                }
            }
            catch (Exception e)
            {
                objJsonResult.code = "0";
                objJsonResult.count = 0;
                objJsonResult.Message = "返回仓位信息失败!" + e.ToString();
                objJsonResult.data = null;
                return objJsonResult;
            }
        }
        #endregion
        #region èŒå‘˜èµ„æ–™
        /// <summary>
        /// æ‰«ç è¿”回职员信息
        /// </summary>
        /// <returns></returns>
        [Route("WEBSController/GetEmployee_Json")]
        [HttpGet]
        public object GetEmployee_Json(string HBarCode)
        {
            try
            {
                Int64 HEmpID = 0;
                HEmpID = DBUtility.ClsPub.isLong(HBarCode);
                ds = oCn.RunProcReturn("select HItemID,HNumber,HName from Gy_Employee with(nolock) where HStopflag=0 and HItemID=" + HEmpID.ToString(), "Gy_Employee");
                if (ds == null || ds.Tables[0].Rows.Count == 0)
                {
                    objJsonResult.code = "0";
                    objJsonResult.count = 0;
                    objJsonResult.Message = "没有返回任何记录,请确认所扫职员条码是否正确,且为非禁用状态!";
                    objJsonResult.data = null;
                    return objJsonResult;
                }
                else
                {
                    objJsonResult.code = "0";
                    objJsonResult.count = 1;
                    objJsonResult.Message = "成功!";
                    objJsonResult.data = ds.Tables[0];
                    return objJsonResult;
                }
            }
            catch (Exception e)
            {
                objJsonResult.code = "0";
                objJsonResult.count = 0;
                objJsonResult.Message = "返回职员信息失败!" + e.ToString();
                objJsonResult.data = null;
                return objJsonResult;
            }
        }
        #endregion
        #region éƒ¨é—¨èµ„æ–™
        /// <summary>
        /// æ‰«ç è¿”回部门信息
        /// </summary>
        /// <returns></returns>
        [Route("WEBSController/GetDepartment_Json")]
        [HttpGet]
        public object GetDepartment_Json(string HBarCode)
        {
            try
            {
                Int64 HDepID = 0;
                HDepID = DBUtility.ClsPub.isLong(HBarCode.Replace("HDE", ""));
                ds = oCn.RunProcReturn("select HItemID,HNumber,HName from Gy_Department with(nolock) where HStopflag=0 and HItemID=" + HDepID.ToString(), "Gy_Department");
                if (ds == null || ds.Tables[0].Rows.Count == 0)
                {
                    objJsonResult.code = "0";
                    objJsonResult.count = 0;
                    objJsonResult.Message = "没有返回任何记录,请确认所扫部门条码是否正常,且为非禁用状态!";
                    objJsonResult.data = null;
                    return objJsonResult;
                }
                else
                {
                    objJsonResult.code = "0";
                    objJsonResult.count = 1;
                    objJsonResult.Message = "成功!";
                    objJsonResult.data = ds.Tables[0];
                    return objJsonResult;
                }
            }
            catch (Exception e)
            {
                objJsonResult.code = "0";
                objJsonResult.count = 0;
                objJsonResult.Message = "返回部门信息失败!" + e.ToString();
                objJsonResult.data = null;
                return objJsonResult;
            }
        }
        #endregion
        #region ä¾›åº”商资料
        /// <summary>
        /// æ‰«ç è¿”回供应商信息
        /// </summary>
        /// <returns></returns>
        [Route("WEBSController/GetSupplier_Json")]
        [HttpGet]
        public object GetSupplier_Json(Int64 HSupID)
        {
            try
            {
                ds = oCn.RunProcReturn("select HItemID,HNumber,HName from Gy_Supplier with(nolock) where HStopflag=0 and HItemID=" + HSupID.ToString(), "Gy_Supplier");
                if (ds == null || ds.Tables[0].Rows.Count == 0)
                {
                    objJsonResult.code = "0";
                    objJsonResult.count = 0;
                    objJsonResult.Message = "没有返回任何记录,请确认所扫供应商条码是否正确,且为非禁用状态!";
                    objJsonResult.data = null;
                    return objJsonResult;
                }
                else
                {
                    objJsonResult.code = "0";
                    objJsonResult.count = 1;
                    objJsonResult.Message = "成功!";
                    objJsonResult.data = ds.Tables[0];
                    return objJsonResult;
                }
            }
            catch (Exception e)
            {
                objJsonResult.code = "0";
                objJsonResult.count = 0;
                objJsonResult.Message = "返回供应商信息失败!" + e.ToString();
                objJsonResult.data = null;
                return objJsonResult;
            }
        }
        #endregion
        #region å®¢æˆ·èµ„æ–™
        /// <summary>
        /// æ‰«ç è¿”回客户信息
        /// </summary>
        /// <returns></returns>
        [Route("WEBSController/GetCustomer_Json")]
        [HttpGet]
        public object GetCustomer_Json(Int64 HCusID)
        {
            try
            {
                ds = oCn.RunProcReturn("select HItemID,HNumber,HName from Gy_Customer with(nolock) where HStopflag=0 and HItemID=" + HCusID.ToString(), "Gy_Customer");
                if (ds == null || ds.Tables[0].Rows.Count == 0)
                {
                    objJsonResult.code = "0";
                    objJsonResult.count = 0;
                    objJsonResult.Message = "没有返回任何记录,请确认所扫客户条码是否正确,且为非禁用状态!";
                    objJsonResult.data = null;
                    return objJsonResult;
                }
                else
                {
                    objJsonResult.code = "0";
                    objJsonResult.count = 1;
                    objJsonResult.Message = "成功!";
                    objJsonResult.data = ds.Tables[0];
                    return objJsonResult;
                }
            }
            catch (Exception e)
            {
                objJsonResult.code = "0";
                objJsonResult.count = 0;
                objJsonResult.Message = "返回客户信息失败!" + e.ToString();
                objJsonResult.data = null;
                return objJsonResult;
            }
        }
        /// <summary>
        /// èŽ·å–å®¢æˆ·åˆ—è¡¨ä¿¡æ¯
        /// </summary>
        /// <returns></returns>
        [Route("WEBSController/GetCustomerList_Json")]
        [HttpGet]
        public object GetCustomerList_Json(string Customer, Int64 HStockOrgID)
        {
            try
            {
                ds = oCn.RunProcReturn("select HItemID,HNumber,HName from Gy_Customer with(nolock) where HStopflag=0 and HUSEORGID=" + HStockOrgID.ToString() + " and (HNumber like '%" + Customer + "%' or HName like '%" + Customer + "%')", "Gy_Customer");
                if (ds == null || ds.Tables[0].Rows.Count == 0)
                {
                    objJsonResult.code = "0";
                    objJsonResult.count = 0;
                    objJsonResult.Message = "没有返回任何客户记录!";
                    objJsonResult.data = null;
                    return objJsonResult;
                }
                else
                {
                    objJsonResult.code = "0";
                    objJsonResult.count = 1;
                    objJsonResult.Message = "成功!";
                    objJsonResult.data = ds.Tables[0];
                    return objJsonResult;
                }
            }
            catch (Exception e)
            {
                objJsonResult.code = "0";
                objJsonResult.count = 0;
                objJsonResult.Message = "返回客户信息失败!" + e.ToString();
                objJsonResult.data = null;
                return objJsonResult;
            }
        }
        #endregion
        #endregion
        #region ç•Œé¢æŽ§ä»¶åŠŸèƒ½è°ƒç”¨æ–¹æ³•
        #region æ‰«ç æ¨¡å—调用方法
        #region æ ¹æ®å•据类型获取单据子类型
@@ -140,7 +546,7 @@
            try
            {
                ds = oWebs.get_BillSubType(HBillType, HStockOrgID);
                if (ds == null)
                if (ds == null || ds.Tables[0].Rows.Count == 0)
                {
                    objJsonResult.code = "0";
                    objJsonResult.count = 0;
@@ -169,8 +575,127 @@
        #endregion
        #region æ‰«ç æ¨¡å—    æ ¹æ®æ¡ç åˆ é™¤ç¼“存列表中对应条码记录
        /// <summary>
        /// æ ¹æ®æ¡ç åˆ é™¤æ¡ç å‡ºå…¥åº“缓存表中记录
        /// </summary>
        /// <returns></returns>
        [Route("WEBSController/set_DelPonderationBillMain_Temp_BarCode_Json")]
        [HttpGet]
        public object set_DelPonderationBillMain_Temp_BarCode_Json(long HInterID, string HBillType, string HBarCode)
        {
            try
            {
                oCn.RunProc("Delete from KF_PonderationBillMain_Temp where HBarCode<>'' and HInterID=" + HInterID.ToString() + " and HBillType='" + HBillType + "' and HBarCode='" + HBarCode + "'", ref DBUtility.ClsPub.sExeReturnInfo);
                objJsonResult.code = "0";
                objJsonResult.count = 1;
                objJsonResult.Message = "删除成功";
                objJsonResult.data = null;
                return objJsonResult;
            }
            catch (Exception e)
            {
                objJsonResult.code = "0";
                objJsonResult.count = 0;
                objJsonResult.Message = "删除条码出入库缓存列表条码记录失败!" + e.ToString();
                objJsonResult.data = null;
                return objJsonResult;
            }
        }
        #endregion
        #region æ‰«ç æ¨¡å—    åˆ é™¤åŠŸèƒ½æŒ‰é’®è°ƒç”¨  åˆ é™¤æ¡ç å‡ºå…¥åº“临时表记录
        /// <summary>
        /// æ‰«ç æ¨¡å—,删除选中行条码出入库临时表记录
        /// </summary>
        /// <returns></returns>
        [Route("WEBSController/set_DelPonderationBillMain_Temp_InterIDAndSource_Json")]
        [HttpGet]
        public object set_DelPonderationBillMain_Temp_InterIDAndSource_Json(long HInterID, long HMaterID, long HAuxPropID, string HMTONo, long HSourceInterID, long HSourceEntryID, string HBillType)
        {
            try
            {
                if (oWebs.set_DelPonderationBillMain_Temp_InterIDAndSource(HInterID, HMaterID, HAuxPropID, HMTONo, HSourceInterID, HSourceEntryID, HBillType, ref DBUtility.ClsPub.sErrInfo))
                {
                    objJsonResult.code = "0";
                    objJsonResult.count = 1;
                    objJsonResult.Message = DBUtility.ClsPub.sErrInfo;  //成功!
                    objJsonResult.data = null;
                    return objJsonResult;
                }
                else
                {
                    objJsonResult.code = "0";
                    objJsonResult.count = 0;
                    objJsonResult.Message = DBUtility.ClsPub.sErrInfo;  //失败!
                    objJsonResult.data = null;
                    return objJsonResult;
                }
            }
            catch (Exception e)
            {
                objJsonResult.code = "0";
                objJsonResult.count = 0;
                objJsonResult.Message = "删除所选行条码出入库临时表记录失败!" + e.ToString();
                objJsonResult.data = null;
                return objJsonResult;
            }
        }
        #endregion
        #region æ‰«ææ¨¡å—    é€€å‡ºåŠŸèƒ½æŒ‰é’®è°ƒç”¨    åˆ é™¤å…ˆè¿›å…ˆå‡ºä¸´æ—¶è¡¨ï¼ˆæ›´æ–° HlineStatus =1)
        /// <summary>
        /// åˆ é™¤å…ˆè¿›å…ˆå‡ºä¸´æ—¶è¡¨ï¼ˆæ›´æ–° HlineStatus =1)
        /// </summary>
        /// <returns></returns>
        [Route("WEBSController/set_DelPonderationBillMain_Temp_FIFO_Json")]
        [HttpGet]
        public object set_DelPonderationBillMain_Temp_FIFO_Json(long HInterID, string HBillType)
        {
            try
            {
                if (oWebs.set_DelPonderationBillMain_Temp_FIFO(HInterID, HBillType, ref DBUtility.ClsPub.sErrInfo))
                {
                    objJsonResult.code = "0";
                    objJsonResult.count = 1;
                    objJsonResult.Message = DBUtility.ClsPub.sErrInfo;  //成功!
                    objJsonResult.data = null;
                    return objJsonResult;
                }
                else
                {
                    objJsonResult.code = "0";
                    objJsonResult.count = 0;
                    objJsonResult.Message = DBUtility.ClsPub.sErrInfo;  //失败!
                    objJsonResult.data = null;
                    return objJsonResult;
                }
            }
            catch (Exception e)
            {
                objJsonResult.code = "0";
                objJsonResult.count = 0;
                objJsonResult.Message = "更新先进先出临时表HlineStatus值失败!" + e.ToString();
                objJsonResult.data = null;
                return objJsonResult;
            }
        }
        #endregion
        #endregion
        #region ç¼“存列表模块调用
        #region ç¼“存列表    ç¼–辑功能调用
@@ -227,7 +752,7 @@
            try
            {
                ds = oWebs.GetKf_ICStockBillQueryList(HBillType, HBillNo, HSourceBillNo);
                if (ds == null)
                if (ds == null || ds.Tables[0].Rows.Count == 0)
                {
                    objJsonResult.code = "0";
                    objJsonResult.count = 0;
@@ -337,50 +862,8 @@
            }
        }
        #endregion
        #region åˆ é™¤æ¡ç å‡ºå…¥åº“临时表记录
        /// <summary>
        /// æ‰«ç æ¨¡å—,删除选中行条码出入库临时表记录
        /// </summary>
        /// <returns></returns>
        [Route("WEBSController/set_DelPonderationBillMain_Temp_InterIDAndSource_Json")]
        [HttpGet]
        public object set_DelPonderationBillMain_Temp_InterIDAndSource_Json(long HInterID, long HMaterID, long HAuxPropID, string HMTONo, long HSourceInterID, long HSourceEntryID, string HBillType)
        {
            try
            {
                if (oWebs.set_DelPonderationBillMain_Temp_InterIDAndSource(HInterID, HMaterID, HAuxPropID, HMTONo, HSourceInterID, HSourceEntryID, HBillType, ref DBUtility.ClsPub.sErrInfo))
                {
                    objJsonResult.code = "0";
                    objJsonResult.count = 1;
                    objJsonResult.Message = DBUtility.ClsPub.sErrInfo;  //成功!
                    objJsonResult.data = null;
                    return objJsonResult;
                }
                else
                {
                    objJsonResult.code = "0";
                    objJsonResult.count = 0;
                    objJsonResult.Message = DBUtility.ClsPub.sErrInfo;  //失败!
                    objJsonResult.data = null;
                    return objJsonResult;
                }
            }
            catch (Exception e)
            {
                objJsonResult.code = "0";
                objJsonResult.count = 0;
                objJsonResult.Message = "删除所选行条码出入库临时表记录失败!" + e.ToString();
                objJsonResult.data = null;
                return objJsonResult;
            }
        }
        /// <summary>
        /// æ ¹æ®å•据ID,删除条码出入库临时表记录
        /// æ ¹æ®å•据ID,删除条码出入库临时表记录 ï¼ˆåŠŸèƒ½åŒä¸Šé¢æ ¹æ®ID删除缓存记录方法)
        /// </summary>
        /// <returns></returns>
        [Route("WEBSController/DeleteBillList_Json")]
@@ -418,20 +901,74 @@
        #endregion
        #endregion
        #region åˆ é™¤å…ˆè¿›å…ˆå‡ºä¸´æ—¶è¡¨ï¼ˆæ›´æ–° HlineStatus =1)
        #region æäº¤ç”Ÿå•处理方法
        #region ç”Ÿäº§å…¥åº“    ä¸Šä¼ ç”Ÿå•
        #endregion
        #region é‡‡è´­å…¥åº“    ä¸Šä¼ ç”Ÿå•
        #endregion
        #region å…¶ä»–入库    ä¸Šä¼ ç”Ÿå•
        #region å…¶ä»–入库    æ–°å¢žæ¨¡å¼
        /// <summary>
        /// åˆ é™¤å…ˆè¿›å…ˆå‡ºä¸´æ—¶è¡¨ï¼ˆæ›´æ–° HlineStatus =1)
        /// å…¶ä»–入库新增上传
        /// </summary>
        /// <returns></returns>
        [Route("WEBSController/set_DelPonderationBillMain_Temp_FIFO_Json")]
        [HttpGet]
        public object set_DelPonderationBillMain_Temp_FIFO_Json(long HInterID, string HBillType)
        [Route("WEBSController/set_SaveOtherInBill_Json")]
        [HttpPost]
        public object set_SaveOtherInBill_Json([FromBody] JObject oMain)
        {
            var _value = oMain["oMain"].ToString();
            string msg1 = _value.ToString();
            try
            {
                if (oWebs.set_DelPonderationBillMain_Temp_FIFO(HInterID, HBillType, ref DBUtility.ClsPub.sErrInfo))
                List<Model.ClsKf_OtherInBillMain> lsmain = new List<Model.ClsKf_OtherInBillMain>();
                ListModels oListModels = new ListModels();
                lsmain = oListModels.getOtherInBillMainByJson(msg1);
                WebS.ClsKf_OtherInBillMain websLsmain = new WebS.ClsKf_OtherInBillMain();
                string sSourceType = lsmain[0].HMainSourceBillType;
                websLsmain.HInterID = lsmain[0].HInterID;
                websLsmain.HBillNo = lsmain[0].HBillNo;
                websLsmain.HBillType = lsmain[0].HBillType;
                websLsmain.HDate = lsmain[0].HDate;
                websLsmain.HDeptID = lsmain[0].HDeptID;
                websLsmain.HWHID = lsmain[0].HWHID;
                websLsmain.HSCWHID = lsmain[0].HSCWHID;
                websLsmain.HSupID = lsmain[0].HSupID;
                websLsmain.HKeeperID = lsmain[0].HKeeperID;
                websLsmain.HSecManagerID = lsmain[0].HSecManagerID;
                websLsmain.HEmpID = lsmain[0].HEmpID;
                websLsmain.HManagerID = lsmain[0].HManagerID;
                websLsmain.HRemark = lsmain[0].HRemark;
                websLsmain.HExplanation = lsmain[0].HExplanation;
                websLsmain.HInnerBillNo = lsmain[0].HInnerBillNo;
                websLsmain.HRedBlueFlag = lsmain[0].HRedBlueFlag;
                websLsmain.HStockStyle = lsmain[0].HStockStyle;
                websLsmain.HBillSubType = lsmain[0].HBillSubType;
                if(lsmain[0].HMainSourceBillType== "1241")
                {
                    websLsmain.HMainSourceBillType = "入库申请单";
                }
                else
                {
                    websLsmain.HMainSourceBillType = "手工录入";
                }
                websLsmain.HMaker = lsmain[0].HMaker;
                websLsmain.HBillerID = lsmain[0].HBillerID;
                websLsmain.HSTOCKORGID = lsmain[0].HSTOCKORGID;
                websLsmain.HOWNERID = lsmain[0].HSTOCKORGID;
                if (oWebs.set_SaveOtherInBill_New(websLsmain, sSourceType, ref DBUtility.ClsPub.sErrInfo))
                {
                    objJsonResult.code = "0";
                    objJsonResult.count = 1;
@@ -452,7 +989,7 @@
            {
                objJsonResult.code = "0";
                objJsonResult.count = 0;
                objJsonResult.Message = "更新先进先出临时表HlineStatus值失败!" + e.ToString();
                objJsonResult.Message = "其他出库单上传失败!" + e.ToString();
                objJsonResult.data = null;
                return objJsonResult;
            }
@@ -460,8 +997,7 @@
        #endregion
        #region æäº¤ç”Ÿå•处理方法
        #endregion
        #region é”€å”®å‡ºåº“    ä¸Šä¼ ç”Ÿå•
@@ -881,11 +1417,90 @@
        #endregion
        #region å…¶ä»–入库    æ‰«ææºå•条码
        /// <summary>
        /// å…¶ä»–入库    æ‰«ææºå•条码
        /// </summary>
        /// <returns></returns>
        [Route("WEBSController/Get_SourceBarCode_OtherIn_Json")]
        [HttpGet]
        public object get_SourceBarCode_OtherIn_Json(Int64 HInterID, string HBillNo, string HBillType, string HSourceBillNo, string HSourceBillType, string HMaker, Int64 HStockOrgID)
        {
            try
            {
                WebSoBar = oWebs.get_SourceBarCode_OtherIn(HInterID, HBillNo, HBillType, HSourceBillNo, HSourceBillType, HMaker, HStockOrgID, ref DBUtility.ClsPub.sErrInfo);
                if (WebSoBar == null)
                {
                    objJsonResult.code = "0";
                    objJsonResult.count = 0;
                    objJsonResult.Message = DBUtility.ClsPub.sErrInfo;
                    objJsonResult.data = null;
                    return objJsonResult;
                }
                else
                {
                    objJsonResult.code = "0";
                    objJsonResult.count = 1;
                    objJsonResult.Message = "成功";
                    objJsonResult.data = WebSoBar;
                    return objJsonResult;
                }
            }
            catch (Exception e)
            {
                objJsonResult.code = "0";
                objJsonResult.count = 0;
                objJsonResult.Message = "扫描源单条码失败!" + e.ToString();
                objJsonResult.data = null;
                return objJsonResult;
            }
        }
        #endregion
        #region ç”Ÿäº§é¢†æ–™    æ‰«ææºå•条码
        /// <summary>
        /// é¢†æ–™å‡ºåº“    æ‰«ææºå•条码
        /// </summary>
        /// <returns></returns>
        [Route("WEBSController/Get_SourceBarCode_MateOut_Json")]
        [HttpGet]
        public object get_SourceBarCode_MateOut_Json(Int64 HInterID, string HBillNo, string HBillType, string HSourceBillNo, string HSourceBillType, string HMaker, Double HPTQty, Int64 HPlanMode, Int64 HFIFOWhID, Int64 HStockOrgID)
        {
            try
            {
                WebSoBar = oWebs.get_SourceBarCode_MateOut(HInterID, HBillNo, HBillType, HSourceBillNo, HSourceBillType, HMaker, HPTQty, HPlanMode, HFIFOWhID, HStockOrgID, ref DBUtility.ClsPub.sErrInfo);
                if (WebSoBar == null)
                {
                    objJsonResult.code = "0";
                    objJsonResult.count = 0;
                    objJsonResult.Message = DBUtility.ClsPub.sErrInfo;
                    objJsonResult.data = null;
                    return objJsonResult;
                }
                else
                {
                    objJsonResult.code = "0";
                    objJsonResult.count = 1;
                    objJsonResult.Message = "成功";
                    objJsonResult.data = WebSoBar;
                    return objJsonResult;
                }
            }
            catch (Exception e)
            {
                objJsonResult.code = "0";
                objJsonResult.count = 0;
                objJsonResult.Message = "扫描源单条码失败!" + e.ToString();
                objJsonResult.data = null;
                return objJsonResult;
            }
        }
        #endregion
@@ -933,6 +1548,43 @@
        #region å§”外出库    æ‰«ææºå•条码
        /// <summary>
        /// å§”外出库    æ‰«ææºå•条码
        /// </summary>
        /// <returns></returns>
        [Route("WEBSController/Get_SourceBarCode_EntrustOut_Json")]
        [HttpGet]
        public object get_SourceBarCode_EntrustOut_Json(Int64 HInterID, string HBillNo, string HBillType, string HSourceBillNo, string HSourceBillType, string HMaker, Int64 HFIFOWhID, Int64 HStockOrgID)
        {
            try
            {
                WebSoBar = oWebs.get_SourceBarCode_EntrustOut(HInterID, HBillNo, HBillType, HSourceBillNo, HSourceBillType, HMaker, HFIFOWhID, HStockOrgID, ref DBUtility.ClsPub.sErrInfo);
                if (WebSoBar == null)
                {
                    objJsonResult.code = "0";
                    objJsonResult.count = 0;
                    objJsonResult.Message = DBUtility.ClsPub.sErrInfo;
                    objJsonResult.data = null;
                    return objJsonResult;
                }
                else
                {
                    objJsonResult.code = "0";
                    objJsonResult.count = 1;
                    objJsonResult.Message = "成功";
                    objJsonResult.data = WebSoBar;
                    return objJsonResult;
                }
            }
            catch (Exception e)
            {
                objJsonResult.code = "0";
                objJsonResult.count = 0;
                objJsonResult.Message = "扫描源单条码失败!" + e.ToString();
                objJsonResult.data = null;
                return objJsonResult;
            }
        }
        #endregion
@@ -1022,18 +1674,92 @@
        #region åˆ†æ­¥å¼è°ƒå‡º    æ‰«ææºå•条码
        /// <summary>
        /// åˆ†æ­¥å¼è°ƒå‡º    æ‰«ææºå•条码
        /// </summary>
        /// <returns></returns>
        [Route("WEBSController/Get_SourceBarCode_MoveStockStepOut_Json")]
        [HttpGet]
        public object get_SourceBarCode_MoveStockStepOut_Json(Int64 HInterID, string HBillNo, string HBillType, string HSourceBillNo, string HSourceBillType, string HMaker, Int64 HFIFOWhID, Int64 HStockInOrgID, Int64 HStockOutOrgID)
        {
            try
            {
                WebSoBar = oWebs.get_SourceBarCode_MoveStockStepOut(HInterID, HBillNo, HBillType, HSourceBillNo, HSourceBillType, HMaker, HFIFOWhID, HStockInOrgID, HStockOutOrgID, ref DBUtility.ClsPub.sErrInfo);
                if (WebSoBar == null)
                {
                    objJsonResult.code = "0";
                    objJsonResult.count = 0;
                    objJsonResult.Message = DBUtility.ClsPub.sErrInfo;
                    objJsonResult.data = null;
                    return objJsonResult;
                }
                else
                {
                    objJsonResult.code = "0";
                    objJsonResult.count = 1;
                    objJsonResult.Message = "成功";
                    objJsonResult.data = WebSoBar;
                    return objJsonResult;
                }
            }
            catch (Exception e)
            {
                objJsonResult.code = "0";
                objJsonResult.count = 0;
                objJsonResult.Message = "扫描源单条码失败!" + e.ToString();
                objJsonResult.data = null;
                return objJsonResult;
            }
        }
        #endregion
        #region åˆ†æ­¥å¼è°ƒå…¥    æ‰«ææºå•条码
        /// <summary>
        /// åˆ†æ­¥å¼è°ƒå…¥    æ‰«ææºå•条码
        /// </summary>
        /// <returns></returns>
        [Route("WEBSController/Get_SourceBarCode_MoveStockStepIn_Json")]
        [HttpGet]
        public object get_SourceBarCode_MoveStockStepIn_Json(Int64 HInterID, string HBillNo, string HBillType, string HSourceBillNo, string HSourceBillType, string HMaker, Int64 HStockInOrgID, Int64 HStockOutOrgID)
        {
            try
            {
                WebSoBar = oWebs.get_SourceBarCode_MoveStockStepIn(HInterID, HBillNo, HBillType, HSourceBillNo, HSourceBillType, HMaker, HStockInOrgID, HStockOutOrgID, ref DBUtility.ClsPub.sErrInfo);
                if (WebSoBar == null)
                {
                    objJsonResult.code = "0";
                    objJsonResult.count = 0;
                    objJsonResult.Message = DBUtility.ClsPub.sErrInfo;
                    objJsonResult.data = null;
                    return objJsonResult;
                }
                else
                {
                    objJsonResult.code = "0";
                    objJsonResult.count = 1;
                    objJsonResult.Message = "成功";
                    objJsonResult.data = WebSoBar;
                    return objJsonResult;
                }
            }
            catch (Exception e)
            {
                objJsonResult.code = "0";
                objJsonResult.count = 0;
                objJsonResult.Message = "扫描源单条码失败!" + e.ToString();
                objJsonResult.data = null;
                return objJsonResult;
            }
        }
        #endregion
        #endregion
        #region ç‰©æ–™æ¡ç å¤„理方法    å…¶ä»–出库库模块
        #region ç‰©æ–™æ¡ç å¤„理方法    å‡ºå…¥åº“模块
        /// <summary>
        /// ç‰©æ–™æ¡ç æ–‡æœ¬æ¡† æ‰«ç è°ƒç”¨
@@ -1262,26 +1988,26 @@
        #endregion
        #region å•据新增模块  èŽ·å–å•æ®åˆ—è¡¨ä¿¡æ¯å¤„ç†æ–¹æ³•
        #region æ‰«ç æ¨¡å—调用方法
        #region ä»Žç¼“存列表页面返回信息
        /// <summary>
        /// èŽ·å–å•æ®åˆ—è¡¨ä¿¡æ¯
        /// ä»Žç¼“存列表页面返回信息
        /// </summary>
        /// <returns></returns>
        [Route("WEBSController/GetBillEntryTmpList_Json")]
        [Route("WEBSController/GetSourceBill_Temp_Json")]
        [HttpGet]
        public object GetBillEntryTmpList(long HInterID, string HBillNo, string HBillType, Int64 HStockOrgID)
        public object GetSourceBill_Temp_Json(Int64 HInterID, string HBillType)
        {
            try
            {
                string sMouldManagerCtl = "N";  //是否启用器具管理
                string sFIFOCtl = "N";          //是否启用先进先出管理
                ds = oWebs.GetBillEntryTmpList(HInterID, HBillNo, HBillType, HStockOrgID, ref sMouldManagerCtl, ref sFIFOCtl, ref DBUtility.ClsPub.sErrInfo);
                if (ds == null)
                ds = oCn.RunProcReturn("exec h_p_WMS_SourceBill_Temp " + HInterID.ToString() + ",'" + HBillType + "'", "h_p_WMS_SourceBill_Temp");
                if (ds == null || ds.Tables[0].Rows.Count == 0)
                {
                    objJsonResult.code = "0";
                    objJsonResult.count = 0;
                    objJsonResult.Message = "没有返回任何记录!";
                    objJsonResult.Message = "从缓存列表返回时,没有返回任何记录!";
                    objJsonResult.data = null;
                    return objJsonResult;
                }
@@ -1297,6 +2023,92 @@
                    }
                    objJsonResult.code = "0";
                    objJsonResult.count = 1;
                    objJsonResult.Message = "成功!";
                    objJsonResult.data = ds.Tables[0];
                    objJsonResult.list = columnNameList;
                    return objJsonResult;
                }
            }
            catch (Exception e)
            {
                objJsonResult.code = "0";
                objJsonResult.count = 0;
                objJsonResult.Message = "返回缓存列表单据信息失败!" + e.ToString();
                objJsonResult.data = null;
                return objJsonResult;
            }
        }
        #endregion
        #region å•据新增模块  èŽ·å–å•æ®åˆ—è¡¨ä¿¡æ¯å¤„ç†æ–¹æ³•
        /// <summary>
        /// èŽ·å–å•æ®åˆ—è¡¨ä¿¡æ¯
        /// </summary>
        /// <returns></returns>
        [Route("WEBSController/GetBillEntryTmpList_Json")]
        [HttpGet]
        public object GetBillEntryTmpList(long HInterID, string HBillNo, string HBillType, Int64 HStockOrgID)
        {
            try
            {
                string sMouldManagerCtl = "N";  //是否启用器具管理
                string sFIFOCtl = "N";          //是否启用先进先出管理
                ds = oWebs.GetBillEntryTmpList(HInterID, HBillNo, HBillType, HStockOrgID, ref sMouldManagerCtl, ref sFIFOCtl, ref DBUtility.ClsPub.sErrInfo);
                if (ds == null || ds.Tables[0].Rows.Count == 0)
                {
                    objJsonResult.code = "0";
                    objJsonResult.count = 0;
                    objJsonResult.Message = "没有返回任何记录!";
                    objJsonResult.data = null;
                    return objJsonResult;
                }
                else
                {
                    //添加物料明细列表列名
                    List<object> columnNameList = new List<object>();
                    foreach (DataColumn col in ds.Tables[0].Columns)
                    {
                        Type dataType = col.DataType;
                        string ColmString = "{\"ColmCols\":\"" + col.ColumnName + "\",\"ColmType\":\"" + dataType.Name + "\"}";
                        columnNameList.Add(JsonConvert.DeserializeObject(ColmString));  //获取到DataColumn列对象的列名
                    }
                    //添加模治具列表列名
                    List<object> MouldcolumnNameList = new List<object>();
                    foreach (DataColumn col in ds.Tables[1].Columns)
                    {
                        Type dataType = col.DataType;
                        string ColmString = "{\"ColmCols\":\"" + col.ColumnName + "\",\"ColmType\":\"" + dataType.Name + "\"}";
                        MouldcolumnNameList.Add(JsonConvert.DeserializeObject(ColmString));  //获取到DataColumn列对象的列名
                    }
                    //添加先进先出列表列名
                    List<object> FIFOcolumnNameList = new List<object>();
                    foreach (DataColumn col in ds.Tables[2].Columns)
                    {
                        Type dataType = col.DataType;
                        string ColmString = "{\"ColmCols\":\"" + col.ColumnName + "\",\"ColmType\":\"" + dataType.Name + "\"}";
                        FIFOcolumnNameList.Add(JsonConvert.DeserializeObject(ColmString));  //获取到DataColumn列对象的列名
                    }
                    //添加条码明细列表列名
                    List<object> BarCodecolumnNameList = new List<object>();
                    foreach (DataColumn col in ds.Tables[3].Columns)
                    {
                        Type dataType = col.DataType;
                        string ColmString = "{\"ColmCols\":\"" + col.ColumnName + "\",\"ColmType\":\"" + dataType.Name + "\"}";
                        BarCodecolumnNameList.Add(JsonConvert.DeserializeObject(ColmString));  //获取到DataColumn列对象的列名
                    }
                    //添加源单生产汇报单条码明细列表列名
                    List<object> ICMOReportcolumnNameList = new List<object>();
                    foreach (DataColumn col in ds.Tables[4].Columns)
                    {
                        Type dataType = col.DataType;
                        string ColmString = "{\"ColmCols\":\"" + col.ColumnName + "\",\"ColmType\":\"" + dataType.Name + "\"}";
                        ICMOReportcolumnNameList.Add(JsonConvert.DeserializeObject(ColmString));  //获取到DataColumn列对象的列名
                    }
                    objJsonResult.code = "0";
                    objJsonResult.count = 1;
                    objJsonResult.Message = "获取信息成功!";
                    objJsonResult.data = ds.Tables[0];
                    objJsonResult.data = new
@@ -1309,6 +2121,10 @@
                        BarCodeDetailslist = ds.Tables[5]   //返回当前所扫描条码明细信息(5)
                    };
                    objJsonResult.list = columnNameList;
                    objJsonResult.list = MouldcolumnNameList;
                    objJsonResult.list = FIFOcolumnNameList;
                    objJsonResult.list = BarCodecolumnNameList;
                    objJsonResult.list = ICMOReportcolumnNameList;
                    return objJsonResult;
                }
            }
@@ -1321,6 +2137,8 @@
                return objJsonResult;
            }
        }
        #endregion
        #endregion
@@ -1520,7 +2338,7 @@
            try
            {
                ds = oWebs.GetKf_PonderationBillMain_Temp_BillCheck(HInterID, HBillType, sWhere);
                if (ds == null)
                if (ds == null || ds.Tables[0].Rows.Count == 0)
                {
                    objJsonResult.code = "0";
                    objJsonResult.count = 0;
@@ -1635,7 +2453,7 @@
            try
            {
                ds = oWebs.GetKf_PonderationBillMain_TempList_BillCheck(HBillType, HMaker, HStockOrgID);
                if (ds == null)
                if (ds == null || ds.Tables[0].Rows.Count == 0)
                {
                    objJsonResult.code = "0";
                    objJsonResult.count = 0;
@@ -1925,7 +2743,7 @@
            try
            {
                ds = oWebs.GetBillEntry_Tmp_Pack(HInterID, HBillNo, HBillType, ref DBUtility.ClsPub.sErrInfo);
                if (ds == null)
                if (ds == null || ds.Tables[0].Rows.Count == 0)
                {
                    objJsonResult.code = "0";
                    objJsonResult.count = 0;
@@ -2020,7 +2838,7 @@
            try
            {
                ds = oWebs.GetSc_PackUnionBill_TempList(HBillType, HMaker, HStockOrgID);
                if (ds == null)
                if (ds == null || ds.Tables[0].Rows.Count == 0)
                {
                    objJsonResult.code = "0";
                    objJsonResult.count = 0;
@@ -2119,7 +2937,7 @@
            try
            {
                ds = oCn.RunProcReturn("exec h_p_WMS_AddPackBarCode_DeletePackUnionBill '" + HBarCode_Pack + "','" + HMaker + "'," + HStockOrgID.ToString(), "h_p_WMS_AddPackBarCode_DeletePackUnionBill");
                if (ds == null)
                if (ds == null || ds.Tables[0].Rows.Count == 0)
                {
                    objJsonResult.code = "0";
                    objJsonResult.count = 0;
@@ -2300,7 +3118,7 @@
            try
            {
                ds = oWebs.GetBillEntry_Temp_MoveStockBill_HuanTuo(HInterID, HBillNo, HBillType, HStockOrgID, ref DBUtility.ClsPub.sErrInfo);
                if (ds == null)
                if (ds == null || ds.Tables[0].Rows.Count == 0)
                {
                    objJsonResult.code = "0";
                    objJsonResult.count = 0;
@@ -2392,7 +3210,7 @@
            try
            {
                ds = oCn.RunProcReturn("exec h_p_KF_MoveStockBill_TempList_HuanTuo " + HInterID.ToString() + ",'" + HBillType + "'", "h_p_KF_MoveStockBill_TempList_HuanTuo");
                if (ds == null)
                if (ds == null || ds.Tables[0].Rows.Count == 0)
                {
                    objJsonResult.code = "0";
                    objJsonResult.count = 0;
@@ -2443,7 +3261,7 @@
            try
            {
                ds = oCn.RunProcReturn("exec h_p_KF_PonderationBillMain_TempList_HuanTuo '" + HBillType + "','" + HMaker + "'," + HStockOrgID.ToString(), "h_p_KF_PonderationBillMain_TempList_HuanTuo");
                if (ds == null)
                if (ds == null || ds.Tables[0].Rows.Count == 0)
                {
                    objJsonResult.code = "0";
                    objJsonResult.count = 0;
@@ -2490,5 +3308,256 @@
        #endregion
        #region æŠ¥è¡¨æ•°æ®èŽ·å–æ–¹æ³•
        #region æ¡ç å‡ºå…¥åº“记录报表
        #region èŽ·å–å•æ®ç±»åž‹ä¿¡æ¯
        /// <summary>
        /// èŽ·å–å•æ®ç±»åž‹ä¿¡æ¯
        /// </summary>
        /// <returns></returns>
        [Route("WEBSController/GetBarCodeReport_BillType_Json")]
        [HttpGet]
        public object GetBarCodeReport_BillType_Json()
        {
            try
            {
                ds = oCn.RunProcReturn("exec h_p_WMS_BarCodeReport_BillType ", "h_p_WMS_BarCodeReport_BillType");
                objJsonResult.code = "0";
                objJsonResult.count = 1;
                objJsonResult.Message = "成功!";
                objJsonResult.data = ds.Tables[0];
                return objJsonResult;
            }
            catch (Exception e)
            {
                objJsonResult.code = "0";
                objJsonResult.count = 0;
                objJsonResult.Message = "获取单据类型信息失败!" + e.ToString();
                objJsonResult.data = null;
                return objJsonResult;
            }
        }
        #endregion
        #region èŽ·å–æ¡ç å‡ºå…¥åº“è®°å½•
        /// <summary>
        /// èŽ·å–æ¡ç å‡ºå…¥åº“è®°å½•
        /// </summary>
        /// <returns></returns>
        [Route("WEBSController/GetKf_BarCodeOutInReport_Json")]
        [HttpGet]
        public object GetKf_BarCodeOutInReport_Json(string sWhere)
        {
            try
            {
                ds = oCn.RunProcReturn("exec h_p_Kf_BarCodeOutInReport_New " + sWhere, "h_p_Kf_BarCodeOutInReport_New");
                if (ds == null || ds.Tables[0].Rows.Count == 0)
                {
                    objJsonResult.code = "0";
                    objJsonResult.count = 0;
                    objJsonResult.Message = "当前所输入过滤条件,没有返回任何结果!";
                    objJsonResult.data = null;
                    return objJsonResult;
                }
                else
                {
                    List<object> columnNameList = new List<object>();
                    //添加列名
                    foreach (DataColumn col in ds.Tables[0].Columns)
                    {
                        Type dataType = col.DataType;
                        string ColmString = "{\"ColmCols\":\"" + col.ColumnName + "\",\"ColmType\":\"" + dataType.Name + "\"}";
                        columnNameList.Add(JsonConvert.DeserializeObject(ColmString));  //获取到DataColumn列对象的列名
                    }
                    objJsonResult.code = "0";
                    objJsonResult.count = 1;
                    objJsonResult.Message = "成功!";
                    objJsonResult.data = ds.Tables[0];
                    objJsonResult.list = columnNameList;
                    return objJsonResult;
                }
            }
            catch (Exception e)
            {
                objJsonResult.code = "0";
                objJsonResult.count = 0;
                objJsonResult.Message = "查询条码出入库记录信息失败!" + e.ToString();
                objJsonResult.data = null;
                return objJsonResult;
            }
        }
        #endregion
        #endregion
        #region æ¡ç åº“存查询报表
        #region èŽ·å–æ¡ç åº“å­˜ä¿¡æ¯
        /// <summary>
        /// èŽ·å–æ¡ç åº“å­˜ä¿¡æ¯
        /// </summary>
        /// <returns></returns>
        [Route("WEBSController/GetKf_BarCodeICInventoryReport_Json")]
        [HttpGet]
        public object GetKf_BarCodeICInventoryReport_Json(string sWhere)
        {
            try
            {
                ds = oCn.RunProcReturn("exec h_p_WMS_BarCodeICInventoryReport " + sWhere, "h_p_WMS_BarCodeICInventoryReport");
                if (ds == null || ds.Tables[0].Rows.Count == 0)
                {
                    objJsonResult.code = "0";
                    objJsonResult.count = 0;
                    objJsonResult.Message = "当前所输入过滤条件,没有返回任何结果!";
                    objJsonResult.data = null;
                    return objJsonResult;
                }
                else
                {
                    List<object> columnNameList = new List<object>();
                    //添加列名
                    foreach (DataColumn col in ds.Tables[0].Columns)
                    {
                        Type dataType = col.DataType;
                        string ColmString = "{\"ColmCols\":\"" + col.ColumnName + "\",\"ColmType\":\"" + dataType.Name + "\"}";
                        columnNameList.Add(JsonConvert.DeserializeObject(ColmString));  //获取到DataColumn列对象的列名
                    }
                    objJsonResult.code = "0";
                    objJsonResult.count = 1;
                    objJsonResult.Message = "成功!";
                    objJsonResult.data = ds.Tables[0];
                    objJsonResult.list = columnNameList;
                    return objJsonResult;
                }
            }
            catch (Exception e)
            {
                objJsonResult.code = "0";
                objJsonResult.count = 0;
                objJsonResult.Message = "查询条码库存信息失败!" + e.ToString();
                objJsonResult.data = null;
                return objJsonResult;
            }
        }
        #endregion
        #endregion
        #region WMS物料出入库记录报表
        #region èŽ·å–WMS物料出入库记录
        /// <summary>
        /// èŽ·å–WMS物料出入库记录
        /// </summary>
        /// <returns></returns>
        [Route("WEBSController/GetKf_MaterOutInReport_Json")]
        [HttpGet]
        public object GetKf_MaterOutInReport_Json(string sWhere)
        {
            try
            {
                ds = oCn.RunProcReturn("exec h_p_WMS_MaterOutInReport " + sWhere, "h_p_WMS_MaterOutInReport");
                if (ds == null || ds.Tables[0].Rows.Count == 0)
                {
                    objJsonResult.code = "0";
                    objJsonResult.count = 0;
                    objJsonResult.Message = "当前所输入过滤条件,没有返回任何结果!";
                    objJsonResult.data = null;
                    return objJsonResult;
                }
                else
                {
                    List<object> columnNameList = new List<object>();
                    //添加列名
                    foreach (DataColumn col in ds.Tables[0].Columns)
                    {
                        Type dataType = col.DataType;
                        string ColmString = "{\"ColmCols\":\"" + col.ColumnName + "\",\"ColmType\":\"" + dataType.Name + "\"}";
                        columnNameList.Add(JsonConvert.DeserializeObject(ColmString));  //获取到DataColumn列对象的列名
                    }
                    objJsonResult.code = "0";
                    objJsonResult.count = 1;
                    objJsonResult.Message = "成功!";
                    objJsonResult.data = ds.Tables[0];
                    objJsonResult.list = columnNameList;
                    return objJsonResult;
                }
            }
            catch (Exception e)
            {
                objJsonResult.code = "0";
                objJsonResult.count = 0;
                objJsonResult.Message = "查询WMS物料出入库记录信息失败!" + e.ToString();
                objJsonResult.data = null;
                return objJsonResult;
            }
        }
        #endregion
        #endregion
        #region WMS物料库存查询报表
        #region èŽ·å–WMS物料库存信息
        /// <summary>
        /// èŽ·å–WMS物料库存信息
        /// </summary>
        /// <returns></returns>
        [Route("WEBSController/GetKf_MaterICInventoryReport_Json")]
        [HttpGet]
        public object GetKf_MaterICInventoryReport_Json(string sWhere)
        {
            try
            {
                ds = oCn.RunProcReturn("exec h_p_WMS_MaterICInventoryReport " + sWhere, "h_p_WMS_MaterICInventoryReport");
                if (ds == null || ds.Tables[0].Rows.Count == 0)
                {
                    objJsonResult.code = "0";
                    objJsonResult.count = 0;
                    objJsonResult.Message = "当前所输入过滤条件,没有返回任何结果!";
                    objJsonResult.data = null;
                    return objJsonResult;
                }
                else
                {
                    List<object> columnNameList = new List<object>();
                    //添加列名
                    foreach (DataColumn col in ds.Tables[0].Columns)
                    {
                        Type dataType = col.DataType;
                        string ColmString = "{\"ColmCols\":\"" + col.ColumnName + "\",\"ColmType\":\"" + dataType.Name + "\"}";
                        columnNameList.Add(JsonConvert.DeserializeObject(ColmString));  //获取到DataColumn列对象的列名
                    }
                    objJsonResult.code = "0";
                    objJsonResult.count = 1;
                    objJsonResult.Message = "成功!";
                    objJsonResult.data = ds.Tables[0];
                    objJsonResult.list = columnNameList;
                    return objJsonResult;
                }
            }
            catch (Exception e)
            {
                objJsonResult.code = "0";
                objJsonResult.count = 0;
                objJsonResult.Message = "查询WMS物料库存信息失败!" + e.ToString();
                objJsonResult.data = null;
                return objJsonResult;
            }
        }
        #endregion
        #endregion
        #endregion
    }
}