/// <summary> /// 效验数量并提交 /// </summary> /// <param name="model"></param> /// <returns></returns> /// public ActionResult ValidateQty(MatchpLatePCModel model) { GetLoginInfo(); if (Login_Info == null) { return Content("<script>location.href='/Home'</script>"); } service = new MatchpLatePCService(Login_Info.User_ID, Login_Info.User_Name, Login_Info.Token); try { service.SetParameter("OldTrayNO", model.OldTrayNO); service.SetParameter("TrayNO", model.TrayNO); service.SetParameter("Barcode", model.Barcode); service.SetParameter("StockBatchNO", model.StockBatchNO); service.SetParameter("IsCheckTrayNO", model.IsCheckTrayNO); //service.ExecuteBusinessCheck("RF_PastesPartofV2", "*"); service.ExecuteBusinessProcess("RF_PastesPartofV2"); DataSet ds = service.GettMatchPlateDtl(); if (ds.Tables[1].Rows.Count == 0) { return Content("error\n" + "操作成功,显示数据失败"); } string strjson = ToJson(ds); //string strjson = "{ \"Master\":[{\"Item\":\"1\",\"GoodsInfo\":\"史云生利乐装高级鸡汤【库存单位:盒】\",\"StockBatchNO\":\"2017061320180615\",\"Qty\":\"34.000\"}],\"Detail\":[{\"Item\":\"1\",\"GoodsInfo\":\"史云生利乐装高级鸡汤【库存单位:盒】\",\"StockBatchNO\":\"2017061320180615\",\"Qty\":\"34.000\"}]}"; return Content(strjson); } catch (Exception ex) { Loger.Error(ex); return Content("error\n" + ex.Message); } }
/// <summary> /// 效验条码 /// </summary> /// <param name="model"></param> /// <returns></returns> /// public ActionResult ValidateBarcode(MatchpLatePCModel model) { GetLoginInfo(); if (Login_Info == null) { return Content("<script>location.href='/Home'</script>"); } service = new MatchpLatePCService(Login_Info.User_ID, Login_Info.User_Name, Login_Info.Token); try { service.SetParameter("OldTrayNO", model.OldTrayNO); service.SetParameter("TrayNO", model.TrayNO); service.SetParameter("Barcode", model.Barcode); service.ExecuteBusinessCheck("RF_PastesPartofV2", "Barcode"); DataTable dt = service.GetMatchPlateGoods(); if (dt != null && dt.Rows.Count > 0) { return Content(JsonHelper.ToJson(dt)); } else { return Content("数据异常,请检查!"); } } catch (Exception ex) { Loger.Error(ex); return Content(ex.Message); } }
/// <summary> /// 效验目标出库箱 /// </summary> /// <param name="model"></param> /// <returns></returns> /// public ActionResult ValidateTrayNO(MatchpLatePCModel model) { GetLoginInfo(); if (Login_Info == null) { return Content("<script>location.href='/Home'</script>"); } service = new MatchpLatePCService(Login_Info.User_ID, Login_Info.User_Name, Login_Info.Token); try { service.SetParameter("OldTrayNO", model.OldTrayNO); service.SetParameter("TrayNO", model.TrayNO); service.SetParameter("IsCheckTrayNO", model.IsCheckTrayNO); service.ExecuteBusinessCheck("RF_PastesPartofV2", "TrayNO"); return Content(""); } catch (Exception ex) { Loger.Error(ex); return Content(ex.Message); } }