From 379d73eaed4c3468c91b1dec52c4309d4f01522f Mon Sep 17 00:00:00 2001 From: Ben Lin <maobin001@msn.com> Date: 星期二, 25 三月 2025 09:46:34 +0800 Subject: [PATCH] 简化收货单审核流程,重构打印逻辑 --- Tiger.Business.WMS/Transaction/Yada/Print_BIZ_U9_ASN.cs | 61 ++++++++++++++++-------------- 1 files changed, 33 insertions(+), 28 deletions(-) diff --git a/Tiger.Business.WMS/Transaction/Yada/Print_BIZ_U9_ASN.cs b/Tiger.Business.WMS/Transaction/Yada/Print_BIZ_U9_ASN.cs index 0c0ad4a..51013d3 100644 --- a/Tiger.Business.WMS/Transaction/Yada/Print_BIZ_U9_ASN.cs +++ b/Tiger.Business.WMS/Transaction/Yada/Print_BIZ_U9_ASN.cs @@ -60,8 +60,17 @@ action.LocaleMsg = Biz.L("WMS.Default.ScanItem.SnEmptyFailure"); return SetOutPutMqttMsg(action, input.Locale); } - //鎵弿鐗╂枡骞跺鏍� - else //if (Command == "Normal") + //濡傛灉鏄湭涓婇棬鎴� + else if (input.Data == "0") + { + action = await GetAsnInfoForPrint(input); + } + //濡傛灉鏄殢鍗曡禒鍝佹垨鑰呮牱鍝� + else if (input.Data == "1") + { + + } + else { action = await ScanItem(input); } @@ -77,7 +86,28 @@ } /// <summary> - /// 鎵弿鐗╂枡骞跺鏍� + /// 鑾峰彇鐢ㄤ簬鎵撳嵃鐨� asn 淇℃伅 + /// </summary> + /// <param name="input"></param> + /// <returns></returns> + public async Task<ApiAction<ScanOutput>> GetAsnInfoForPrint(BaseInput input) + { + var action = new ApiAction<ScanOutput>(new ScanOutput() ); + try + { + + } + catch (Exception ex) + { + //鍙栨秷褰撳墠鎿嶄綔 + ResetScan(); + action.CatchExceptionWithLog(ex, Biz.L("WMS.Default.Scan.ScanException", input.SN)); + } + return SetOutPutMqttMsg(action, input.Locale); + } + + /// <summary> + /// 鎵弿鏉$爜鍒嗘瀽绫诲瀷 /// </summary> public async Task<ApiAction<ScanOutput>> ScanItem(BaseInput input) { @@ -210,21 +240,6 @@ sn.RECEIVE_DATE = DateTime.MinValue; } - //var historys = new List<WMS_ITEM_HIS>(); - //var items = await Biz.Db.Queryable<WMS_ITEM>().Where(q => ScanList.Select(s => s.SN).Contains(q.SN)).ToListAsync(); - //foreach (var item in items) - //{ - // var order = item.TRANS_CODE; - // item.STATUS = WMS_ITEM.STATUSs.Incoming.GetValue(); - // item.SOURCE_CODE = ""; - // item.SOURCE_ORDER = ""; - // item.SOURCE_LINE = ""; - // item.TRANS_CODE = item.SOURCE_CODE; - // item.TRANS_NO = item.SOURCE_ORDER; - // item.TRANS_LINE = item.SOURCE_LINE; - // historys.Add(new WMS_ITEM_HIS(item, $"鏉$爜[{item.SN}]鍙栨秷娓呯偣锛屾搷浣滃崟鎹甗{order}]")); - //} - //浣跨敤缁熶竴鐨勪簨鍔B瀵硅薄 var db = GetCommitDB(); var dbTran = db.UseTran(() => @@ -261,16 +276,6 @@ var action = new ApiAction(); try { - //var item = await Biz.Db.Queryable<WMS_ITEM>().Where(q => q.SN == input.SN).FirstAsync(); - //var order = item.TRANS_CODE; - //item.STATUS = WMS_ITEM.STATUSs.Incoming.GetValue(); - //item.SOURCE_CODE = ""; - //item.SOURCE_ORDER = ""; - //item.SOURCE_LINE = ""; - //item.TRANS_CODE = item.SOURCE_CODE; - //item.TRANS_NO = item.SOURCE_ORDER; - //item.TRANS_LINE = item.SOURCE_LINE; - //浣跨敤缁熶竴鐨勪簨鍔B瀵硅薄 var db = GetCommitDB(); var dbTran = db.UseTran(() => -- Gitblit v1.9.3