From 4a68e02a9dbffe0b215ceb1d9758ccb17329e523 Mon Sep 17 00:00:00 2001
From: schangxiang@126.com <schangxiang@126.com>
Date: 周三, 18 12月 2024 10:49:30 +0800
Subject: [PATCH] 222
---
LA24030_LuLiPackageLine_Wms/Admin.NET.Application/Connected Services/CCWcfService/ConnectedService.json | 10
LA24030_LuLiPackageLine_Wms/Admin.NET.Application/Service/WmsOperationTask/WmsOperationTaskService.cs | 169 +++++++++-----
LA24030_LuLiPackageLine_Wms/Admin.NET.Application/Service/ReportCenter/Mes_Package_UnLine_Record/Dto/Mes_Package_UnLine_RecordInput.cs | 51 ++++
LA24030_LuLiPackageLine_Web/src/views/main/ReportCenter/mes_Package_UnLine_Record/index.vue | 29 ++
LA24030_LuLiPackageLine_Web/src/views/main/ReportCenter/mes_Package_UnLine_Record/component/editDialog.vue | 23 +
LA24030_LuLiPackageLine_Wms/Admin.NET.Application/Connected Services/CCWcfService/Reference.cs | 8
CC/iWareCC_ASRS/FormCC.cs | 2
LA24030_LuLiPackageLine_Web/src/views/main/WmsOrder/manualFeedKitting/index.vue | 26 +
CC/iWareCC_ASRS/ThreadService/05_BZ30(齐套验证)/DataProcess_ValidateQiTao.cs | 268 +++++++++++-----------
LA24030_LuLiPackageLine_Wms/Admin.NET.Application/Service/ReportCenter/Mes_Package_UnLine_Record/Mes_Package_UnLine_RecordService.cs | 14 +
LA24030_LuLiPackageLine_Wms/Admin.NET.Application/Service/WmsOperationTask/Dto/ValidateQiTaoOutput.cs | 6
CC/iWareCC_ASRS/WCF/CCWcfService.cs | 27 ++
LA24030_LuLiPackageLine_Wms/Admin.NET.Application/Entity/WmsOrder/Mes_Package_UnLine_Record.cs | 12 +
LA24030_LuLiPackageLine_Wms/Admin.NET.Application/Service/ReportCenter/Mes_Package_UnLine_Record/Dto/Mes_Package_UnLine_RecordOutput.cs | 15 +
CC/iWareCC_ASRS/WCF/ICCWcfService.cs | 9
15 files changed, 458 insertions(+), 211 deletions(-)
diff --git a/CC/iWareCC_ASRS/FormCC.cs b/CC/iWareCC_ASRS/FormCC.cs
index 7d9b439..b6db60b 100644
--- a/CC/iWareCC_ASRS/FormCC.cs
+++ b/CC/iWareCC_ASRS/FormCC.cs
@@ -250,7 +250,7 @@
new Thread(PushPackageCodeToMes.Handler).Start();
new Thread(PushPaperCutToMes.Handler).Start();
- new Thread(DataProcess_ValidateQiTao.Handler).Start();
+ //new Thread(DataProcess_ValidateQiTao.Handler).Start();
//*/
#endregion
diff --git "a/CC/iWareCC_ASRS/ThreadService/05_BZ30\050\351\275\220\345\245\227\351\252\214\350\257\201\051/DataProcess_ValidateQiTao.cs" "b/CC/iWareCC_ASRS/ThreadService/05_BZ30\050\351\275\220\345\245\227\351\252\214\350\257\201\051/DataProcess_ValidateQiTao.cs"
index 527392a..f83187a 100644
--- "a/CC/iWareCC_ASRS/ThreadService/05_BZ30\050\351\275\220\345\245\227\351\252\214\350\257\201\051/DataProcess_ValidateQiTao.cs"
+++ "b/CC/iWareCC_ASRS/ThreadService/05_BZ30\050\351\275\220\345\245\227\351\252\214\350\257\201\051/DataProcess_ValidateQiTao.cs"
@@ -1,149 +1,149 @@
-锘縰sing Admin.NET.Application;
-using iWareCC.Common.Helper;
-using iWareCC.StationService;
-using iWareCommon.Common.Globle;
-using iWareCommon.Utils;
-using iWareModel;
-using iWareSql.DataAccess;
-using iWareSql.DBModel;
-using iWareSql.WmsDBModel;
-using System;
-using System.Collections.Generic;
-using System.Linq;
-using System.Runtime.Remoting.Messaging;
-using System.ServiceModel.Configuration;
-using System.Text;
-using System.Threading;
-using System.Threading.Tasks;
-using WZ.Useful.Commons;
-using XiGang.Core.Model;
+锘�//using Admin.NET.Application;
+//using iWareCC.Common.Helper;
+//using iWareCC.StationService;
+//using iWareCommon.Common.Globle;
+//using iWareCommon.Utils;
+//using iWareModel;
+//using iWareSql.DataAccess;
+//using iWareSql.DBModel;
+//using iWareSql.WmsDBModel;
+//using System;
+//using System.Collections.Generic;
+//using System.Linq;
+//using System.Runtime.Remoting.Messaging;
+//using System.ServiceModel.Configuration;
+//using System.Text;
+//using System.Threading;
+//using System.Threading.Tasks;
+//using WZ.Useful.Commons;
+//using XiGang.Core.Model;
-namespace iWareCC.ThreadService
-{
- /// <summary>
- /// BZ30榻愬楠岃瘉
- /// </summary>
- public static class DataProcess_ValidateQiTao
- {
- public static async void Handler()
- {
- var alertMsg = "";
- LogType logType = LogType.DataProcess_ValidateQiTao;
- while (true)
- {
- Thread.Sleep(2000);//浼戠湢2绉掞紝灏嗕紤鐪犲啓鍒板墠闈紝鏄负浜嗕笅闈㈢殑continue鏂规硶鎵ц鍚庝笉鏄剧ず閿欒淇℃伅鐨勬彁绀猴紒锛侊紒銆怑ditBy shaocx,2022-05-24銆�
- SystemWarningMsg._lbl_Alert_DataProcess_ValidateQiTao = string.Empty;
- try
- {
- //if (SystemValue.isAllowRuning_DataProcess_ValidateQiTao && SystemValue.isStartedModel)
- if (SystemValue.isStartedModel)
- {
- var rgvLocation = StationLocationEnum.BZ30.ToString();
+//namespace iWareCC.ThreadService
+//{
+// /// <summary>
+// /// BZ30榻愬楠岃瘉
+// /// </summary>
+// public static class DataProcess_ValidateQiTao
+// {
+// public static async void Handler()
+// {
+// var alertMsg = "";
+// LogType logType = LogType.DataProcess_ValidateQiTao;
+// while (true)
+// {
+// Thread.Sleep(2000);//浼戠湢2绉掞紝灏嗕紤鐪犲啓鍒板墠闈紝鏄负浜嗕笅闈㈢殑continue鏂规硶鎵ц鍚庝笉鏄剧ず閿欒淇℃伅鐨勬彁绀猴紒锛侊紒銆怑ditBy shaocx,2022-05-24銆�
+// SystemWarningMsg._lbl_Alert_DataProcess_ValidateQiTao = string.Empty;
+// try
+// {
+// //if (SystemValue.isAllowRuning_DataProcess_ValidateQiTao && SystemValue.isStartedModel)
+// if (SystemValue.isStartedModel)
+// {
+// var rgvLocation = StationLocationEnum.BZ30.ToString();
- using (WmsDBModel wmsDB = new WmsDBModel())
- {
- var bz30Config = wmsDB.SysConfig.Where(x => x.Code == "wms_bz30_qitao").FirstOrDefault();
- if (bz30Config == null)
- {
- SystemWarningMsg._lbl_Alert_DataProcess_ValidateQiTao = $"娌℃湁閰嶇疆 wms_bz30_qitao 鍊�";
- continue;
- }
- var configValue = bz30Config.Value;
- if (string.IsNullOrEmpty(configValue) || configValue.IndexOf('|') <= -1)
- {
- SystemWarningMsg._lbl_Alert_DataProcess_ValidateQiTao = $"閰嶇疆 wms_bz30_qitao 鍊納configValue}涓虹┖鎴栦笉姝g‘";
- continue;
- }
- var configValues = configValue.Split('|');
- var packageCode = configValues[0];
- var qitaoValue = configValues[1];//榻愬 涓嶉綈濂�
- var _UnlinePerson = configValues[2];
- bool iscomplete = false;
- if (qitaoValue.Equals("榻愬"))
- {
- iscomplete = true;
- }
- //TODO:鎺ㄩ�佺粰PLC 鍘诲摢涓柟鍚戯紵
+// using (WmsDBModel wmsDB = new WmsDBModel())
+// {
+// var bz30Config = wmsDB.SysConfig.Where(x => x.Code == "wms_bz30_qitao").FirstOrDefault();
+// if (bz30Config == null)
+// {
+// SystemWarningMsg._lbl_Alert_DataProcess_ValidateQiTao = $"娌℃湁閰嶇疆 wms_bz30_qitao 鍊�";
+// continue;
+// }
+// var configValue = bz30Config.Value;
+// if (string.IsNullOrEmpty(configValue) || configValue.IndexOf('|') <= -1)
+// {
+// SystemWarningMsg._lbl_Alert_DataProcess_ValidateQiTao = $"閰嶇疆 wms_bz30_qitao 鍊納configValue}涓虹┖鎴栦笉姝g‘";
+// continue;
+// }
+// var configValues = configValue.Split('|');
+// var packageCode = configValues[0];
+// var qitaoValue = configValues[1];//榻愬 涓嶉綈濂�
+// var _UnlinePerson = configValues[2];
+// bool iscomplete = false;
+// if (qitaoValue.Equals("榻愬"))
+// {
+// iscomplete = true;
+// }
+// //TODO:鎺ㄩ�佺粰PLC 鍘诲摢涓柟鍚戯紵
- using (StationServiceClient client = new StationServiceClient())
- {
- var res = client.WriteQiTaoInfo((int)EDevice.Station, rgvLocation, iscomplete);
- if (!res.result)
- {
- SystemWarningMsg._lbl_Alert_DataProcess_ValidateQiTao = $"{rgvLocation.ToString()}-鎺ㄩ�佺粰PLC鏄惁榻愬澶辫触,ChangeModeAsync 杩斿洖:{res.resMsg}";
- continue;
- }
- else
- {
- Log4NetHelper.WriteInfoLog(logType, $"{rgvLocation.ToString()}-鎺ㄩ�佺粰PLC鏄惁榻愬 鎴愬姛,ChangeModeAsync锛屽弬鏁�: 绔欑偣{rgvLocation}");
- }
- }
- //
+// using (StationServiceClient client = new StationServiceClient())
+// {
+// var res = client.WriteQiTaoInfo((int)EDevice.Station, rgvLocation, iscomplete);
+// if (!res.result)
+// {
+// SystemWarningMsg._lbl_Alert_DataProcess_ValidateQiTao = $"{rgvLocation.ToString()}-鎺ㄩ�佺粰PLC鏄惁榻愬澶辫触,ChangeModeAsync 杩斿洖:{res.resMsg}";
+// continue;
+// }
+// else
+// {
+// Log4NetHelper.WriteInfoLog(logType, $"{rgvLocation.ToString()}-鎺ㄩ�佺粰PLC鏄惁榻愬 鎴愬姛,ChangeModeAsync锛屽弬鏁�: 绔欑偣{rgvLocation}");
+// }
+// }
+// //
- //鏇存柊鍊�
- bz30Config.Value = "";
- var package = wmsDB.mes_package_gather.Where(x => x.PackageCode == packageCode).FirstOrDefault();
- if (package != null)
- {
- package.UpiStatus = (int)UpiStatusEnum.宸蹭笅绾�;
- package.AreaCode = (int)AreaCodeEnum.涓嬬嚎鍖哄煙;
- }
- var upiList = wmsDB.mes_batchOrderUPI_new.Where(x => x.PackageCode == packageCode).ToList();
- foreach (var item in upiList)
- {
- item.UpiStatus = (int)UpiStatusEnum.宸蹭笅绾�;
- item.AreaCode = (int)AreaCodeEnum.涓嬬嚎鍖哄煙;
- item.UpdateTime = DateTime.Now;
- }
- //鍒犻櫎闃熷垪淇℃伅
- var lineQueue = wmsDB.mes_package_linequeue.Where(x => x.PackageCode == packageCode).FirstOrDefault();
- if (lineQueue != null)
- {
- wmsDB.mes_package_linequeue.Remove(lineQueue);
- }
+// //鏇存柊鍊�
+// bz30Config.Value = "";
+// var package = wmsDB.mes_package_gather.Where(x => x.PackageCode == packageCode).FirstOrDefault();
+// if (package != null)
+// {
+// package.UpiStatus = (int)UpiStatusEnum.宸蹭笅绾�;
+// package.AreaCode = (int)AreaCodeEnum.涓嬬嚎鍖哄煙;
+// }
+// var upiList = wmsDB.mes_batchOrderUPI_new.Where(x => x.PackageCode == packageCode).ToList();
+// foreach (var item in upiList)
+// {
+// item.UpiStatus = (int)UpiStatusEnum.宸蹭笅绾�;
+// item.AreaCode = (int)AreaCodeEnum.涓嬬嚎鍖哄煙;
+// item.UpdateTime = DateTime.Now;
+// }
+// //鍒犻櫎闃熷垪淇℃伅
+// var lineQueue = wmsDB.mes_package_linequeue.Where(x => x.PackageCode == packageCode).FirstOrDefault();
+// if (lineQueue != null)
+// {
+// wmsDB.mes_package_linequeue.Remove(lineQueue);
+// }
- //澶勭悊琛� mes_order_gather
- var errmsg = "";
- var result = MyExtendHelper.HandlerOrderGather(wmsDB, package, qitaoValue, _UnlinePerson, out errmsg);
- if (result == false)
- {
- SystemWarningMsg._lbl_Alert_DataProcess_ValidateQiTao = errmsg;
- continue;
- }
+// //澶勭悊琛� mes_order_gather
+// var errmsg = "";
+// var result = MyExtendHelper.HandlerOrderGather(wmsDB, package, qitaoValue, _UnlinePerson, out errmsg);
+// if (result == false)
+// {
+// SystemWarningMsg._lbl_Alert_DataProcess_ValidateQiTao = errmsg;
+// continue;
+// }
- //鏂板涓嬬嚎璁板綍
- //鍒ゆ柇濡傛灉鍖呭凡缁忎笅绾夸簡锛屽氨涓嶅啀鍐欏叆涓嬬嚎璁板綍浜�
- var existPackObj = wmsDB.mes_package_unline_record.Where(x => x.PackageCode == package.PackageCode).FirstOrDefault();
- if (existPackObj == null)
- {
- mes_package_unline_record record = new mes_package_unline_record();
- record = ClassHelper.RotationMapping<mes_package_unline_record, mes_package_gather>(package);
- record.Id = Yitter.IdGenerator.YitIdHelper.NextId();
- record.CreateTime = DateTime.Now;
- record.UpdateTime = DateTime.Now;
- record.OpRemark = "涓嬬嚎";
- wmsDB.mes_package_unline_record.Add(record);
- }
+// //鏂板涓嬬嚎璁板綍
+// //鍒ゆ柇濡傛灉鍖呭凡缁忎笅绾夸簡锛屽氨涓嶅啀鍐欏叆涓嬬嚎璁板綍浜�
+// var existPackObj = wmsDB.mes_package_unline_record.Where(x => x.PackageCode == package.PackageCode).FirstOrDefault();
+// if (existPackObj == null)
+// {
+// mes_package_unline_record record = new mes_package_unline_record();
+// record = ClassHelper.RotationMapping<mes_package_unline_record, mes_package_gather>(package);
+// record.Id = Yitter.IdGenerator.YitIdHelper.NextId();
+// record.CreateTime = DateTime.Now;
+// record.UpdateTime = DateTime.Now;
+// record.OpRemark = "涓嬬嚎";
+// wmsDB.mes_package_unline_record.Add(record);
+// }
- WmsRecordUpiProcessHandler.SaveWmsRecordPackageProcess(wmsDB, package, "BZ30", "榻愬楠岃瘉");
+// WmsRecordUpiProcessHandler.SaveWmsRecordPackageProcess(wmsDB, package, "BZ30", "榻愬楠岃瘉");
- wmsDB.SaveChanges();
- }
- }
+// wmsDB.SaveChanges();
+// }
+// }
- }
- catch (Exception ex)
- {
- SystemWarningMsg._lbl_Alert_DataProcess_ValidateQiTao += " 鍑虹幇寮傚父:" + ex.Message + SysGloble.SPLIT_STR;
- Log4NetHelper.WriteErrorLog(logType, " 鍑虹幇寮傚父锛�" + ex.Message, ex);
- }
- }
- }
+// }
+// catch (Exception ex)
+// {
+// SystemWarningMsg._lbl_Alert_DataProcess_ValidateQiTao += " 鍑虹幇寮傚父:" + ex.Message + SysGloble.SPLIT_STR;
+// Log4NetHelper.WriteErrorLog(logType, " 鍑虹幇寮傚父锛�" + ex.Message, ex);
+// }
+// }
+// }
- }
-}
+// }
+//}
diff --git a/CC/iWareCC_ASRS/WCF/CCWcfService.cs b/CC/iWareCC_ASRS/WCF/CCWcfService.cs
index a0221ba..e1f068f 100644
--- a/CC/iWareCC_ASRS/WCF/CCWcfService.cs
+++ b/CC/iWareCC_ASRS/WCF/CCWcfService.cs
@@ -120,5 +120,32 @@
}
}
+
+ /// <summary>
+ /// 涓嬬嚎鏀捐鏂瑰悜
+ /// </summary>
+ /// <param name="iscomplete"></param>
+ /// <returns></returns>
+ public FunRetEntity WriteQiTaoInfo(bool iscomplete)
+ {
+ try
+ {
+ using (StationServiceClient client = new StationServiceClient())
+ {
+ var res = client.WriteQiTaoInfo((int)EDevice.Station, StationLocationEnum.BZ30.ToString(), iscomplete);
+ if (!res.result)
+ {
+ return FunRetEntity.Fail(res.resMsg);
+ }
+ }
+
+ return FunRetEntity.Success("鎴愬姛", "");
+ }
+ catch (Exception ex)
+ {
+ return FunRetEntity.Fail("寮傚父:" + ex.Message);
+ }
+ }
+
}
}
diff --git a/CC/iWareCC_ASRS/WCF/ICCWcfService.cs b/CC/iWareCC_ASRS/WCF/ICCWcfService.cs
index 66cdebe..2a17381 100644
--- a/CC/iWareCC_ASRS/WCF/ICCWcfService.cs
+++ b/CC/iWareCC_ASRS/WCF/ICCWcfService.cs
@@ -47,5 +47,14 @@
[OperationContract]
FunRetEntity WriteStation_PartClear();
+
+ /// <summary>
+ /// 涓嬬嚎鏀捐鏂瑰悜
+ /// </summary>
+ /// <param name="iscomplete"></param>
+ /// <returns></returns>
+ [OperationContract]
+ FunRetEntity WriteQiTaoInfo(bool iscomplete);
+
}
}
diff --git a/LA24030_LuLiPackageLine_Web/src/views/main/ReportCenter/mes_Package_UnLine_Record/component/editDialog.vue b/LA24030_LuLiPackageLine_Web/src/views/main/ReportCenter/mes_Package_UnLine_Record/component/editDialog.vue
index e7718b2..acc201d 100644
--- a/LA24030_LuLiPackageLine_Web/src/views/main/ReportCenter/mes_Package_UnLine_Record/component/editDialog.vue
+++ b/LA24030_LuLiPackageLine_Web/src/views/main/ReportCenter/mes_Package_UnLine_Record/component/editDialog.vue
@@ -30,6 +30,27 @@
</el-col>
<el-col :xs="24" :sm="12" :md="12" :lg="12" :xl="12" class="mb20">
+ <el-form-item label="涓嬬嚎浣嶇疆" prop="location">
+ <el-input v-model="ruleForm.location" placeholder="璇疯緭鍏ヤ笅绾夸綅缃�" maxlength="50" show-word-limit clearable />
+
+ </el-form-item>
+
+ </el-col>
+ <el-col :xs="24" :sm="12" :md="12" :lg="12" :xl="12" class="mb20">
+ <el-form-item label="鎬诲寘鏁�" prop="allPackageNum">
+ <el-input-number v-model="ruleForm.allPackageNum" placeholder="璇疯緭鍏ユ�诲寘鏁�" clearable />
+
+ </el-form-item>
+
+ </el-col>
+ <el-col :xs="24" :sm="12" :md="12" :lg="12" :xl="12" class="mb20">
+ <el-form-item label="褰撳墠绗嚑鍖呬笅绾�" prop="curUnlineIndexPackageNum">
+ <el-input-number v-model="ruleForm.curUnlineIndexPackageNum" placeholder="璇疯緭鍏ュ綋鍓嶇鍑犲寘涓嬬嚎" clearable />
+
+ </el-form-item>
+
+ </el-col>
+ <el-col :xs="24" :sm="12" :md="12" :lg="12" :xl="12" class="mb20">
<el-form-item label="鐢熶骇鍗曞彿" prop="info5">
<el-input v-model="ruleForm.info5" placeholder="璇疯緭鍏ョ敓浜у崟鍙�" maxlength="60" show-word-limit clearable />
@@ -178,6 +199,8 @@
//鑷娣诲姞鍏朵粬瑙勫垯
const rules = ref<FormRules>({
packageCode: [{required: true, message: '璇疯緭鍏ュ寘瑁呭彿锛�', trigger: 'blur',},],
+ allPackageNum: [{required: true, message: '璇疯緭鍏ユ�诲寘鏁帮紒', trigger: 'blur',},],
+ curUnlineIndexPackageNum: [{required: true, message: '璇疯緭鍏ュ綋鍓嶇鍑犲寘涓嬬嚎锛�', trigger: 'blur',},],
planNo: [{required: true, message: '璇疯緭鍏ユ壒娆″彿锛�', trigger: 'blur',},],
orderId: [{required: true, message: '璇疯緭鍏ヨ鍗曞彿锛�', trigger: 'blur',},],
isDelete: [{required: true, message: '璇烽�夋嫨杞垹闄わ紒', trigger: 'change',},],
diff --git a/LA24030_LuLiPackageLine_Web/src/views/main/ReportCenter/mes_Package_UnLine_Record/index.vue b/LA24030_LuLiPackageLine_Web/src/views/main/ReportCenter/mes_Package_UnLine_Record/index.vue
index e00d49b..1217245 100644
--- a/LA24030_LuLiPackageLine_Web/src/views/main/ReportCenter/mes_Package_UnLine_Record/index.vue
+++ b/LA24030_LuLiPackageLine_Web/src/views/main/ReportCenter/mes_Package_UnLine_Record/index.vue
@@ -5,7 +5,7 @@
<el-row>
<el-col :xs="24" :sm="12" :md="12" :lg="8" :xl="4" class="mb10">
<el-form-item label="鍏抽敭瀛�">
- <el-input v-model="queryParamsMes_Package_UnLine_Record.searchKey" clearable="" placeholder="鍖呰鍙�,鐢熶骇鍗曞彿,鎵规鍙�,璁㈠崟鍙�,閿�鍞悎鍚屽崟鍙�,绗嚑鍖�,缁忛攢搴楀悕绉�,浜у搧鍚嶇О,瀹㈡埛鍚嶇О,鑷彁or鍙戣揣,鍖呰閮ㄤ欢鎬绘暟閲�,鍖呰闈㈢Н,澶囨敞,鍒涘缓浜�,淇敼浜�"/>
+ <el-input v-model="queryParamsMes_Package_UnLine_Record.searchKey" clearable="" placeholder="鍖呰鍙�,涓嬬嚎浣嶇疆,鐢熶骇鍗曞彿,鎵规鍙�,璁㈠崟鍙�,閿�鍞悎鍚屽崟鍙�,绗嚑鍖�,缁忛攢搴楀悕绉�,浜у搧鍚嶇О,瀹㈡埛鍚嶇О,鑷彁or鍙戣揣,鍖呰閮ㄤ欢鎬绘暟閲�,鍖呰闈㈢Н,澶囨敞,鍒涘缓浜�,淇敼浜�"/>
</el-form-item>
</el-col>
@@ -21,6 +21,24 @@
<el-option v-for="(item,index) in getEnumUpiFlagData_Index" :key="index" :value="item.value" :label="`${item.describe}`" />
</el-select>
+
+ </el-form-item>
+ </el-col>
+ <el-col :xs="24" :sm="12" :md="12" :lg="8" :xl="4" class="mb10" v-if="showAdvanceQueryUIMes_Package_UnLine_Record">
+ <el-form-item label="涓嬬嚎浣嶇疆">
+ <el-input v-model="queryParamsMes_Package_UnLine_Record.location" clearable="" placeholder="璇疯緭鍏ヤ笅绾夸綅缃�"/>
+
+ </el-form-item>
+ </el-col>
+ <el-col :xs="24" :sm="12" :md="12" :lg="8" :xl="4" class="mb10" v-if="showAdvanceQueryUIMes_Package_UnLine_Record">
+ <el-form-item label="鎬诲寘鏁�">
+ <el-input-number v-model="queryParamsMes_Package_UnLine_Record.allPackageNum" clearable="" placeholder="璇疯緭鍏ユ�诲寘鏁�"/>
+
+ </el-form-item>
+ </el-col>
+ <el-col :xs="24" :sm="12" :md="12" :lg="8" :xl="4" class="mb10" v-if="showAdvanceQueryUIMes_Package_UnLine_Record">
+ <el-form-item label="褰撳墠绗嚑鍖呬笅绾�">
+ <el-input-number v-model="queryParamsMes_Package_UnLine_Record.curUnlineIndexPackageNum" clearable="" placeholder="璇疯緭鍏ュ綋鍓嶇鍑犲寘涓嬬嚎"/>
</el-form-item>
</el-col>
@@ -120,6 +138,12 @@
</el-form-item>
</el-col>
+ <el-col :xs="24" :sm="12" :md="12" :lg="8" :xl="4" class="mb10" v-if="showAdvanceQueryUIMes_Package_UnLine_Record">
+ <el-form-item label="淇敼鏃堕棿">
+ <el-date-picker placeholder="璇烽�夋嫨淇敼鏃堕棿" value-format="YYYY/MM/DD HH:mm:ss" type="datetimerange" :default-time="defaultTimeRange" v-model="queryParamsMes_Package_UnLine_Record.updateTimeRange" />
+
+ </el-form-item>
+ </el-col>
<el-col :xs="24" :sm="12" :md="12" :lg="6" :xl="6" class="mb10">
<el-form-item>
<el-button-group style="display: flex; align-items: center;">
@@ -153,6 +177,9 @@
<el-tag>{{ getEnumDesc(scope.row.upiFlag, getEnumUpiFlagData_Index)}}</el-tag>
</template>
</el-table-column>
+ <el-table-column prop="location" label="涓嬬嚎浣嶇疆" show-overflow-tooltip="" />
+ <el-table-column prop="allPackageNum" label="鎬诲寘鏁�" show-overflow-tooltip="" />
+ <el-table-column prop="curUnlineIndexPackageNum" label="褰撳墠绗嚑鍖呬笅绾�" show-overflow-tooltip="" />
<el-table-column prop="info5" label="鐢熶骇鍗曞彿" show-overflow-tooltip="" />
<el-table-column prop="planNo" label="鎵规鍙�" show-overflow-tooltip="" />
<el-table-column prop="orderId" label="璁㈠崟鍙�" show-overflow-tooltip="" />
diff --git a/LA24030_LuLiPackageLine_Web/src/views/main/WmsOrder/manualFeedKitting/index.vue b/LA24030_LuLiPackageLine_Web/src/views/main/WmsOrder/manualFeedKitting/index.vue
index 2d4f536..0d2010b 100644
--- a/LA24030_LuLiPackageLine_Web/src/views/main/WmsOrder/manualFeedKitting/index.vue
+++ b/LA24030_LuLiPackageLine_Web/src/views/main/WmsOrder/manualFeedKitting/index.vue
@@ -34,7 +34,7 @@
<br />
<div class="detailBox" style="height: calc(65vh)">
<div class="titleTip">
- <div class="" v-show="isSuccess == '鎴愬姛' && qiTaoReuslt=='榻愬' ">
+ <div class="" v-show="isSuccess == '鎴愬姛' && isNewOrder===false ">
<svg t="1732788314050" class="icon" viewBox="0 0 1024 1024" version="1.1" xmlns="http://www.w3.org/2000/svg" p-id="11359" width="100" height="100">
<path
d="M874.119618 149.859922A510.816461 510.816461 0 0 0 511.997 0.00208a509.910462 509.910462 0 0 0-362.119618 149.857842c-199.817789 199.679789-199.817789 524.581447 0 724.260236a509.969462 509.969462 0 0 0 362.119618 149.857842A508.872463 508.872463 0 0 0 874.119618 874.120158c199.836789-199.679789 199.836789-524.581447 0-724.260236zM814.94268 378.210681L470.999043 744.132295a15.359984 15.359984 0 0 1-5.887994 4.095996c-1.751998 1.180999-2.913997 2.362998-5.276994 2.913997a34.499964 34.499964 0 0 1-13.469986 2.914997 45.547952 45.547952 0 0 1-12.897986-2.303998l-4.095996-2.363997a45.291952 45.291952 0 0 1-7.009992-4.095996l-196.902793-193.789796a34.126964 34.126964 0 0 1-10.555989-25.186973c0-9.37399 3.583996-18.74698 9.98399-25.186974a36.429962 36.429962 0 0 1 50.372947 0l169.98382 167.423824L763.389735 330.220732a37.059961 37.059961 0 0 1 50.371947-1.732998 33.647965 33.647965 0 0 1 11.165988 25.186973 35.544963 35.544963 0 0 1-9.98399 24.575974v-0.04z m0 0"
@@ -42,9 +42,9 @@
p-id="11360"
></path>
</svg>
- <p class="okText">{{_packageCode}} 銆恵{qiTaoReuslt}}銆戯紒</p>
+ <p class="okText">銆恵{qiTaoReuslt}}銆戯紒</p>
</div>
- <div class="" v-show="isSuccess == '鎴愬姛' && qiTaoReuslt=='涓嶉綈濂�' ">
+ <div class="" v-show="isSuccess == '鎴愬姛' && isNewOrder ">
<svg t="1732842594517" class="icon" viewBox="0 0 1024 1024" version="1.1" xmlns="http://www.w3.org/2000/svg" p-id="4303" width="100" height="100">
<path
d="M549.044706 512l166.189176-166.249412a26.383059 26.383059 0 0 0 0-36.98447 26.383059 26.383059 0 0 0-37.044706 0L512 475.015529l-166.249412-166.249411a26.383059 26.383059 0 0 0-36.98447 0 26.383059 26.383059 0 0 0 0 37.044706L475.015529 512l-166.249411 166.249412a26.383059 26.383059 0 0 0 0 36.98447 26.383059 26.383059 0 0 0 37.044706 0L512 548.984471l166.249412 166.249411a26.383059 26.383059 0 0 0 36.98447 0 26.383059 26.383059 0 0 0 0-37.044706L548.984471 512zM512 1024a512 512 0 1 1 0-1024 512 512 0 0 1 0 1024z"
@@ -52,7 +52,7 @@
p-id="4304"
></path>
</svg>
- <p class="no_okText">{{_packageCode}} 銆恵{qiTaoReuslt}}銆戯紒</p>
+ <p class="no_okText">銆恵{qiTaoReuslt}}銆戯紒</p>
</div>
<div class="" v-show="isSuccess && isSuccess != '鎴愬姛'">
<svg t="1732842594517" class="icon" viewBox="0 0 1024 1024" version="1.1" xmlns="http://www.w3.org/2000/svg" p-id="4303" width="100" height="100">
@@ -66,7 +66,14 @@
</div>
</div>
<ul>
-
+ <li>
+ <span class="text_left">鍖呰缂栧彿:</span>
+ <span class="text_rt">{{ tableData.packageCode }}</span>
+ </li>
+ <li>
+ <span class="text_left">鐢熶骇鍗曞彿:</span>
+ <span class="text_rt">{{ tableData.info5 }}</span>
+ </li>
<li>
<span class="text_left">鎵规鍙�:</span>
<span class="text_rt">{{ tableData.planNo }}</span>
@@ -91,10 +98,6 @@
<li>
<span class="text_left">閿�鍞悎鍚屽崟鍙�:</span>
<span class="text_rt">{{ tableData.info4 }}</span>
- </li>
- <li>
- <span class="text_left">绗嚑鍖�:</span>
- <span class="text_rt">{{ tableData.info6 }}</span>
</li>
<li>
<span class="text_left">浜у搧鍚嶇О:</span>
@@ -223,6 +226,7 @@
//=======================end榧犳爣瀹氫綅 鐢ㄤ簬寮曠敤杈撳叆妗�=====================
const isSuccess = ref('');
const qiTaoReuslt = ref('');
+const isNewOrder = ref('');
const _packageCode = ref('');
// 鏌ヨ鎿嶄綔 888888888
const handleQuery = async () => {
@@ -243,6 +247,7 @@
tableData.value ={};
isSuccess.value ='';
qiTaoReuslt.value ='' ;
+ isNewOrder.value ='';
};
function handleResponse(res: any) {
tableData.value = res.data.result ?? {};
@@ -251,16 +256,19 @@
if (res.data.code == 200) {
isSuccess.value = '鎴愬姛';
qiTaoReuslt.value = res.data.result ? res.data.result.qiTaoReuslt : '';
+ isNewOrder.value = res.data.result ? res.data.result.isNewOrder : '';
//qiTaoReuslt.value ='榻愬';// 妯℃嫙
} else if (res.data.code == 400) {
loading.value = false;
isSuccess.value = res.data.message || '鏈煡璇㈠埌鏁版嵁';
qiTaoReuslt.value ='' ;
+ isNewOrder.value ='' ;
return;
} else {
loading.value = false;
isSuccess.value = '';
qiTaoReuslt.value ='' ;
+ isNewOrder.value ='' ;
ElMessage.warning('缃戠粶寮傚父 璇锋眰澶辫触');
return;
}
diff --git a/LA24030_LuLiPackageLine_Wms/Admin.NET.Application/Connected Services/CCWcfService/ConnectedService.json b/LA24030_LuLiPackageLine_Wms/Admin.NET.Application/Connected Services/CCWcfService/ConnectedService.json
index 3deff86..4a1ac5e 100644
--- a/LA24030_LuLiPackageLine_Wms/Admin.NET.Application/Connected Services/CCWcfService/ConnectedService.json
+++ b/LA24030_LuLiPackageLine_Wms/Admin.NET.Application/Connected Services/CCWcfService/ConnectedService.json
@@ -29,11 +29,11 @@
"BouncyCastle.Cryptography, {BouncyCastle.Cryptography, 2.3.0}",
"COSXML, {Tencent.QCloud.Cos.Sdk, 5.4.32}",
"Crc32.NET, {Crc32.NET, 1.2.0}",
- "D:\\code\\LA24030-LuLI_PackageLine\\LA24030_LuLiPackageLine_Wms\\Admin.NET.Application\\bin\\Debug\\net6.0\\Admin.NET.Core.dll",
- "D:\\code\\LA24030-LuLI_PackageLine\\LA24030_LuLiPackageLine_Wms\\Admin.NET.Application\\bin\\Debug\\net6.0\\Admin.NET.Plugin.ApprovalFlow.dll",
- "D:\\code\\LA24030-LuLI_PackageLine\\LA24030_LuLiPackageLine_Wms\\Admin.NET.Application\\bin\\Debug\\net6.0\\Admin.NET.Plugin.DingTalk.dll",
- "D:\\code\\LA24030-LuLI_PackageLine\\LA24030_LuLiPackageLine_Wms\\Admin.NET.Application\\bin\\Debug\\net6.0\\Admin.NET.Plugin.GoView.dll",
- "D:\\code\\LA24030-LuLI_PackageLine\\LA24030_LuLiPackageLine_Wms\\Admin.NET.Application\\bin\\Debug\\net6.0\\Admin.NET.Plugin.ReZero.dll",
+ "D:\\code\\LA24030-LuLI_PackageLine\\LA24030_LuLiPackageLine_Wms\\Admin.NET.Application\\bin\\Release\\net6.0\\Admin.NET.Core.dll",
+ "D:\\code\\LA24030-LuLI_PackageLine\\LA24030_LuLiPackageLine_Wms\\Admin.NET.Application\\bin\\Release\\net6.0\\Admin.NET.Plugin.ApprovalFlow.dll",
+ "D:\\code\\LA24030-LuLI_PackageLine\\LA24030_LuLiPackageLine_Wms\\Admin.NET.Application\\bin\\Release\\net6.0\\Admin.NET.Plugin.DingTalk.dll",
+ "D:\\code\\LA24030-LuLI_PackageLine\\LA24030_LuLiPackageLine_Wms\\Admin.NET.Application\\bin\\Release\\net6.0\\Admin.NET.Plugin.GoView.dll",
+ "D:\\code\\LA24030-LuLI_PackageLine\\LA24030_LuLiPackageLine_Wms\\Admin.NET.Application\\bin\\Release\\net6.0\\Admin.NET.Plugin.ReZero.dll",
"DmProvider, {SqlSugarCore.Dm, 1.3.0}",
"DocumentFormat.OpenXml, {DocumentFormat.OpenXml, 2.7.2}",
"DynamicExpresso.Core, {DynamicExpresso.Core, 2.3.3}",
diff --git a/LA24030_LuLiPackageLine_Wms/Admin.NET.Application/Connected Services/CCWcfService/Reference.cs b/LA24030_LuLiPackageLine_Wms/Admin.NET.Application/Connected Services/CCWcfService/Reference.cs
index 41bdf04..fb5fe09 100644
--- a/LA24030_LuLiPackageLine_Wms/Admin.NET.Application/Connected Services/CCWcfService/Reference.cs
+++ b/LA24030_LuLiPackageLine_Wms/Admin.NET.Application/Connected Services/CCWcfService/Reference.cs
@@ -80,6 +80,9 @@
[System.ServiceModel.OperationContractAttribute(Action="http://tempuri.org/ICCWcfService/WriteStation_PartClear", ReplyAction="http://tempuri.org/ICCWcfService/WriteStation_PartClearResponse")]
System.Threading.Tasks.Task<CCWcfService.FunRetEntity> WriteStation_PartClearAsync();
+
+ [System.ServiceModel.OperationContractAttribute(Action="http://tempuri.org/ICCWcfService/WriteQiTaoInfo", ReplyAction="http://tempuri.org/ICCWcfService/WriteQiTaoInfoResponse")]
+ System.Threading.Tasks.Task<CCWcfService.FunRetEntity> WriteQiTaoInfoAsync(bool iscomplete);
}
[System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.Tools.ServiceModel.Svcutil", "2.1.0")]
@@ -152,6 +155,11 @@
return base.Channel.WriteStation_PartClearAsync();
}
+ public System.Threading.Tasks.Task<CCWcfService.FunRetEntity> WriteQiTaoInfoAsync(bool iscomplete)
+ {
+ return base.Channel.WriteQiTaoInfoAsync(iscomplete);
+ }
+
public virtual System.Threading.Tasks.Task OpenAsync()
{
return System.Threading.Tasks.Task.Factory.FromAsync(((System.ServiceModel.ICommunicationObject)(this)).BeginOpen(null, null), new System.Action<System.IAsyncResult>(((System.ServiceModel.ICommunicationObject)(this)).EndOpen));
diff --git a/LA24030_LuLiPackageLine_Wms/Admin.NET.Application/Entity/WmsOrder/Mes_Package_UnLine_Record.cs b/LA24030_LuLiPackageLine_Wms/Admin.NET.Application/Entity/WmsOrder/Mes_Package_UnLine_Record.cs
index f0e7655..fade219 100644
--- a/LA24030_LuLiPackageLine_Wms/Admin.NET.Application/Entity/WmsOrder/Mes_Package_UnLine_Record.cs
+++ b/LA24030_LuLiPackageLine_Wms/Admin.NET.Application/Entity/WmsOrder/Mes_Package_UnLine_Record.cs
@@ -24,6 +24,18 @@
public UpiFlagEnum? UpiFlag { get; set; } = UpiFlagEnum.姝e父;
/// <summary>
+ /// 涓嬬嚎浣嶇疆(BZ-33 BZ-32)
+ /// </summary>
+ [SugarColumn(ColumnName = "Location", ColumnDescription = "涓嬬嚎浣嶇疆", Length = 50)]
+ public string? Location { get; set; }
+
+ [SugarColumn(ColumnName = "AllPackageNum", ColumnDescription = "鎬诲寘鏁�")]
+ public int AllPackageNum { get; set; }
+
+ [SugarColumn(ColumnName = "CurUnlineIndexPackageNum", ColumnDescription = "褰撳墠绗嚑鍖呬笅绾�")]
+ public int CurUnlineIndexPackageNum { get; set; }
+
+ /// <summary>
/// 鐢熶骇鍗曞彿
/// </summary>
[SugarColumn(ColumnName = "Info5", ColumnDescription = "鐢熶骇鍗曞彿", Length = 60)]
diff --git a/LA24030_LuLiPackageLine_Wms/Admin.NET.Application/Service/ReportCenter/Mes_Package_UnLine_Record/Dto/Mes_Package_UnLine_RecordInput.cs b/LA24030_LuLiPackageLine_Wms/Admin.NET.Application/Service/ReportCenter/Mes_Package_UnLine_Record/Dto/Mes_Package_UnLine_RecordInput.cs
index 0f7c651..71b86e1 100644
--- a/LA24030_LuLiPackageLine_Wms/Admin.NET.Application/Service/ReportCenter/Mes_Package_UnLine_Record/Dto/Mes_Package_UnLine_RecordInput.cs
+++ b/LA24030_LuLiPackageLine_Wms/Admin.NET.Application/Service/ReportCenter/Mes_Package_UnLine_Record/Dto/Mes_Package_UnLine_RecordInput.cs
@@ -19,6 +19,21 @@
public virtual Admin.NET.Application.UpiFlagEnum? UpiFlag { get; set; }
/// <summary>
+ /// 涓嬬嚎浣嶇疆
+ /// </summary>
+ public virtual string Location { get; set; }
+
+ /// <summary>
+ /// 鎬诲寘鏁�
+ /// </summary>
+ public virtual int AllPackageNum { get; set; }
+
+ /// <summary>
+ /// 褰撳墠绗嚑鍖呬笅绾�
+ /// </summary>
+ public virtual int CurUnlineIndexPackageNum { get; set; }
+
+ /// <summary>
/// 鐢熶骇鍗曞彿
/// </summary>
public virtual string Info5 { get; set; }
@@ -151,6 +166,21 @@
public Admin.NET.Application.UpiFlagEnum? UpiFlag { get; set; }
/// <summary>
+ /// 涓嬬嚎浣嶇疆
+ /// </summary>
+ public string? Location { get; set; }
+
+ /// <summary>
+ /// 鎬诲寘鏁�
+ /// </summary>
+ public int? AllPackageNum { get; set; }
+
+ /// <summary>
+ /// 褰撳墠绗嚑鍖呬笅绾�
+ /// </summary>
+ public int? CurUnlineIndexPackageNum { get; set; }
+
+ /// <summary>
/// 鐢熶骇鍗曞彿
/// </summary>
public string? Info5 { get; set; }
@@ -234,6 +264,15 @@
/// 鍒涘缓鏃堕棿鑼冨洿
/// </summary>
public List<DateTime?> CreateTimeRange { get; set; }
+ /// <summary>
+ /// 淇敼鏃堕棿
+ /// </summary>
+ public DateTime? UpdateTime { get; set; }
+
+ /// <summary>
+ /// 淇敼鏃堕棿鑼冨洿
+ /// </summary>
+ public List<DateTime?> UpdateTimeRange { get; set; }
}
/// <summary>
@@ -248,6 +287,18 @@
public override string PackageCode { get; set; }
/// <summary>
+ /// 鎬诲寘鏁�
+ /// </summary>
+ [Required(ErrorMessage = "鎬诲寘鏁颁笉鑳戒负绌�")]
+ public override int AllPackageNum { get; set; }
+
+ /// <summary>
+ /// 褰撳墠绗嚑鍖呬笅绾�
+ /// </summary>
+ [Required(ErrorMessage = "褰撳墠绗嚑鍖呬笅绾夸笉鑳戒负绌�")]
+ public override int CurUnlineIndexPackageNum { get; set; }
+
+ /// <summary>
/// 鎵规鍙�
/// </summary>
[Required(ErrorMessage = "鎵规鍙蜂笉鑳戒负绌�")]
diff --git a/LA24030_LuLiPackageLine_Wms/Admin.NET.Application/Service/ReportCenter/Mes_Package_UnLine_Record/Dto/Mes_Package_UnLine_RecordOutput.cs b/LA24030_LuLiPackageLine_Wms/Admin.NET.Application/Service/ReportCenter/Mes_Package_UnLine_Record/Dto/Mes_Package_UnLine_RecordOutput.cs
index 997a3fe..3b1306b 100644
--- a/LA24030_LuLiPackageLine_Wms/Admin.NET.Application/Service/ReportCenter/Mes_Package_UnLine_Record/Dto/Mes_Package_UnLine_RecordOutput.cs
+++ b/LA24030_LuLiPackageLine_Wms/Admin.NET.Application/Service/ReportCenter/Mes_Package_UnLine_Record/Dto/Mes_Package_UnLine_RecordOutput.cs
@@ -21,6 +21,21 @@
public Admin.NET.Application.UpiFlagEnum? UpiFlag { get; set; }
/// <summary>
+ /// 涓嬬嚎浣嶇疆
+ /// </summary>
+ public string Location { get; set; }
+
+ /// <summary>
+ /// 鎬诲寘鏁�
+ /// </summary>
+ public int AllPackageNum { get; set; }
+
+ /// <summary>
+ /// 褰撳墠绗嚑鍖呬笅绾�
+ /// </summary>
+ public int CurUnlineIndexPackageNum { get; set; }
+
+ /// <summary>
/// 鐢熶骇鍗曞彿
/// </summary>
public string Info5 { get; set; }
diff --git a/LA24030_LuLiPackageLine_Wms/Admin.NET.Application/Service/ReportCenter/Mes_Package_UnLine_Record/Mes_Package_UnLine_RecordService.cs b/LA24030_LuLiPackageLine_Wms/Admin.NET.Application/Service/ReportCenter/Mes_Package_UnLine_Record/Mes_Package_UnLine_RecordService.cs
index 5314e09..a3f7f17 100644
--- a/LA24030_LuLiPackageLine_Wms/Admin.NET.Application/Service/ReportCenter/Mes_Package_UnLine_Record/Mes_Package_UnLine_RecordService.cs
+++ b/LA24030_LuLiPackageLine_Wms/Admin.NET.Application/Service/ReportCenter/Mes_Package_UnLine_Record/Mes_Package_UnLine_RecordService.cs
@@ -127,6 +127,7 @@
var query = _rep.AsQueryable()
.WhereIF(!string.IsNullOrWhiteSpace(input.SearchKey), u =>
u.PackageCode.Contains(input.SearchKey.Trim())
+ || u.Location.Contains(input.SearchKey.Trim())
|| u.Info5.Contains(input.SearchKey.Trim())
|| u.PlanNo.Contains(input.SearchKey.Trim())
|| u.OrderId.Contains(input.SearchKey.Trim())
@@ -144,6 +145,9 @@
)
.WhereIF(!string.IsNullOrWhiteSpace(input.PackageCode), u => u.PackageCode.Contains(input.PackageCode.Trim()))
.WhereIF(input.UpiFlag.HasValue, u => u.UpiFlag == input.UpiFlag)
+ .WhereIF(!string.IsNullOrWhiteSpace(input.Location), u => u.Location.Contains(input.Location.Trim()))
+ .WhereIF(input.AllPackageNum>0, u => u.AllPackageNum == input.AllPackageNum)
+ .WhereIF(input.CurUnlineIndexPackageNum>0, u => u.CurUnlineIndexPackageNum == input.CurUnlineIndexPackageNum)
.WhereIF(!string.IsNullOrWhiteSpace(input.Info5), u => u.Info5.Contains(input.Info5.Trim()))
.WhereIF(!string.IsNullOrWhiteSpace(input.PlanNo), u => u.PlanNo.Contains(input.PlanNo.Trim()))
.WhereIF(!string.IsNullOrWhiteSpace(input.OrderId), u => u.OrderId.Contains(input.OrderId.Trim()))
@@ -167,6 +171,16 @@
query = query.Where(u => u.CreateTime <= end);
}
}
+ if(input.UpdateTimeRange != null && input.UpdateTimeRange.Count >0)
+ {
+ DateTime? start= input.UpdateTimeRange[0].Value;
+ query = query.WhereIF(start.HasValue, u => u.UpdateTime >= start);
+ if (input.UpdateTimeRange.Count >1 && input.UpdateTimeRange[1].HasValue)
+ {
+ var end = input.UpdateTimeRange[1].Value;
+ query = query.Where(u => u.UpdateTime <= end);
+ }
+ }
return query;
}
diff --git a/LA24030_LuLiPackageLine_Wms/Admin.NET.Application/Service/WmsOperationTask/Dto/ValidateQiTaoOutput.cs b/LA24030_LuLiPackageLine_Wms/Admin.NET.Application/Service/WmsOperationTask/Dto/ValidateQiTaoOutput.cs
index 76a9bfc..8fb01f0 100644
--- a/LA24030_LuLiPackageLine_Wms/Admin.NET.Application/Service/WmsOperationTask/Dto/ValidateQiTaoOutput.cs
+++ b/LA24030_LuLiPackageLine_Wms/Admin.NET.Application/Service/WmsOperationTask/Dto/ValidateQiTaoOutput.cs
@@ -11,6 +11,12 @@
{
/// <summary>
+ /// 鏄惁鏄柊璁㈠崟
+ /// </summary>
+ public virtual bool IsNewOrder { get; set; }
+
+
+ /// <summary>
/// 榻愬缁撴灉
/// </summary>
public virtual string QiTaoReuslt { get; set; }
diff --git a/LA24030_LuLiPackageLine_Wms/Admin.NET.Application/Service/WmsOperationTask/WmsOperationTaskService.cs b/LA24030_LuLiPackageLine_Wms/Admin.NET.Application/Service/WmsOperationTask/WmsOperationTaskService.cs
index 05fade2..66c1fd6 100644
--- a/LA24030_LuLiPackageLine_Wms/Admin.NET.Application/Service/WmsOperationTask/WmsOperationTaskService.cs
+++ b/LA24030_LuLiPackageLine_Wms/Admin.NET.Application/Service/WmsOperationTask/WmsOperationTaskService.cs
@@ -29,6 +29,7 @@
private readonly SqlSugarRepository<Mes_Upi_LineQueue> _mes_Upi_LineQueueRep;
private readonly SqlSugarRepository<Mes_Package_LineQueue> _mes_Package_LineQueueRep;
private readonly SqlSugarRepository<WmsRecordUpiNg> _wmsRecordUpiNgRep;
+ private readonly SqlSugarRepository<Mes_Package_UnLine_Record> _mes_Package_UnLine_RecordRep;
private readonly WmsCommonnQueryService _wmsCommonnQueryService;
public WmsOperationTaskService(
@@ -43,6 +44,7 @@
, SqlSugarRepository<WmsRecordUpiNg> wmsRecordUpiNgRep
, WmsCommonnQueryService wmsCommonnQueryService
, SqlSugarRepository<Mes_Package_LineQueue> mes_Package_LineQueueRep
+ , SqlSugarRepository<Mes_Package_UnLine_Record> mes_Package_UnLine_RecordRep
)
{
_mes_Package_LineQueueRep = mes_Package_LineQueueRep;
@@ -57,6 +59,7 @@
_wmsRecordUpiProcessRep = wmsRecordUpiProcessRep;
_wmsRecordPackageProcessRep = wmsRecordPackageProcessRep;
_mes_Upi_LineQueueRep = mes_Upi_LineQueueRep;
+ _mes_Package_UnLine_RecordRep = mes_Package_UnLine_RecordRep;
}
@@ -216,7 +219,7 @@
}
/// <summary>
- /// 鍒ゆ柇榻愬
+ /// 涓嬬嚎鏀捐
/// </summary>
/// <param name="input"></param>
/// <returns></returns>
@@ -238,81 +241,55 @@
throw Oops.Oh($"娌℃湁鎵惧埌鍖呭彿{input.PackageCode}鐨勬眹鎬绘暟鎹�");
}
-
-
- var sysConfig = await _sysConfigRep.GetFirstAsync(x => x.Code == CommonConst.WmsBZ30_QiTao);
- if (sysConfig == null)
+ if (package.UpiStatus == UpiStatusEnum.宸蹭笅绾�)
{
- throw Oops.Oh($"娌℃湁閰嶇疆 鍒ゆ柇榻愬 鍊�");
- }
- if (!string.IsNullOrEmpty(sysConfig.Value) && sysConfig.Value.Trim() != "鏃�")
- {
- throw Oops.Oh($"鍒ゆ柇榻愬鍊煎凡缁忓瓨鍦ㄥ�納sysConfig.Value},涓嶅厑璁告搷浣�");
+ throw Oops.Oh($"鍖厈input.PackageCode}宸蹭笅绾�");
}
- //璁板綍宸ヤ綔鏃堕棿鍜屽伐浣滀汉
- var curUserName = App.User.FindFirst(ClaimConst.RealName)?.Value;
+ var unlineObj = await _mes_Package_UnLine_RecordRep.AsQueryable().Where(x => x.PackageCode == input.PackageCode).FirstAsync();
+ if (unlineObj != null)
+ {
+ throw Oops.Oh($"鍖呭彿{input.PackageCode}宸茬粡涓嬬嚎");
+ }
- var setValue = "";
+ //鍒ゆ柇鏄惁鏄柊鐢熶骇璁㈠崟
var _QiTaoReuslt = "";
-
- bool isNeedQueryQiTao = true;
- var order = await _mesOrderGatherRep.AsQueryable().Where(x => x.Info5 == package.Info5).FirstAsync();
- if (order == null)
- {
-
+ bool isNewOrder = false;
+ string _location = "BZ-33";
+ var lastPackageUnline = await _mes_Package_UnLine_RecordRep.AsQueryable().Where(x => x.UpiFlag == UpiFlagEnum.姝e父).OrderByDescending(x => x.Id).FirstAsync();
+ if (lastPackageUnline == null)
+ {//璁や负鏄柊鐢熶骇璁㈠崟
+ isNewOrder = true;
}
else
{
- if (order.IsKitting != null)
- {
- _QiTaoReuslt = (bool)order.IsKitting ? "榻愬" : "涓嶉綈濂�";
- isNeedQueryQiTao = false;
- }
- }
- if (isNeedQueryQiTao)
- {
- var other_orderList = await _mesPackageGatherRep.AsQueryable().Where(x => x.Info5 == package.Info5 && x.PackageCode != input.PackageCode).ToListAsync();
- var num = other_orderList.Where(x => x.UpiStatus == UpiStatusEnum.鍒濆).Count();
- if (num > 0)
- {
- //涓嶉綈濂�
- _QiTaoReuslt = "涓嶉綈濂�";
+ if (lastPackageUnline.Info5 != package.Info5)
+ {//璁や负鏄柊鐢熶骇璁㈠崟
+ isNewOrder = true;
+ if (lastPackageUnline.Location == "BZ-33")
+ {
+ _location = "BZ-32";
+ }
+ else
+ {
+ _location = "BZ-33";
+ }
}
else
{
- _QiTaoReuslt = "榻愬";
+ _location = lastPackageUnline.Location;
}
}
- setValue = $"{input.PackageCode}|{_QiTaoReuslt}|" + curUserName;
-
- if (package.UpiStatus == UpiStatusEnum.宸蹭笅绾�)
- {
- throw Oops.Oh($"鍖呭凡涓嬬嚎,榻愬缁撴灉[{_QiTaoReuslt}]");
+ if (string.IsNullOrEmpty(_location))
+ {//榛樿
+ _location = "BZ-33";
}
- if (order == null)
- {
- Mes_Order_Gather newOrder = new Mes_Order_Gather()
- {
- Info5 = package.Info5,
- IsKitting = _QiTaoReuslt == "榻愬" ? true : false,
- PlanNo = package.PlanNo,
- OrderId = package.OrderId
- };
- await _mesOrderGatherRep.InsertAsync(newOrder);
- }
- else
- {
- order.IsKitting = _QiTaoReuslt == "榻愬" ? true : false;
- await _mesOrderGatherRep.UpdateAsync(order);
- }
+ _QiTaoReuslt = (bool)isNewOrder ? "鏂拌鍗�" : "褰撳墠璁㈠崟";
- sysConfig.Value = setValue;
- await _sysConfigRep.UpdateAsync(sysConfig);
- //*/
-
+ //璁板綍宸ヤ綔鏃堕棿鍜屽伐浣滀汉
+ var curUserName = App.User.FindFirst(ClaimConst.RealName)?.Value;
var sysConfig_wms_unline_oper = await _sysConfigRep.GetFirstAsync(x => x.Code == CommonConst.wms_unline_oper);
if (sysConfig_wms_unline_oper == null)
@@ -334,8 +311,78 @@
}
+
+ //璇锋眰PLC
+ //鍒ゆ柇鏂瑰悜
+ bool myLocation = false;
+ if (_location == "BZ-33")
+ {
+ myLocation = false;
+ }
+ else
+ {
+ myLocation = true;
+ }
+ var client = await WCFServiceHelper.GetWCFService_SAPCC_Client(_sysConfigRep);
+ var res = await client.WriteQiTaoInfoAsync(myLocation);
+ if (res.result == false)
+ {
+ throw Oops.Oh(res.resMsg);
+ }
+
+
+ //鏇存柊鏁版嵁
+ package.UpiStatus = UpiStatusEnum.宸蹭笅绾�;
+ package.AreaCode = AreaCodeEnum.涓嬬嚎鍖哄煙;
+ await _mesPackageGatherRep.UpdateAsync(package);
+
+ var upiList = await _mesBatchOrderUpiRep.AsQueryable().Where(x => x.PackageCode == input.PackageCode).ToListAsync();
+ foreach (var item in upiList)
+ {
+ item.UpiStatus = UpiStatusEnum.宸蹭笅绾�;
+ item.AreaCode = AreaCodeEnum.涓嬬嚎鍖哄煙;
+ item.UpdateTime = DateTime.Now;
+ }
+ await _mesBatchOrderUpiRep.UpdateRangeAsync(upiList);
+ //鍒犻櫎闃熷垪淇℃伅
+ var lineQueue = await _mes_Package_LineQueueRep.AsQueryable().Where(x => x.PackageCode == input.PackageCode).FirstAsync();
+ if (lineQueue != null)
+ {
+ await _mes_Package_LineQueueRep.DeleteAsync(lineQueue);
+ }
+ //澶勭悊琛� mes_order_gather
+ await UpdateOrderGather(package, false);
+
+ var _cretaorName = App.User.FindFirst(ClaimConst.RealName)?.Value;
+
+ //鏂板涓嬬嚎璁板綍琛�
+ var all_upiList = await _mesBatchOrderUpiRep.AsQueryable().Where(x => x.Info5 == package.Info5).ToListAsync();
+ var all_unlineList = await _mes_Package_UnLine_RecordRep.AsQueryable().Where(x => x.Info5 == package.Info5).ToListAsync();
+ Mes_Package_UnLine_Record record = new Mes_Package_UnLine_Record();
+ record = package.Adapt<Mes_Package_UnLine_Record>();
+ record.Id = Yitter.IdGenerator.YitIdHelper.NextId();
+ record.Location = _location;
+ record.AllPackageNum = all_upiList.GroupBy(x => x.PackageCode).Count();
+ record.CurUnlineIndexPackageNum = all_unlineList.GroupBy(x => x.PackageCode).Count() + 1;
+ record.CreateTime = DateTime.Now;
+ record.CreateUserName = _cretaorName;
+ await _mes_Package_UnLine_RecordRep.InsertAsync(record);
+
+ //璁板綍鍖呭饱鍘�
+ WmsRecordPackageProcess wmsRecordPackage = new WmsRecordPackageProcess();
+ wmsRecordPackage = package.Adapt<WmsRecordPackageProcess>();
+ wmsRecordPackage.Id = Yitter.IdGenerator.YitIdHelper.NextId();
+ wmsRecordPackage.Location = "";
+ wmsRecordPackage.OperRemark = "姝e父涓嬬嚎";
+ wmsRecordPackage.CreateTime = DateTime.Now;
+ wmsRecordPackage.CreateUserName = _cretaorName;
+ await _wmsRecordPackageProcessRep.InsertAsync(wmsRecordPackage);
+
+
output = package.Adapt<ValidateQiTaoOutput>();
- output.QiTaoReuslt = _QiTaoReuslt;
+ output.QiTaoReuslt = _QiTaoReuslt + $",绗瑊record.CurUnlineIndexPackageNum}鍖呬笅绾�,鍏眥record.AllPackageNum}鍖�";
+ output.IsNewOrder = isNewOrder;
+ //output.IsNewOrder = false;
return output;
}
@@ -518,7 +565,7 @@
}
/// <summary>
- /// 涓嬬嚎鏇存柊 璁㈠崟琛ㄦ暟鎹�
+ /// 鍏叡-涓嬬嚎鏇存柊 璁㈠崟琛ㄦ暟鎹�
/// </summary>
/// <param name="singlePackage"></param>
/// <returns></returns>
--
Gitblit v1.9.3