已修改16个文件
已重命名2个文件
已添加2个文件
| | |
| | | } |
| | | #endregion Functions |
| | | |
| | | /// <summary> |
| | | /// éç½®æ¬æ¬¡æ«ç ä¿¡æ¯ |
| | | /// </summary> |
| | | public virtual void ResetScan() |
| | | { |
| | | //æ¸
çæåæ°æ®æäº¤æä½ |
| | | DBCommitList.Clear(); |
| | | } |
| | | |
| | | public override bool Close(bool needSaveHistoryLog = false) |
| | | { |
| | | //needSaveHistoryLog = true; |
¶Ô±ÈÐÂÎļþ |
| | |
| | | using Tiger.Model; |
| | | using SqlSugar; |
| | | using System; |
| | | using System.Collections.Generic; |
| | | using System.Linq.Expressions; |
| | | using System.Text; |
| | | using System.Threading.Tasks; |
| | | using Rhea.Common; |
| | | using System.Net; |
| | | using System.Linq; |
| | | using Newtonsoft.Json; |
| | | using Tiger.IBusiness; |
| | | using Microsoft.AspNetCore.Http; |
| | | using Tiger.Model.Minsun; |
| | | using Org.BouncyCastle.Asn1.Tsp; |
| | | using Tiger.Model.Entitys.MES.Position; |
| | | using Apache.NMS.ActiveMQ.Commands; |
| | | using System.Security.Cryptography; |
| | | using System.Diagnostics; |
| | | using Tiger.Model.Entitys.MES.U9C; |
| | | using Newtonsoft.Json.Linq; |
| | | using System.Security.Policy; |
| | | using NetTaste; |
| | | |
| | | namespace Tiger.Business.WMS |
| | | { |
| | | public partial class WMS_U9C |
| | | { |
| | | /// <summary> |
| | | /// 颿åéæåå®¡æ ¸æ¥å£ |
| | | /// </summary> |
| | | public static string ApproveReqReturnUrl |
| | | { get; set; } = "http://172.16.80.20/u9c/webapi/IssueDoc/Approve"; // ApiConfig.IsTestServer ? Cache.SysParam["ApproveReqReturnUrl_Test", "U9CUrl"].PARAM_VALUE : Cache.SysParam["ApproveReqReturnUrl", "U9CUrl"].PARAM_VALUE; //http://172.16.80.20/u9c/webapi/IssueDoc/Approve |
| | | |
| | | /// <summary> |
| | | /// 颿åéæåå®¡æ ¸æ¥å£ |
| | | /// </summary> |
| | | /// <param name="input"></param> |
| | | /// <returns></returns> |
| | | public async Task<ApiAction<List<U9CReturnData>>> ApproveReqReturn(ApproveReqReturnInput input) |
| | | { |
| | | Logger.Interface.Info($"/**\r\n *è¿å
¥é¢æåéæåå®¡æ ¸æ¥å£....\r\n */\r\n"); //åºå®åæ³ |
| | | var action = new ApiAction<List<U9CReturnData>>(); |
| | | try |
| | | { |
| | | //妿已ç»ç»å½åä¸éè¦å次ç»å½ï¼ç´æ¥ä½¿ç¨ä¼ å
¥çtoken |
| | | if (input.IsLogin) |
| | | { |
| | | var u9CLoginResult = await HttpHelper.GetAsync<U9CLoginResult>($"{U9CAuthLoginUrl}userCode={Reviewer}{secret}"); |
| | | if (u9CLoginResult.Success) |
| | | { |
| | | input.token = u9CLoginResult.Data; |
| | | Logger.Interface.Info($"U9Cç»å½token: {input.token}"); |
| | | } |
| | | } |
| | | |
| | | var response = await HttpHelper.PostAsync(ConfirmReqReturnUrl, JsonConvert.SerializeObject(input.ApproveReqReturnParams), new Dictionary<string, string>() { { "token", input.token } }); |
| | | var result = JsonConvert.DeserializeObject<U9CResult>(response.Message); |
| | | if (result != null) |
| | | { |
| | | if (result.Success && result.Data[0].m_isSucess) |
| | | { |
| | | action.Data = result.Data; |
| | | Logger.Interface.Info($"颿åéæåå®¡æ ¸æ¥å£æäº¤Json: {JsonConvert.SerializeObject(input.ApproveReqReturnParams)}ï¼è¿åJson: {response.Message}"); |
| | | } |
| | | else |
| | | { |
| | | action.IsSuccessed = false; |
| | | action.LocaleMsg = new($"{action.Message}; {result.Data[0].m_errorMsg}"); |
| | | Logger.Interface.Info($"颿åéæåå®¡æ ¸æ¥å£å¤±è´¥:{result.Data[0].m_errorMsg}ï¼æäº¤Json: {JsonConvert.SerializeObject(input.ApproveReqReturnParams)}"); |
| | | } |
| | | } |
| | | } |
| | | catch (System.Exception ex) |
| | | { |
| | | action.CatchExceptionWithLog(ex, "颿å/éæååæ/éæç¡®è®¤å¼å¸¸"); |
| | | } |
| | | Logger.Interface.Info($"/* 颿åéæåå®¡æ ¸æ¥å£ç»æ */\r\n"); //åºå®åæ³ |
| | | return action; |
| | | } |
| | | } |
| | | } |
ÎļþÃû´Ó Tiger.Business.WMS/ERP/WMS_U9C.CreateMiscRcvTrans.cs ÐÞ¸Ä |
| | |
| | | //妿已ç»ç»å½åä¸éè¦å次ç»å½ï¼ç´æ¥ä½¿ç¨ä¼ å
¥çtoken |
| | | if (input.IsLogin) |
| | | { |
| | | var u9CLoginResult = await HttpHelper.GetAsync<U9CLoginResult>($"{U9CAuthLoginUrl}userCode={input.userId}{secret}"); |
| | | var u9CLoginResult = await HttpHelper.GetAsync<U9CLoginResult>($"{U9CAuthLoginUrl}userCode={Reviewer}{secret}"); |
| | | if (u9CLoginResult.Success) |
| | | { |
| | | input.token = u9CLoginResult.Data; |
ÎļþÃû´Ó Tiger.Business.WMS/ERP/WMS_U9C.CreateMiscShip.cs ÐÞ¸Ä |
| | |
| | | //妿已ç»ç»å½åä¸éè¦å次ç»å½ï¼ç´æ¥ä½¿ç¨ä¼ å
¥çtoken |
| | | if (input.IsLogin) |
| | | { |
| | | var u9CLoginResult = await HttpHelper.GetAsync<U9CLoginResult>($"{U9CAuthLoginUrl}userCode={input.userId}{secret}"); |
| | | var u9CLoginResult = await HttpHelper.GetAsync<U9CLoginResult>($"{U9CAuthLoginUrl}userCode={Reviewer}{secret}"); |
| | | if (u9CLoginResult.Success) |
| | | { |
| | | input.token = u9CLoginResult.Data; |
¶Ô±ÈÐÂÎļþ |
| | |
| | | using Tiger.Model; |
| | | using SqlSugar; |
| | | using System; |
| | | using System.Collections.Generic; |
| | | using System.Linq.Expressions; |
| | | using System.Text; |
| | | using System.Threading.Tasks; |
| | | using Rhea.Common; |
| | | using System.Net; |
| | | using System.Linq; |
| | | using Newtonsoft.Json; |
| | | using Tiger.IBusiness; |
| | | using Microsoft.AspNetCore.Http; |
| | | using Tiger.Model.Minsun; |
| | | using Org.BouncyCastle.Asn1.Tsp; |
| | | using Tiger.Model.Entitys.MES.Position; |
| | | using Apache.NMS.ActiveMQ.Commands; |
| | | using System.Security.Cryptography; |
| | | using System.Diagnostics; |
| | | using Tiger.Model.Entitys.MES.U9C; |
| | | using Newtonsoft.Json.Linq; |
| | | using System.Security.Policy; |
| | | using NetTaste; |
| | | |
| | | namespace Tiger.Business.WMS |
| | | { |
| | | public partial class WMS_U9C |
| | | { |
| | | /// <summary> |
| | | /// 颿å/éæå åæ/éæç¡®è®¤ |
| | | /// </summary> |
| | | public static string ConfirmReqReturnUrl |
| | | { get; set; } = "http://172.16.80.20/u9c/webapi/IssueDoc/Confirm"; // ApiConfig.IsTestServer ? Cache.SysParam["ConfirmReqReturnUrl_Test", "U9CUrl"].PARAM_VALUE : Cache.SysParam["ConfirmReqReturnUrl", "U9CUrl"].PARAM_VALUE; //http://172.16.80.20/u9c/webapi/IssueDoc/Confirm |
| | | |
| | | /// <summary> |
| | | /// 颿å/éæååæ/éæç¡®è®¤ |
| | | /// </summary> |
| | | /// <param name="input"></param> |
| | | /// <returns></returns> |
| | | public async Task<ApiAction<List<U9CReturnData>>> ConfirmReqReturn(ConfirmReqReturnInput input) |
| | | { |
| | | Logger.Interface.Info($"/**\r\n *è¿å
¥é¢æå/éæååæ/éæç¡®è®¤æ¥å£....\r\n */\r\n"); //åºå®åæ³ |
| | | var action = new ApiAction<List<U9CReturnData>>(); |
| | | try |
| | | { |
| | | //妿已ç»ç»å½åä¸éè¦å次ç»å½ï¼ç´æ¥ä½¿ç¨ä¼ å
¥çtoken |
| | | if (input.IsLogin) |
| | | { |
| | | var u9CLoginResult = await HttpHelper.GetAsync<U9CLoginResult>($"{U9CAuthLoginUrl}userCode={input.userId}{secret}"); |
| | | if (u9CLoginResult.Success) |
| | | { |
| | | input.token = u9CLoginResult.Data; |
| | | Logger.Interface.Info($"U9Cç»å½token: {input.token}"); |
| | | } |
| | | } |
| | | |
| | | var response = await HttpHelper.PostAsync(ConfirmReqReturnUrl, JsonConvert.SerializeObject(input.ConfirmReqReturnParams), new Dictionary<string, string>() { { "token", input.token } }); |
| | | var result = JsonConvert.DeserializeObject<U9CResult>(response.Message); |
| | | if (result != null) |
| | | { |
| | | if (result.Success && result.Data[0].m_isSucess) |
| | | { |
| | | action.Data = result.Data; |
| | | Logger.Interface.Info($"颿å/éæååæ/éæç¡®è®¤æ¥å£æäº¤Json: {JsonConvert.SerializeObject(input.ConfirmReqReturnParams)}ï¼è¿åJson: {response.Message}"); |
| | | } |
| | | else |
| | | { |
| | | action.IsSuccessed = false; |
| | | action.LocaleMsg = new($"{action.Message}; {result.Data[0].m_errorMsg}"); |
| | | Logger.Interface.Info($"颿å/éæååæ/éæç¡®è®¤æ¥å£å¤±è´¥:{result.Data[0].m_errorMsg}ï¼æäº¤Json: {JsonConvert.SerializeObject(input.ConfirmReqReturnParams)}"); |
| | | } |
| | | } |
| | | } |
| | | catch (System.Exception ex) |
| | | { |
| | | action.CatchExceptionWithLog(ex, "颿å/éæååæ/éæç¡®è®¤å¼å¸¸"); |
| | | } |
| | | Logger.Interface.Info($"/* 颿å/éæååæ/éæç¡®è®¤æ¥å£ç»æ */\r\n"); //åºå®åæ³ |
| | | return action; |
| | | } |
| | | } |
| | | } |
| | |
| | | /// </summary> |
| | | /// <param name="input"></param> |
| | | /// <returns></returns> |
| | | public async Task<ApiAction<List<U9CReturnData>>> CreateProdReturnOrder(CreateProdReturnOrderInput input) { |
| | | public async Task<ApiAction<List<U9CReturnData>>> CreateProdReturnOrderNew(CreateProdReturnOrderNewInput input) { |
| | | Logger.Interface.Info($"/**\r\n *è¿å
¥å建ç产éæå-æè¡éææ¥å£....\r\n */\r\n"); //åºå®åæ³ |
| | | var action = new ApiAction<List<U9CReturnData>>(); |
| | | try |
| | |
| | | } |
| | | } |
| | | |
| | | var response = await HttpHelper.PostAsync(CreateProdReturnOrderUrl, JsonConvert.SerializeObject(input.CreateProdReturnOrderParam), new Dictionary<string, string>() { { "token", input.token } }); |
| | | var response = await HttpHelper.PostAsync(CreateProdReturnOrderNewUrl, JsonConvert.SerializeObject(input.CreateProdReturnOrderNewParams), new Dictionary<string, string>() { { "token", input.token } }); |
| | | var result = JsonConvert.DeserializeObject<U9CResult>(response.Message); |
| | | if (result != null) |
| | | { |
| | | if (result.Success && result.Data[0].m_isSucess) |
| | | { |
| | | action.Data = result.Data; |
| | | Logger.Interface.Info($"å建ç产éæå-æè¡éææ¥å£æäº¤Json: {JsonConvert.SerializeObject(input.CreateProdReturnOrderParam)}ï¼è¿åJson: {response.Message}"); |
| | | Logger.Interface.Info($"å建ç产éæå-æè¡éææ¥å£æäº¤Json: {JsonConvert.SerializeObject(input.CreateProdReturnOrderNewParams)}ï¼è¿åJson: {response.Message}"); |
| | | } |
| | | else |
| | | { |
| | | action.IsSuccessed = false; |
| | | action.LocaleMsg = new($"{action.Message}; {result.Data[0].m_errorMsg}"); |
| | | Logger.Interface.Info($"å建ç产éæå-æè¡éææ¥å£å¤±è´¥:{result.Data[0].m_errorMsg}"); |
| | | Logger.Interface.Info($"å建ç产éæå-æè¡éææ¥å£å¤±è´¥:{result.Data[0].m_errorMsg}ï¼æäº¤Json: {JsonConvert.SerializeObject(input.CreateProdReturnOrderNewParams)}"); |
| | | } |
| | | } |
| | | } |
| | |
| | | Logger.Interface.Info($"/* å建ç产éæå-æè¡éææ¥å£ç»æ */\r\n"); //åºå®åæ³ |
| | | return action; |
| | | } |
| | | |
| | | /// <summary> |
| | | /// å建ç产éæå |
| | | /// </summary> |
| | | /// <param name="input"></param> |
| | | /// <returns></returns> |
| | | public async Task<ApiAction<List<U9CReturnData>>> CreateProdReturnOrder(CreateProdReturnOrderInput input) |
| | | { |
| | | Logger.Interface.Info($"/**\r\n *è¿å
¥å建ç产éæåæ¥å£....\r\n */\r\n"); //åºå®åæ³ |
| | | var action = new ApiAction<List<U9CReturnData>>(); |
| | | try |
| | | { |
| | | //妿已ç»ç»å½åä¸éè¦å次ç»å½ï¼ç´æ¥ä½¿ç¨ä¼ å
¥çtoken |
| | | if (input.IsLogin) |
| | | { |
| | | var u9CLoginResult = await HttpHelper.GetAsync<U9CLoginResult>($"{U9CAuthLoginUrl}userCode={input.userId}{secret}"); |
| | | if (u9CLoginResult.Success) |
| | | { |
| | | input.token = u9CLoginResult.Data; |
| | | Logger.Interface.Info($"U9Cç»å½token: {input.token}"); |
| | | } |
| | | } |
| | | |
| | | var response = await HttpHelper.PostAsync(CreateProdReturnOrderNewUrl, JsonConvert.SerializeObject(input.CreateProdReturnOrderParam), new Dictionary<string, string>() { { "token", input.token } }); |
| | | var result = JsonConvert.DeserializeObject<U9CResult>(response.Message); |
| | | if (result != null) |
| | | { |
| | | if (result.Success && result.Data[0].m_isSucess) |
| | | { |
| | | action.Data = result.Data; |
| | | Logger.Interface.Info($"å建ç产éæåæ¥å£æäº¤Json: {JsonConvert.SerializeObject(input.CreateProdReturnOrderParam)}ï¼è¿åJson: {response.Message}"); |
| | | } |
| | | else |
| | | { |
| | | action.IsSuccessed = false; |
| | | action.LocaleMsg = new($"{action.Message}; {result.Data[0].m_errorMsg}"); |
| | | Logger.Interface.Info($"å建ç产éæåæ¥å£å¤±è´¥:{result.Data[0].m_errorMsg}"); |
| | | } |
| | | } |
| | | } |
| | | catch (System.Exception ex) |
| | | { |
| | | action.CatchExceptionWithLog(ex, "å建ç产éæåå¼å¸¸"); |
| | | } |
| | | Logger.Interface.Info($"/* å建ç产éæåæ¥å£ç»æ */\r\n"); //åºå®åæ³ |
| | | return action; |
| | | } |
| | | } |
| | | } |
| | |
| | | //妿已ç»ç»å½åä¸éè¦å次ç»å½ï¼ç´æ¥ä½¿ç¨ä¼ å
¥çtoken |
| | | if (input.IsLogin) |
| | | { |
| | | var u9CLoginResult = await HttpHelper.GetAsync<U9CLoginResult>($"{U9CAuthLoginUrl}userCode={input.userId}{secret}"); |
| | | var u9CLoginResult = await HttpHelper.GetAsync<U9CLoginResult>($"{U9CAuthLoginUrl}userCode={Reviewer}{secret}"); |
| | | if (u9CLoginResult.Success) |
| | | { |
| | | input.token = u9CLoginResult.Data; |
| | |
| | | { get; set; } = "http://172.16.80.20/u9c/webapi/TransferIn/Approve"; // ApiConfig.IsTestServer ? Cache.SysParam["TransferInApproveUrl_Test", "U9CUrl"].PARAM_VALUE : Cache.SysParam["TransferInApproveUrl", "U9CUrl"].PARAM_VALUE; //http://172.16.80.20/u9c/webapi/TransferIn/Approve |
| | | |
| | | /// <summary> |
| | | /// å建ç产éæå-æè¡éææ¥å£ |
| | | /// å建è°å
¥åæ¥å£ |
| | | /// </summary> |
| | | /// <param name="input"></param> |
| | | /// <returns></returns> |
| | | public async Task<ApiAction<List<U9CReturnData>>> CreateTransferIn(CreateTransferInInput input) { |
| | | Logger.Interface.Info($"/**\r\n *è¿å
¥å建ç产éæå-æè¡éææ¥å£....\r\n */\r\n"); //åºå®åæ³ |
| | | Logger.Interface.Info($"/**\r\n *è¿å
¥å建è°å
¥åæ¥å£....\r\n */\r\n"); //åºå®åæ³ |
| | | var action = new ApiAction<List<U9CReturnData>>(); |
| | | try |
| | | { |
| | |
| | | if (result.Success && result.Data[0].m_isSucess) |
| | | { |
| | | action.Data = result.Data; |
| | | Logger.Interface.Info($"å建ç产éæå-æè¡éææ¥å£æäº¤Json: {JsonConvert.SerializeObject(input.CreateTransferInParam)}ï¼è¿åJson: {response.Message}"); |
| | | Logger.Interface.Info($"å建è°å
¥åæ¥å£æäº¤Json: {JsonConvert.SerializeObject(input.CreateTransferInParam)}ï¼è¿åJson: {response.Message}"); |
| | | } |
| | | else |
| | | { |
| | | action.IsSuccessed = false; |
| | | action.LocaleMsg = new($"{action.Message}; {result.Data[0].m_errorMsg}"); |
| | | Logger.Interface.Info($"å建ç产éæå-æè¡éææ¥å£å¤±è´¥:{result.Data[0].m_errorMsg}"); |
| | | Logger.Interface.Info($"å建è°å
¥åæ¥å£å¤±è´¥:{result.Data[0].m_errorMsg}"); |
| | | } |
| | | } |
| | | } |
| | | catch (System.Exception ex) |
| | | { |
| | | action.CatchExceptionWithLog(ex, "å建ç产éæå-æè¡éæå¼å¸¸"); |
| | | action.CatchExceptionWithLog(ex, "å建è°å
¥åå¼å¸¸"); |
| | | } |
| | | Logger.Interface.Info($"/* å建ç产éæå-æè¡éææ¥å£ç»æ */\r\n"); //åºå®åæ³ |
| | | Logger.Interface.Info($"/* å建è°å
¥åæ¥å£ç»æ */\r\n"); //åºå®åæ³ |
| | | return action; |
| | | } |
| | | |
| | |
| | | var action = new ApiAction<List<U9CReturnData2>>(); |
| | | try |
| | | { |
| | | action = await Submit(input); |
| | | if (action.IsSuccessed) |
| | | { |
| | | input.IsLogin = false; |
| | | action = await Approve(input); |
| | | } |
| | | //action = await Submit(input); |
| | | //if (action.IsSuccessed) |
| | | //{ |
| | | // input.IsLogin = false; |
| | | // action = await Approve(input); |
| | | //} |
| | | |
| | | action = await Approve(input); |
| | | } |
| | | catch (System.Exception ex) |
| | | { |
| | |
| | | public static string U9CAuthLoginUrl { get; set; } = ApiConfig.IsTestServer ? Cache.SysParam["U9CAuthLoginUrl_Test", "U9CUrl"].PARAM_VALUE : Cache.SysParam["U9CAuthLoginUrl", "U9CUrl"].PARAM_VALUE; // "http://172.16.80.20/U9C/webapi/OAuth2/AuthLogin?"; æµè¯ |
| | | //public static string U9CAuthLoginUrl { get; set; } = Cache.SysParam["U9CAuthLoginUrl", "U9CUrl"].PARAM_VALUE; //æ£å¼ |
| | | public static string secret = "&entcode=02&orgcode=101&clientid=mes&clientsecret=12c8ee7e9bb74ad2a6a0fb3315c8af20"; |
| | | /// <summary> |
| | | /// å®¡æ ¸äºº |
| | | /// </summary> |
| | | public static string Reviewer = Cache.SysParam["Reviewer", "U9CUrl"].PARAM_VALUE; |
| | | public static string CreateRcvBySrcASNUrl |
| | | { get; set; } = "http://172.16.80.20/U9C/webapi/Receivement/CreateRcvBySrcASN"; //ApiConfig.IsTestServer ? Cache.SysParam["CreateRcvBySrcASNUrl_Test", "U9CUrl"].PARAM_VALUE : Cache.SysParam["CreateRcvBySrcASNUrl", "U9CUrl"].PARAM_VALUE; //"http://172.16.80.20/U9C/webapi/Receivement/CreateRcvBySrcASN"; æµè¯ |
| | | public static string CreateReceivementUrl |
| | |
| | | { get; set; } = "http://172.16.80.20/u9c/webapi/Receivement/SubmitLine"; // ApiConfig.IsTestServer ? Cache.SysParam["SubmitLineUrl_Test", "U9CUrl"].PARAM_VALUE : Cache.SysParam["SubmitLineUrl", "U9CUrl"].PARAM_VALUE; //http://172.16.80.20/u9c/webapi/Receivement/SubmitLine; æµè¯ |
| | | public static string ApproveLineUrl |
| | | { get; set; } = "http://172.16.80.20/u9c/webapi/Receivement/ApproveLine"; // ApiConfig.IsTestServer ? Cache.SysParam["ApproveLineUrl_Test", "U9CUrl"].PARAM_VALUE : Cache.SysParam["ApproveLineUrl", "U9CUrl"].PARAM_VALUE; //http://172.16.80.20/u9c/webapi/Receivement/ApproveLine; æµè¯ |
| | | /// <summary> |
| | | /// å建çäº§é¢æå |
| | | /// </summary> |
| | | public static string CreateProdMaterialReqUrl |
| | | { get; set; } = "http://172.16.80.20/u9c/webapi/IssueDoc/Create"; // ApiConfig.IsTestServer ? Cache.SysParam["CreateProdMaterialReqUrl_Test", "U9CUrl"].PARAM_VALUE : Cache.SysParam["CreateProdMaterialReqUrl", "U9CUrl"].PARAM_VALUE; //http://172.16.80.20/u9c/webapi/IssueDoc/Create |
| | | public static string CreateProdReturnOrderUrl |
| | | /// <summary> |
| | | /// å建ç产éæå-æè¡éæ |
| | | /// </summary> |
| | | public static string CreateProdReturnOrderNewUrl |
| | | { get; set; } = "http://172.16.80.20/u9c/webapi/IssueDoc/CreateRecedeIssueDocNew"; // ApiConfig.IsTestServer ? Cache.SysParam["CreateProdReturnOrderUrl_Test", "U9CUrl"].PARAM_VALUE : Cache.SysParam["CreateProdReturnOrderUrl", "U9CUrl"].PARAM_VALUE; //http://172.16.80.20/u9c/webapi/IssueDoc/CreateRecedeIssueDocNew |
| | | /// <summary> |
| | | /// å建å§å¤çäº§é¢æå |
| | | /// </summary> |
| | | public static string CreateOutProdMaterialReqUrl |
| | | { get; set; } = "http://172.16.80.20/u9c/webapi/PMIssueDoc/Create"; // ApiConfig.IsTestServer ? Cache.SysParam["CreateOutProdMaterialReqUrl_Test", "U9CUrl"].PARAM_VALUE : Cache.SysParam["CreateOutProdMaterialReqUrl", "U9CUrl"].PARAM_VALUE; //http://172.16.80.20/u9c/webapi/PMIssueDoc/Create |
| | | /// <summary> |
| | | /// å建å§å¤ç产éæå |
| | | /// </summary> |
| | | public static string CreateOutProdReturnOrderUrl |
| | | { get; set; } = "http://172.16.80.20/u9c/webapi/PMIssueDoc/CreateRecedeIssueDoc"; // ApiConfig.IsTestServer ? Cache.SysParam["CreateOutProdReturnOrderUrl_Test", "U9CUrl"].PARAM_VALUE : Cache.SysParam["CreateOutProdReturnOrderUrl", "U9CUrl"].PARAM_VALUE; //http://172.16.80.20/u9c/webapi/PMIssueDoc/CreateRecedeIssueDoc |
| | | /// <summary> |
| | | /// å建è°å
¥å |
| | | /// </summary> |
| | | public static string CreateTransferInUrl |
| | | { get; set; } = "http://172.16.80.20/u9c/webapi/TransferIn/Create"; // ApiConfig.IsTestServer ? Cache.SysParam["CreateTransferInUrl_Test", "U9CUrl"].PARAM_VALUE : Cache.SysParam["CreateTransferInUrl", "U9CUrl"].PARAM_VALUE; //http://172.16.80.20/u9c/webapi/TransferIn/Create |
| | | |
| | |
| | | //妿已ç»ç»å½åä¸éè¦å次ç»å½ï¼ç´æ¥ä½¿ç¨ä¼ å
¥çtoken |
| | | if (input.IsLogin) |
| | | { |
| | | var u9CLoginResult = await HttpHelper.GetAsync<U9CLoginResult>($"{U9CAuthLoginUrl}userCode={input.userId}{secret}"); |
| | | var u9CLoginResult = await HttpHelper.GetAsync<U9CLoginResult>($"{U9CAuthLoginUrl}userCode={Reviewer}{secret}"); |
| | | if (u9CLoginResult.Success) |
| | | { |
| | | input.token = u9CLoginResult.Data; |
| | |
| | | } |
| | | return pickList; |
| | | } |
| | | |
| | | /// <summary> |
| | | /// æ ¹æ®åæç±»åï¼è°ç¨ç¸åºåæåæ®çERPæ¥å£ |
| | | /// </summary> |
| | | /// <param name="type"></param> |
| | | /// <param name="orderNo"></param> |
| | | /// <param name="commitInput"></param> |
| | | /// <returns></returns> |
| | | public static List<BIZ_WMS_PREP_SRC_DTL> CommitToERP(this BIZ_WMS_PREP.BIZ_TYPEs type, string orderNo, object commitInput) |
| | | { |
| | | // æ¥è¯¢åæ®æç» |
| | | var pickList = new List<BIZ_WMS_PREP_SRC_DTL>(); |
| | | switch (type) |
| | | { |
| | | case BIZ_WMS_PREP.BIZ_TYPEs.Others: |
| | | { |
| | | var dtls = Biz.Db.Queryable<BIZ_U9_MISC_OUT_DTL>().Where(q => q.ORDER_NO == orderNo).ToList(); |
| | | pickList = dtls.Select(q => q.GetPickItem()).ToList(); |
| | | } |
| | | break; |
| | | case BIZ_WMS_PREP.BIZ_TYPEs.WorkOrder: |
| | | { |
| | | var dtls = Biz.DataSource["YadaU9C"].Client.Queryable<mes_MOPickList>().Where(q => q.MoDocNo == orderNo).ToList(); |
| | | pickList = dtls.Select(q => q.GetPickItem()).ToList(); |
| | | } |
| | | break; |
| | | case BIZ_WMS_PREP.BIZ_TYPEs.Outsourcing: |
| | | { |
| | | var dtls = Biz.DataSource["YadaU9C"].Client.Queryable<mes_SCMPickList>().Where(q => q.PoDocNo == orderNo).ToList(); |
| | | pickList = dtls.Select(q => q.GetPickItem()).ToList(); |
| | | } |
| | | break; |
| | | case BIZ_WMS_PREP.BIZ_TYPEs.Requisition: |
| | | default: |
| | | break; |
| | | } |
| | | return pickList; |
| | | } |
| | | } |
| | | } |
| | |
| | | catch (Exception ex) |
| | | { |
| | | //åæ¶å½åæä½ |
| | | ResetScan(); |
| | | ResetTrans(); |
| | | //action.CatchExceptionWithLog(ex, $"æ«æ[{input.SN}]å¼å¸¸"); |
| | | action.CatchExceptionWithLog(ex, Biz.L("WMS.Default.Scan.ScanException", input.SN)); |
| | | } |
| | |
| | | action.IsSuccessed = false; |
| | | //action.LocaleMsg = Biz.L("å¨ä½[{0}]åªè½åæ¾ä¸ä¸ªç©æ"); |
| | | action.LocaleMsg = Biz.L("WMS.Default.ScanItem.LocationSingleFailure", nLocation.LOCATION_CODE); |
| | | ResetScan(); |
| | | ResetTrans(); |
| | | return SetOutPutMqttMsg(action, input.Locale); |
| | | } |
| | | |
| | |
| | | { |
| | | action.IsSuccessed = false; |
| | | action.LocaleMsg = putonResult.LocaleMsg; |
| | | ResetScan(); |
| | | ResetTrans(); |
| | | return SetOutPutMqttMsg(action, input.Locale); |
| | | } |
| | | |
| | |
| | | catch (Exception ex) |
| | | { |
| | | //åæ¶å½åæä½ |
| | | ResetScan(); |
| | | ResetTrans(); |
| | | //action.CatchExceptionWithLog(ex, $"æ«ææ¡ç [{input.SN}]夿 ¸å¼å¸¸"); |
| | | action.CatchExceptionWithLog(ex, Biz.L("WMS.Default.ScanItem.ScanException", input.SN)); |
| | | } |
| | |
| | | catch (Exception ex) |
| | | { |
| | | //åæ¶å½åæä½ |
| | | ResetScan(); |
| | | ResetTrans(); |
| | | //action.CatchExceptionWithLog(ex, $"æ«æè´§æ¶/å¨ä½[{0}]å¼å¸¸"); |
| | | action.CatchExceptionWithLog(ex, Biz.L("WMS.Default.ScanShelf.ScanException", Code)); |
| | | } |
| | |
| | | #endregion |
| | | |
| | | /// <summary> |
| | | /// éç½®å½åæä½ï¼æéè¦åéåæ¤æ¹æ³ |
| | | /// éç½®äºå¡æ°æ®ï¼æéè¦åéåæ¤æ¹æ³ |
| | | /// </summary> |
| | | public override void ResetScan() |
| | | public override void ResetTrans() |
| | | { |
| | | base.ResetScan(); |
| | | base.ResetTrans(); |
| | | ResetScanInfo(); |
| | | CurScanShelf = null; |
| | | } |
| | |
| | | catch (Exception ex) |
| | | { |
| | | //åæ¶å½åæä½ |
| | | ResetScan(); |
| | | ResetTrans(); |
| | | //action.CatchExceptionWithLog(ex, $"æ«æ[{input.SN}]å¼å¸¸"); |
| | | action.CatchExceptionWithLog(ex, Biz.L("WMS.Default.Scan.ScanException", input.SN)); |
| | | } |
| | |
| | | { |
| | | action.IsSuccessed = false; |
| | | action.LocaleMsg = downResult.LocaleMsg; |
| | | ResetScan(); |
| | | ResetTrans(); |
| | | return SetOutPutMqttMsg(action, input.Locale); |
| | | } |
| | | |
| | |
| | | } |
| | | catch (Exception ex) |
| | | { |
| | | ResetScan(); |
| | | ResetTrans(); |
| | | //action.CatchExceptionWithLog(ex, $"æ«ææ¡ç [{input.SN}]夿 ¸å¼å¸¸"); |
| | | action.CatchExceptionWithLog(ex, Biz.L("WMS.Default.ScanItem.ScanException", input.SN)); |
| | | } |
| | |
| | | catch (Exception ex) |
| | | { |
| | | //åæ¶å½åæä½ |
| | | ResetScan(); |
| | | ResetTrans(); |
| | | //action.CatchExceptionWithLog(ex, $"æ«æè´§æ¶/å¨ä½[{0}]å¼å¸¸"); |
| | | action.CatchExceptionWithLog(ex, Biz.L("WMS.Default.ScanShelf.ScanException", Code)); |
| | | } |
| | |
| | | action.LocaleMsg = Biz.L("WMS.Default.ScanItem.TakeDownSucceeded", CurInvItem.SN, CurInvItem.Location?.LOCATION_CODE); |
| | | |
| | | //éç½®å·¥åº |
| | | ResetScan(); |
| | | ResetTrans(); |
| | | return SetOutPutMqttMsg(action, locale); |
| | | } |
| | | |
| | | #endregion |
| | | |
| | | /// <summary> |
| | | /// éç½®å½åæä½ï¼æéè¦åéåæ¤æ¹æ³ |
| | | /// éç½®äºå¡æ°æ®ï¼æéè¦åéåæ¤æ¹æ³ |
| | | /// </summary> |
| | | public override void ResetScan() |
| | | public override void ResetTrans() |
| | | { |
| | | base.ResetScan(); |
| | | base.ResetTrans(); |
| | | Command = null; |
| | | CurInvItem = null; |
| | | CurScanShelf = null; |
| | |
| | | { |
| | | var action = new ApiAction(); |
| | | |
| | | ResetScan(); |
| | | ResetTrans(); |
| | | action.IsSuccessed = true; |
| | | //action.LocaleMsg = new($"æä½å·²éç½®ï¼è¯·éæ°æ«æ"); |
| | | action.LocaleMsg = new("WMS.Transaction.Reset"); |
| | |
| | | return action; |
| | | } |
| | | /// <summary> |
| | | /// éç½®å½åæä½ï¼æéè¦åéåæ¤æ¹æ³ |
| | | /// éç½®äºå¡æ°æ®ï¼æéè¦åéåæ¤æ¹æ³ |
| | | /// </summary> |
| | | public virtual void ResetScan() |
| | | public virtual void ResetTrans() |
| | | { |
| | | ProcessingSn = null; |
| | | } |
| | |
| | | catch (Exception ex) |
| | | { |
| | | //åæ¶å½åæä½ |
| | | ResetScan(); |
| | | ResetTrans(); |
| | | //action.CatchExceptionWithLog(ex, $"æ«æ[{input.SN}]å¼å¸¸"); |
| | | action.CatchExceptionWithLog(ex, Biz.L("WMS.Default.Scan.ScanException", input.SN)); |
| | | } |
| | |
| | | catch (Exception ex) |
| | | { |
| | | //åæ¶å½åæä½ |
| | | ResetScan(); |
| | | ResetTrans(); |
| | | //action.CatchExceptionWithLog(ex, $"æ«ææ¡ç [{0}]夿 ¸å¼å¸¸"); |
| | | action.CatchExceptionWithLog(ex, Biz.L("WMS.Default.ScanItem.ScanException", input.SN)); |
| | | } |
| | |
| | | action.LocaleMsg = Biz.L("WMS.Count_BIZ_U9_ASN.CountSuccess", CurSn.First().SN); |
| | | |
| | | //éç½®å·¥åº |
| | | ResetScan(); |
| | | ResetTrans(); |
| | | return SetOutPutMqttMsg(action, locale); ; |
| | | } |
| | | |
| | |
| | | #endregion |
| | | |
| | | /// <summary> |
| | | /// éç½®å½åæä½ï¼æéè¦åéåæ¤æ¹æ³ |
| | | /// éç½®äºå¡æ°æ®ï¼æéè¦åéåæ¤æ¹æ³ |
| | | /// </summary> |
| | | public override void ResetTrans() |
| | | { |
| | | ResetScan(); |
| | | CurScanShelf = null; |
| | | base.ResetTrans(); |
| | | } |
| | | |
| | | /// <summary> |
| | | /// éç½®æ¬æ¬¡æ«ç ä¿¡æ¯ |
| | | /// </summary> |
| | | public override void ResetScan() |
| | | { |
| | | base.ResetScan(); |
| | | Command = null; |
| | | Command = "Normal"; |
| | | CurInvItem = null; |
| | | CurScanShelf = null; |
| | | CurSn = null; |
| | | base.ResetScan(); |
| | | } |
| | | |
| | | public override bool Close(bool needSaveHistoryLog = false) |
| | |
| | | catch (Exception ex) |
| | | { |
| | | //åæ¶å½åæä½ |
| | | ResetScan(); |
| | | ResetTrans(); |
| | | //action.CatchExceptionWithLog(ex, $"æ«æ[{input.SN}]å¼å¸¸"); |
| | | action.CatchExceptionWithLog(ex, Biz.L("WMS.Default.Scan.ScanException", input.SN)); |
| | | } |
| | |
| | | action.IsSuccessed = false; |
| | | //action.LocaleMsg = Biz.L("å¨ä½[{0}]åªè½åæ¾ä¸ä¸ªç©æ"); |
| | | action.LocaleMsg = Biz.L("WMS.Default.ScanItem.LocationSingleFailure", nLocation.LOCATION_CODE); |
| | | ResetScan(); |
| | | ResetTrans(); |
| | | return SetOutPutMqttMsg(action, input.Locale); |
| | | } |
| | | |
| | |
| | | { |
| | | action.IsSuccessed = false; |
| | | action.LocaleMsg = putonResult.LocaleMsg; |
| | | ResetScan(); |
| | | ResetTrans(); |
| | | return SetOutPutMqttMsg(action, input.Locale); |
| | | } |
| | | |
| | |
| | | sn.IS_IN = "Y"; |
| | | } |
| | | //妿å½åè¡ä¸æ¶å®ææ 记为å¾
å®¡æ ¸ |
| | | Action approveAction = null; |
| | | receiptDtl.QTY_IN = receipt.SnList.Where(q => q.LINE_NO == receiptDtl.LINE_NO && q.STATUS == WMS_ITEM.STATUSs.InStore.GetValue()).Sum(q => q.QTY); |
| | | if (receiptDtl.QTY_IN == receiptDtl.QTY_OK) |
| | | { |
| | | receiptDtl.STATUS = BIZ_U9_RECEIPT.STATUSs.Review.GetValue(); |
| | | //å½ååæ®æç»å·²ç»å
¨é¨ä¸æ¶å®æï¼å¯ä»¥è°ç¨U9è¡å®¡æ¥å£ |
| | | approveAction = () => |
| | | //å½ååæ®æç»è¡å·²ç»å
¨é¨ä¸æ¶å®æï¼å¯ä»¥è°ç¨U9è¡å®¡æ¥å£ï¼å¦æè¡å®¡å¤±è´¥åæ¥éï¼æåä¸ä¸ªä¸æ¶å¤±è´¥ |
| | | var iInput = new SubmitLineInput |
| | | { |
| | | var iInput = new SubmitLineInput |
| | | userId = UserCode, |
| | | IsLogin = true, |
| | | param = new() |
| | | { |
| | | userId = UserCode, |
| | | IsLogin = true, |
| | | param = new() |
| | | { |
| | | RcvLineID = receiptDtl.ID, |
| | | RcvDocNo = receiptDtl.ORDER_NO, |
| | | DocLineNo = receiptDtl.LINE_NO, |
| | | OrgCode = receiptDtl.AUTH_ORG, |
| | | } |
| | | }; |
| | | var result = DI.Resolve<IWMS_U9C>().ReceivementApproveLine(iInput).Result; |
| | | if (!result.IsSuccessed) |
| | | { |
| | | throw new Exception(Biz.T(result.LocaleMsg, input.Locale)); |
| | | } |
| | | else |
| | | { |
| | | //æ´æ°åæ®ä¿¡æ¯ |
| | | MainDB.Updateable<BIZ_U9_RECEIPT_DTL>().SetColumns(q => q.STATUS == BIZ_U9_RECEIPT.STATUSs.Finished.GetValue()).Where(q => q.ID == receiptDtl.ID).ExecuteCommand(); |
| | | if (!MainDB.Queryable<BIZ_U9_RECEIPT_DTL>().Any(q => q.STATUS < BIZ_U9_RECEIPT.STATUSs.Finished.GetValue() && q.ORDER_NO == receipt.ORDER_NO)) |
| | | { |
| | | MainDB.Updateable<BIZ_U9_RECEIPT>().SetColumns(q => q.STATUS == BIZ_U9_RECEIPT.STATUSs.Finished.GetValue()).Where(q => q.ID == receipt.ID).ExecuteCommand(); |
| | | } |
| | | RcvLineID = receiptDtl.ID, |
| | | RcvDocNo = receiptDtl.ORDER_NO, |
| | | DocLineNo = receiptDtl.LINE_NO, |
| | | OrgCode = receiptDtl.AUTH_ORG, |
| | | } |
| | | }; |
| | | var result = await DI.Resolve<IWMS_U9C>().ReceivementApproveLine(iInput); |
| | | if (!result.IsSuccessed) |
| | | { |
| | | action.IsSuccessed = false; |
| | | action.LocaleMsg = result.LocaleMsg; |
| | | return SetOutPutMqttMsg(action, input.Locale); |
| | | } |
| | | else |
| | | { |
| | | receiptDtl.STATUS = BIZ_U9_RECEIPT.STATUSs.Finished.GetValue(); |
| | | } |
| | | } |
| | | else |
| | | { |
| | | receiptDtl.STATUS = BIZ_U9_RECEIPT.STATUSs.Storing.GetValue(); |
| | | } |
| | | //æ´æ°åæ®ç¶æ |
| | | if (receipt.Details.Any(q => q.STATUS < BIZ_U9_RECEIPT.STATUSs.Review.GetValue())) |
| | | { |
| | | receipt.STATUS = BIZ_U9_RECEIPT.STATUSs.Storing.GetValue(); |
| | | } |
| | | else |
| | | else if (receipt.Details.Any(q => q.STATUS < BIZ_U9_RECEIPT.STATUSs.Finished.GetValue())) |
| | | { |
| | | receipt.STATUS = BIZ_U9_RECEIPT.STATUSs.Review.GetValue(); |
| | | } |
| | | else |
| | | { |
| | | receipt.STATUS = BIZ_U9_RECEIPT.STATUSs.Finished.GetValue(); |
| | | } |
| | | |
| | | //å建åéå
é对象ç¨äºä¼ å
¥DBSubmitActionä¸ä¿åå½åéè¦æåçæ°æ®å¼ |
| | |
| | | }); |
| | | |
| | | //宿ææå¤çå使ç¨äºå¡ä¿åæ°æ® |
| | | action = DoIfFinish(action, input.Locale, approveAction); |
| | | action = DoIfFinish(action, input.Locale); |
| | | } |
| | | catch (Exception ex) |
| | | { |
| | | //åæ¶å½åæä½ |
| | | ResetScan(); |
| | | ResetTrans(); |
| | | //action.CatchExceptionWithLog(ex, $"æ«ææ¡ç [{input.SN}]夿 ¸å¼å¸¸"); |
| | | action.CatchExceptionWithLog(ex, Biz.L("WMS.Default.ScanItem.ScanException", input.SN)); |
| | | } |
| | |
| | | catch (Exception ex) |
| | | { |
| | | //åæ¶å½åæä½ |
| | | ResetScan(); |
| | | ResetTrans(); |
| | | //action.CatchExceptionWithLog(ex, $"æ«æè´§æ¶/å¨ä½[{0}]å¼å¸¸"); |
| | | action.CatchExceptionWithLog(ex, Biz.L("WMS.Default.ScanShelf.ScanException", Code)); |
| | | } |
| | |
| | | action.LocaleMsg = Biz.L("WMS.Default.ScanItem.PutOnSucceeded", CurInvItem.SN, CurInvItem.Location.LOCATION_CODE); |
| | | |
| | | //éç½®å·¥åº |
| | | ResetScanInfo(); |
| | | ResetScan(); |
| | | return SetOutPutMqttMsg(action, locale); |
| | | } |
| | | |
| | | #endregion |
| | | |
| | | /// <summary> |
| | | /// éç½®å½åæä½ï¼æéè¦åéåæ¤æ¹æ³ |
| | | /// éç½®äºå¡æ°æ®ï¼æéè¦åéåæ¤æ¹æ³ |
| | | /// </summary> |
| | | public override void ResetScan() |
| | | public override void ResetTrans() |
| | | { |
| | | base.ResetScan(); |
| | | ResetScanInfo(); |
| | | ResetScan(); |
| | | CurScanShelf = null; |
| | | base.ResetTrans(); |
| | | } |
| | | |
| | | /// <summary> |
| | | /// éç½®æ«ç ä¿¡æ¯ |
| | | /// éç½®æ¬æ¬¡æ«ç ä¿¡æ¯ |
| | | /// </summary> |
| | | public void ResetScanInfo() |
| | | public override void ResetScan() |
| | | { |
| | | Command = null; |
| | | Command = "Normal"; |
| | | CurInvItem = null; |
| | | base.ResetScan(); |
| | | } |
| | | |
| | | public override bool Close(bool needSaveHistoryLog = false) |
| | |
| | | catch (Exception ex) |
| | | { |
| | | //åæ¶å½åæä½ |
| | | ResetScan(); |
| | | ResetTrans(); |
| | | //action.CatchExceptionWithLog(ex, $"æ«æ[{input.SN}]å¼å¸¸"); |
| | | action.CatchExceptionWithLog(ex, Biz.L("WMS.Default.Scan.ScanException", input.SN)); |
| | | } |
| | |
| | | catch (Exception ex) |
| | | { |
| | | //åæ¶å½åæä½ |
| | | ResetScan(); |
| | | ResetTrans(); |
| | | //action.CatchExceptionWithLog(ex, $"夿任塿«æåæ®å¼å¸¸(Data: {0})"); |
| | | action.CatchExceptionWithLog(ex, Biz.L("WMS.Out_BIZ_WMS_PREP.ScanOrderException", input?.Data)); |
| | | } |
| | |
| | | catch (Exception ex) |
| | | { |
| | | //åæ¶å½åæä½ |
| | | ResetScan(); |
| | | ResetTrans(); |
| | | //action.CatchExceptionWithLog(ex, $"夿任å¡éæ©è¦ç©æè¡å¼å¸¸(Data: {0})"); |
| | | action.CatchExceptionWithLog(ex, Biz.L("WMS.Out_BIZ_WMS_PREP.SelectItemException", input?.Data)); |
| | | } |
| | |
| | | { |
| | | action.IsSuccessed = false; |
| | | action.LocaleMsg = downResult.LocaleMsg; |
| | | ResetScanInfo(); |
| | | ResetScan(); |
| | | return SetOutPutMqttMsg(action, input.Locale); |
| | | } |
| | | else//å¤ç夿任塿°æ® |
| | |
| | | catch (Exception ex) |
| | | { |
| | | //åæ¶å½åæä½ |
| | | ResetScan(); |
| | | //æ¸
çæåæ°æ®æäº¤æä½ |
| | | DBCommitList.Clear(); |
| | | ResetTrans(); |
| | | //action.CatchExceptionWithLog(ex, $"æ«ææ¡ç [{input.SN}]夿 ¸å¼å¸¸"); |
| | | action.CatchExceptionWithLog(ex, Biz.L("WMS.Default.ScanItem.ScanException", input.SN)); |
| | | } |
| | |
| | | catch (Exception ex) |
| | | { |
| | | //åæ¶å½åæä½ |
| | | ResetScan(); |
| | | ResetTrans(); |
| | | //action.CatchExceptionWithLog(ex, $"æ«æè´§æ¶/å¨ä½[{0}]å¼å¸¸"); |
| | | action.CatchExceptionWithLog(ex, Biz.L("WMS.Default.ScanShelf.ScanException", Code)); |
| | | } |
| | |
| | | action.LocaleMsg = Biz.L("WMS.Default.ScanItem.TakeDownSucceeded", CurInvItem.SN, CurInvItem.Location?.LOCATION_CODE); |
| | | |
| | | //éç½®å·¥åº |
| | | ResetScanInfo(); |
| | | ResetScan(); |
| | | return SetOutPutMqttMsg(action, locale); |
| | | } |
| | | |
| | | #endregion |
| | | |
| | | /// <summary> |
| | | /// éç½®å½åæä½ï¼æéè¦åéåæ¤æ¹æ³ |
| | | /// éç½®äºå¡æ°æ®ï¼æéè¦åéåæ¤æ¹æ³ |
| | | /// </summary> |
| | | public override void ResetScan() |
| | | public override void ResetTrans() |
| | | { |
| | | base.ResetScan(); |
| | | ResetScanInfo(); |
| | | ResetScan(); |
| | | CurPREP = new(MainDB, UserCode, OrgCode); |
| | | CurPrepDtl = new(); |
| | | CurScanShelf = null; |
| | | base.ResetTrans(); |
| | | } |
| | | |
| | | /// <summary> |
| | | /// éç½®æ«ç ä¿¡æ¯ |
| | | /// éç½®æ¬æ¬¡æ«ç ä¿¡æ¯ |
| | | /// </summary> |
| | | public void ResetScanInfo() |
| | | public override void ResetScan() |
| | | { |
| | | Command = "Normal"; |
| | | CurInvItem = null; |
| | | CurSn = new(); |
| | | base.ResetScan(); |
| | | } |
| | | |
| | | public override bool Close(bool needSaveHistoryLog = false) |
| | |
| | | catch (Exception ex) |
| | | { |
| | | //åæ¶å½åæä½ |
| | | ResetScan(); |
| | | ResetTrans(); |
| | | //action.CatchExceptionWithLog(ex, $"æ«æ[{input.SN}]å¼å¸¸"); |
| | | action.CatchExceptionWithLog(ex, Biz.L("WMS.Default.Scan.ScanException", input.SN)); |
| | | } |
| | |
| | | catch (Exception ex) |
| | | { |
| | | //åæ¶å½åæä½ |
| | | ResetScan(); |
| | | ResetTrans(); |
| | | action.CatchExceptionWithLog(ex, Biz.L("WMS.Default.Scan.ScanException", input.SN)); |
| | | } |
| | | return SetOutPutMqttMsg(action, input.Locale); |
| | |
| | | catch (Exception ex) |
| | | { |
| | | //åæ¶å½åæä½ |
| | | ResetScan(); |
| | | ResetTrans(); |
| | | action.CatchExceptionWithLog(ex, Biz.L("WMS.Default.Scan.ScanException", input.SN)); |
| | | } |
| | | return SetOutPutMqttMsg(action, input.Locale); |
| | |
| | | action.LocaleMsg = Biz.L("WMS.Count_BIZ_U9_ASN.CountSuccess", string.Join(",", SnList)); |
| | | |
| | | //éç½®å·¥åº |
| | | ResetScan(); |
| | | ResetTrans(); |
| | | return SetOutPutMqttMsg(action, locale); ; |
| | | } |
| | | |
| | | #endregion |
| | | |
| | | /// <summary> |
| | | /// éç½®å½åæä½ï¼æéè¦åéåæ¤æ¹æ³ |
| | | /// éç½®äºå¡æ°æ®ï¼æéè¦åéåæ¤æ¹æ³ |
| | | /// </summary> |
| | | public override void ResetScan() |
| | | public override void ResetTrans() |
| | | { |
| | | base.ResetScan(); |
| | | base.ResetTrans(); |
| | | Command = null; |
| | | CurInvItem = null; |
| | | CurScanShelf = null; |
| | |
| | | public Task<ApiAction<List<U9CReturnData2>>> ReceivementApproveLine(SubmitLineInput input); |
| | | public Task<ApiAction<List<U9CReturnData>>> CreateProdMaterialReq(CreateProdMaterialReqInput input); |
| | | public Task<ApiAction<List<U9CReturnData>>> CreateProdReturnOrder(CreateProdReturnOrderInput input); |
| | | public Task<ApiAction<List<U9CReturnData>>> CreateProdReturnOrderNew(CreateProdReturnOrderNewInput input); |
| | | public Task<ApiAction<List<U9CReturnData>>> CreateOutProdMaterialReq(CreateOutProdMaterialReqInput input); |
| | | public Task<ApiAction<List<U9CReturnData>>> CreateOutProdReturnOrder(CreateOutProdReturnOrderInput input); |
| | | public Task<ApiAction<List<U9CReturnData>>> ConfirmReqReturn(ConfirmReqReturnInput input); |
| | | public Task<ApiAction<List<U9CReturnData>>> CreateTransferForm(CreateTransferFormInput input); |
| | | public Task<ApiAction<List<U9CReturnData2>>> TransferFormApprove(TransferFormSubmitInput input); |
| | | public Task<ApiAction<List<U9CReturnData>>> CreateTransferIn(CreateTransferInInput input); |
| | |
| | | #endregion |
| | | |
| | | #region å建ç产éæå-æè¡éææ¥å£ |
| | | public class CreateProdReturnOrderInput : U9CBaseInput |
| | | public class CreateProdReturnOrderNewInput : U9CBaseInput |
| | | { |
| | | public List<CreateProdReturnOrderParam> CreateProdReturnOrderParam { get; set; } |
| | | public List<CreateProdReturnOrderNewParam> CreateProdReturnOrderNewParams { get; set; } |
| | | } |
| | | |
| | | public class CreateProdReturnOrderParam |
| | | public class CreateProdReturnOrderNewParam |
| | | { |
| | | public List<RecedeItemAndSnDTOList> RecedeItemAndSnDTOList { get; set; } |
| | | public bool IsAutoIssued { get; set; } |
| | |
| | | public double IssueLineNum { get; set; } |
| | | } |
| | | |
| | | #endregion |
| | | |
| | | #region å建ç产éæå |
| | | public class CreateProdReturnOrderInput : U9CBaseInput |
| | | { |
| | | public List<CreateProdReturnOrderParam> CreateProdReturnOrderParam { get; set; } |
| | | } |
| | | |
| | | public class CreateProdReturnOrderParam |
| | | { |
| | | /// <summary> |
| | | /// ç©æç¼ç |
| | | /// </summary> |
| | | public string ItemCode { get; set; } |
| | | /// <summary> |
| | | /// å¤æè¡¨ID |
| | | /// </summary> |
| | | public string PickID { get; set; } |
| | | /// <summary> |
| | | /// éææ°é |
| | | /// </summary> |
| | | public double RecedeQty { get; set; } |
| | | /// <summary> |
| | | /// éæçç± 0 åæ£éæ 1å§å¤éæ 2æªæéæ 3é¢æå»ºè®®éæ 4åéæ 5çç¹å·®å¼éæ 6è·¨æé´åå¼å·¥éæ |
| | | /// </summary> |
| | | public int RecedeReason { get; set; } |
| | | /// <summary> |
| | | /// 颿åè¡ID |
| | | /// </summary> |
| | | public double IssueDocLine { get; set; } |
| | | /// <summary> |
| | | /// æ¹å· |
| | | /// </summary> |
| | | public string LotNo { get; set; } |
| | | /// <summary> |
| | | /// èªå¨æ£æ é»è®¤ false |
| | | /// </summary> |
| | | public bool IsAutoIssued { get; set; } = false; |
| | | public string OtherID { get; set; } = "WMS"; |
| | | /// <summary> |
| | | /// ç¶æ 1为æäº¤ç¶æ |
| | | /// </summary> |
| | | public int DocStatus { get; set; } |
| | | } |
| | | #endregion |
| | | |
| | | #region å建å§å¤çäº§é¢æå |
| | |
| | | |
| | | #endregion |
| | | |
| | | #region 颿å/éæååæ/éæç¡®è®¤ |
| | | public class ConfirmReqReturnInput : U9CBaseInput |
| | | { |
| | | public List<ConfirmReqReturnParam> ConfirmReqReturnParams { get; set; } |
| | | } |
| | | |
| | | public class ConfirmReqReturnParam |
| | | { |
| | | /// <summary> |
| | | /// 颿å/éæåå· |
| | | /// </summary> |
| | | public string DocNo { get; set; } |
| | | public bool IsSucceed { get; set; } = true; |
| | | public string ErrorMsg { get; set; } |
| | | public bool OperateType { get; set; } = true; |
| | | public string OtherID { get; set; } = "WMS"; |
| | | public bool IsNotNewTransaction { get; set; } = true; |
| | | public bool IsAutoApp { get; set; } = true; |
| | | } |
| | | #endregion |
| | | |
| | | |
| | | #region 颿åéæåå®¡æ ¸æ¥å£ |
| | | public class ApproveReqReturnInput : U9CBaseInput |
| | | { |
| | | public List<ApproveReqReturnParam> ApproveReqReturnParams { get; set; } |
| | | } |
| | | |
| | | public class ApproveReqReturnParam: ConfirmReqReturnParam |
| | | { |
| | | } |
| | | #endregion |
| | | |
| | | #region å建è°å
¥å |
| | | public class CreateTransferInInput : U9CBaseInput |
| | | { |
| | |
| | | [DisplayName("éè´æ°é")] |
| | | public double PO_QTY { get; set; } |
| | | /// <summary> |
| | | /// æ¶è´§åID |
| | | /// </summary> |
| | | [DisplayName("æ¶è´§åID")] |
| | | public string RECEIVER_ID { get; set; } |
| | | /// <summary> |
| | | /// æ¶è´§åå· |
| | | /// </summary> |
| | | [DisplayName("æ¶è´§åå·")] |
| | | public string RECEIVER_NO { get; set; } |
| | | /// <summary> |
| | | /// æ¶è´§åè¡å· |
| | | /// </summary> |
| | | [DisplayName("æ¶è´§åè¡å·")] |
| | | public string RECEIVER_LINE { get; set; } |
| | | /// <summary> |
| | | /// æ¶è´§äºº |
| | | /// </summary> |
| | | [DisplayName("æ¶è´§äºº")] |
| | | public string RECEIVER { get; set; } |
| | | /// <summary> |
| | | /// æ¶è´§æ¥æ |
| | | /// </summary> |
| | | [DisplayName("æ¶è´§æ¥æ")] |
| | | public DateTime RECEIVE_DATE { get; set; } = DateTime.MinValue; |
| | | /// <summary> |
| | | /// 鿣åID |
| | | /// </summary> |
| | | [DisplayName("鿣åID")] |