ch
2021-07-13 a87ff9576d6b0521f5a4f9a5ef09747908f8c06b
Merge branch 'master' of http://101.37.171.70:10101/r/MESWMS-API
1个文件已修改
49 ■■■■■ 已修改文件
WebAPI/Controllers/CJGL/Cj_StationEntrustInBillController.cs 49 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
WebAPI/Controllers/CJGL/Cj_StationEntrustInBillController.cs
@@ -408,6 +408,55 @@
        }
        /// <summary>
        /// 委外工序发出单流水号回车获取工序信息
        ///参数:string sql。
        ///返回值:object。
        /// </summary>
        [Route("Cj_StationEntrustInBill/txtHProcNo_KeyDown")]
        [HttpGet]
        public object txtHProcNo_KeyDown(string sBillNo, string sProcNo)
        {
            try
            {
                if (sBillNo.Equals("") || sProcNo.Equals(""))
                {
                    objJsonResult.code = "0";
                    objJsonResult.count = 0;
                    objJsonResult.Message = "条形码不能为空!";
                    objJsonResult.data = null;
                    return objJsonResult;
                }
                //得到信息(委外标记为0时,流转标记为1时)
                ds = oCN.RunProcReturn("select top 1 * from h_v_Sc_ProcessExchangeBillList  where 单据号= '" + sBillNo + "' and 下道流转工序<>'转' and 委外标记=1 and 流转标记=1  and 工序号='" + sProcNo + "'", "h_v_Sc_ProcessExchangeBillList");
                //Ds = oCn.RunProcReturn("select top 1 * from h_v_Sc_ProcessExchangeBillList  where 单据号= '" + sBillNo + "' and 工序号='" + sProcNo + "' and 委外标记=0 and 流转标记=1 ", "h_v_Sc_ProcessExchangeBillList");
                //写入信息
                if (ds == null || ds.Tables[0].Rows.Count == 0)
                {
                    objJsonResult.code = "0";
                    objJsonResult.count = 0;
                    objJsonResult.Message = "工序号错误或者当前工序号不允许进站,请重新输入!";
                    objJsonResult.data = null;
                    return objJsonResult;
                }
                objJsonResult.code = "1";
                objJsonResult.count = 1;
                objJsonResult.Message = "Sucess!";
                objJsonResult.data = ds.Tables[0];
                return objJsonResult;
            }
            catch (Exception e)
            {
                objJsonResult.code = "0";
                objJsonResult.count = 0;
                objJsonResult.Message = "Exception!" + e.ToString();
                objJsonResult.data = null;
                return objJsonResult;
            }
        }
        //