From 23e4f986644298cb23ac43173414b7e1404b6657 Mon Sep 17 00:00:00 2001
From: dengjunjie <dengjunjie@hnkhzn.com>
Date: 星期六, 15 六月 2024 17:26:23 +0800
Subject: [PATCH] 任务逻辑优化
---
代码管理/WMS/WMS_Server/WIDESEA_WMS/Services/system/Partial/dt_stationinfoService.cs | 8 +++-----
1 files changed, 3 insertions(+), 5 deletions(-)
diff --git "a/\344\273\243\347\240\201\347\256\241\347\220\206/WMS/WMS_Server/WIDESEA_WMS/Services/system/Partial/dt_stationinfoService.cs" "b/\344\273\243\347\240\201\347\256\241\347\220\206/WMS/WMS_Server/WIDESEA_WMS/Services/system/Partial/dt_stationinfoService.cs"
index fdd7795..befac78 100644
--- "a/\344\273\243\347\240\201\347\256\241\347\220\206/WMS/WMS_Server/WIDESEA_WMS/Services/system/Partial/dt_stationinfoService.cs"
+++ "b/\344\273\243\347\240\201\347\256\241\347\220\206/WMS/WMS_Server/WIDESEA_WMS/Services/system/Partial/dt_stationinfoService.cs"
@@ -112,13 +112,11 @@
VOLContext context = new VOLContext();
Idt_agvtaskRepository agvtaskRepository = new dt_agvtaskRepository(context);
IVV_Mes_WorkinfoRepository workinfoRepository = new VV_Mes_WorkinfoRepository(context);
- string json = string.Empty;
foreach (var Key in saveModel.DelKeys)
{
try
{
var station = repository.Find(x => x.id.ToString() == Key.ToString()).FirstOrDefault();
- json = json + station.stationCode + ",";
if (!station.stationCode.Contains("X") && !station.stationCode.Contains("W01001004") && !station.stationCode.Contains("W01001005")) throw new Exception($"鏃爗station.stationCode}浣跨敤鏉冮檺锛�");
if (!station.enable) throw new Exception($"{station.stationCode}鏈惎鐢紒");
if (station.location_state == LocationStateEnum.Abnormal.ToString()) throw new Exception($"{station.stationCode}鐘舵�佸紓甯革紒");
@@ -217,7 +215,7 @@
Idt_agvtaskRepository agvtaskRepository = new dt_agvtaskRepository(context);
IVV_Mes_WorkinfoRepository workinfoRepository = new VV_Mes_WorkinfoRepository(context);
string completor = UserContext.Current.UserName;
- object json = null;
+ //List<object> jsons = null;
foreach (var Key in saveModel.DelKeys)
{
try
@@ -257,7 +255,7 @@
jobID = station.Number,
agv_TrayStatus = station.tray_status
};
- json = agvtask;
+ //jsons.Add(agvtask);
agvtaskRepository.Add(agvtask, true);
station.location_state = LocationStateEnum.InBusy.ToString();
repository.Update(station, x => new { x.location_state }, true);
@@ -268,7 +266,7 @@
webResponse.Error(webResponse.Message += ex.Message);
}
}
- WriteDBLog.Write($"鎵嬪姩涓嬫枡浠诲姟 ", new { 淇℃伅 = webResponse.Message, 鏁版嵁 = json }, LogState.Sucess, "WMS", completor);
+ WriteDBLog.Write($"鎵嬪姩涓嬫枡浠诲姟 ", new { 淇℃伅 = webResponse.Message }, LogState.Sucess, "WMS", completor);
return webResponse;
}
--
Gitblit v1.9.3