| | |
| | | } |
| | | } |
| | | |
| | | //判断条码之前的工序是否出站 |
| | | [Route("LEMS/SNBarcodeProcCtrl")] |
| | | [HttpGet] |
| | | public object SNBarcodeProcCtrl(string SubBarcode,string HProcExchBillNo) |
| | | { |
| | | DataSet ds; |
| | | try |
| | | { |
| | | SQLHelper.ClsCN oCN = new SQLHelper.ClsCN(); |
| | | ds = oCN.RunProcReturn(" select * from Gy_BarCodeBill where HSourceBillNo='" + HProcExchBillNo + "' and HBarCode='" + SubBarcode + "'", "Gy_BarCodeBill"); |
| | | if (ds.Tables[0].Rows.Count == 0) |
| | | { |
| | | objJsonResult.code = "0"; |
| | | objJsonResult.count = 0; |
| | | objJsonResult.Message = "查无数据,条码:" + SubBarcode + "不属于当前流转卡:" + HProcExchBillNo + "!"; |
| | | objJsonResult.data = null; |
| | | return objJsonResult; |
| | | } |
| | | |
| | | ds = oCN.RunProcReturn(@"exec h_p_Sc_SNBarcodeProcCtrl '" + SubBarcode + "'", "h_p_Sc_SNBarcodeProcCtrl"); |
| | | if (ClsPub.isInt(ds.Tables[0].Rows.Count) == 0) |
| | | { |
| | | objJsonResult.code = "0"; |
| | | objJsonResult.count = 0; |
| | | objJsonResult.Message = "查无数据!"; |
| | | objJsonResult.data = null; |
| | | return objJsonResult; |
| | | } |
| | | else if (ds.Tables[0].Rows[0]["HBack"].ToString() == "2") |
| | | { |
| | | objJsonResult.code = "0"; |
| | | objJsonResult.count = 0; |
| | | objJsonResult.Message = ds.Tables[0].Rows[0]["HBackRemark"].ToString() + "!"; |
| | | objJsonResult.data = null; |
| | | return objJsonResult; |
| | | } |
| | | else |
| | | { |
| | | objJsonResult.code = "1"; |
| | | objJsonResult.count = 1; |
| | | objJsonResult.Message = null; |
| | | objJsonResult.data = null; |
| | | return objJsonResult; |
| | | } |
| | | } |
| | | catch (Exception e) |
| | | { |
| | | objJsonResult.code = "0"; |
| | | objJsonResult.count = 0; |
| | | objJsonResult.Message = "异常!"; |
| | | objJsonResult.data = e.ToString(); |
| | | return objJsonResult; |
| | | } |
| | | } |
| | | |
| | | |
| | | //判断总的包装数量是否超过流转卡数量 |
| | | [Route("LEMS/h_p_Sc_ProductionLinePackaging_Checkqty")] |
| | | [HttpGet] |