From f7d36a3dd47e06bf76863179af1d76bd0e23054f Mon Sep 17 00:00:00 2001 From: lss <Lss@HanInfo> Date: 星期一, 19 五月 2025 10:25:17 +0800 Subject: [PATCH] s7协议S7200Smart开发,接口字段更新 --- HH.WCS.Mobox3/HH.WCS.Mobox3.JiaTong/api/ApiHelper.cs | 32 ++++++++++++++++++++++++++++++-- 1 files changed, 30 insertions(+), 2 deletions(-) diff --git a/HH.WCS.Mobox3/HH.WCS.Mobox3.JiaTong/api/ApiHelper.cs b/HH.WCS.Mobox3/HH.WCS.Mobox3.JiaTong/api/ApiHelper.cs index c9ea9be..1e6dc8f 100644 --- a/HH.WCS.Mobox3/HH.WCS.Mobox3.JiaTong/api/ApiHelper.cs +++ b/HH.WCS.Mobox3/HH.WCS.Mobox3.JiaTong/api/ApiHelper.cs @@ -153,7 +153,7 @@ AddErrorInfo("璐т綅鏌ユ壘澶辫触", result.msg); } } - else if (taskData.taskType == 2)//鍏ュ簱娴佺▼锛岀洿鎺ヤ娇鐢ㄨ捣鐐硅揣浣嶅拰缁堢偣璐т綅鐢熸垚浠诲姟 + else if (taskData.taskType == 2)//鍏ュ簱娴佺▼锛岀洿鎺ヤ娇鐢ㄨ捣鐐硅揣浣嶅拰缁堢偣璐т綅鐢熸垚浠诲姟锛岃捣鐐归渶瑕佹湁鎵樼洏 { startloc = db.Queryable<Location>().Where(a => a.S_CODE.Trim() == taskData.pickStation).First(); if (startloc != null) @@ -433,6 +433,34 @@ return result; } } + else if (taskData.taskType == 8)//鍙犵洏鏈虹┖鎵樺洖搴�+ { + note = "绌烘墭鍥炲簱";//浜曟澗绌烘墭鍥炲簱锛岄渶瑕佷笌鍙犵洏鏈哄畨鍏ㄤ氦浜�+ startloc = db.Queryable<Location>().Where(a => a.S_CODE.Trim() == taskData.pickStation).First(); + if (startloc != null) + { + Start = startloc.S_CODE; + } + else + { + result.code = "1"; + result.msg = $"鏍规嵁璧风偣:{taskData.pickStation},鎵句笉鍒板搴旇揣浣嶏紝璇锋鏌ヨ揣浣嶈〃"; + AddErrorInfo("璐т綅鏌ユ壘澶辫触", result.msg); + return result; + } + endloc = db.Queryable<Location>().Where(a => a.S_CODE.Trim() == taskData.dropStation).First(); + if (endloc != null) + { + End = taskData.dropStation; + } + else + { + result.code = "1"; + result.msg = $"鏍规嵁缁堢偣:{End},鎵句笉鍒板搴旇揣浣嶏紝璇锋鏌ヨ揣浣嶈〃"; + AddErrorInfo("璐т綅鏌ユ壘澶辫触", result.msg); + return result; + } + } else { LogHelper.Info($"Createtask==> 浠诲姟绫诲瀷鏈夎"); @@ -629,7 +657,7 @@ try { //鍒涘缓鎵樼洏鏁版嵁缁戝畾鍏崇郴 - if (ContainerHelper.CreateCntrItem(model.Rfid, model.PartNumber, model.PartDesc, model.LotNumber, model.Weight)) + if (ContainerHelper.CreateCntrItem(model.Rfid, model.PartNumber, model.PartDesc, model.LotNumber, model.Weight,model.Qty)) { //鍒涘缓鎴愬姛娴佺▼ } -- Gitblit v1.9.1