| | |
| | | using Tiger.IBusiness; |
| | | using Tiger.Model.Sharetronic.Shelf; |
| | | using Tiger.Business.WMS.Sharetronic.Shelf; |
| | | using static IronPython.Modules._ast; |
| | | |
| | | namespace Tiger.Business.WMS.Transaction |
| | | { |
| | |
| | | { |
| | | public IIn_BIZ_U9_RECEIPT Init(string id, string userCode, string apiHost, string orgCode) |
| | | { |
| | | base.Init(id, apiHost, userCode, orgCode); |
| | | base.Init(id, userCode, apiHost, orgCode); |
| | | Logger.Console.Info($"Start {this.GetType().Name} Transaction[ID: {TransID}]"); |
| | | return this; |
| | | } |
| | |
| | | action.LocaleMsg = Biz.L("WMS.In_BIZ_U9_RECEIPT.ScanItem.ReceiptDtlStatusException", receiptDtl.LINE_NO, receiptDtl.STATUS.GetEnumDesc<BIZ_U9_RECEIPT.STATUSs>()); |
| | | return action; |
| | | } |
| | | var receiptSn = receipt.SnList.First(q => q.SN == CurInvItem.SN); |
| | | if (receiptSn.STATUS != WMS_ITEM.STATUSs.WaitIn.GetValue()) |
| | | var receiptSn = receipt.SnList.Where(q => CurInvItem.Items.Any(i => i.SN == q.SN)).ToList(); |
| | | if (receiptSn.Any(q => q.STATUS != WMS_ITEM.STATUSs.WaitIn.GetValue())) |
| | | { |
| | | action.IsSuccessed = false; |
| | | //action.LocaleMsg = Biz.L("收货单中条码[{0}]状态[{1}]异常,请扫描正确的条码"); |
| | | action.LocaleMsg = Biz.L("WMS.In_BIZ_U9_RECEIPT.ScanItem.ReceiptSnStatusException", receiptSn.SN, receiptSn.STATUS.GetEnumDesc<WMS_ITEM.STATUSs>()); |
| | | action.LocaleMsg = Biz.L("WMS.In_BIZ_U9_RECEIPT.ScanItem.ReceiptSnStatusException", CurInvItem.SN, receiptSn.First(q => q.STATUS != WMS_ITEM.STATUSs.WaitIn.GetValue()).STATUS.GetEnumDesc<WMS_ITEM.STATUSs>()); |
| | | return action; |
| | | } |
| | | |
| | |
| | | //执行上架数据处理 |
| | | foreach (var item in CurInvItem.Items) |
| | | { |
| | | item.IS_LOCKED = "Y"; |
| | | item.SOURCE_CODE = item.TRANS_CODE; |
| | | item.SOURCE_ORDER = item.TRANS_NO; |
| | | item.SOURCE_LINE = item.TRANS_LINE; |
| | |
| | | } |
| | | |
| | | //更新单据信息 |
| | | receiptSn.STATUS = WMS_ITEM.STATUSs.InStore.GetValue(); |
| | | receiptSn.IS_IN = "Y"; |
| | | foreach(var sn in receiptSn) |
| | | { |
| | | sn.STATUS = WMS_ITEM.STATUSs.InStore.GetValue(); |
| | | sn.IS_IN = "Y"; |
| | | } |
| | | //如果当前行上架完成标记为待审核 |
| | | receiptDtl.QTY_IN = receipt.SnList.Where(q => q.LINE_NO == receiptDtl.LINE_NO).Sum(q => q.QTY); |
| | | if (receiptDtl.QTY_IN == receiptDtl.QTY) |
| | |
| | | action.LocaleMsg = Biz.L("WMS.Default.ScanItem.PutOnSucceeded", CurInvItem.SN, CurInvItem.Location.LOCATION_CODE); |
| | | |
| | | //重置工序 |
| | | ResetScan(); |
| | | ResetScanInfo(); |
| | | return action; |
| | | } |
| | | |
| | |
| | | public override void ResetScan() |
| | | { |
| | | base.ResetScan(); |
| | | ResetScanInfo(); |
| | | CurScanShelf = null; |
| | | } |
| | | |
| | | /// <summary> |
| | | /// 重置扫码信息 |
| | | /// </summary> |
| | | public void ResetScanInfo() |
| | | { |
| | | Command = null; |
| | | CurInvItem = null; |
| | | CurScanShelf = null; |
| | | } |
| | | |
| | | public override bool Close(bool needSaveHistoryLog = false) |