From 553f7744bedee0685635ed070a4a0e18b796238f Mon Sep 17 00:00:00 2001 From: lss <2538410689@qq.com> Date: 星期四, 24 七月 2025 17:30:36 +0800 Subject: [PATCH] 1111 --- HH.WCS.Mobox3/HH.WCS.Mobox3.JiaTong/api/ApiHelper.cs | 46 +++++++++++++++++++++------------------------- 1 files changed, 21 insertions(+), 25 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 68fe676..8a62d44 100644 --- a/HH.WCS.Mobox3/HH.WCS.Mobox3.JiaTong/api/ApiHelper.cs +++ b/HH.WCS.Mobox3/HH.WCS.Mobox3.JiaTong/api/ApiHelper.cs @@ -37,9 +37,9 @@ #region 浣抽�鍚堣偉鎺ュ彛涓氬姟 - - public static object _lockCreateTask = new object(); public static object _lockCreateItem = new object(); + public static object _lockCreateTask = new object(); + /// <summary> /// 绔嬪簱浠诲姟涓嬪彂=銆嬪垱寤轰换鍔� /// </summary> @@ -146,6 +146,19 @@ AddErrorInfo("瀵绘壘鍑哄簱璐т綅澶辫触", result.msg, Source); 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, Source); + // return result; + //} } else { @@ -154,6 +167,8 @@ AddErrorInfo("鍒涘缓鎵樼洏澶辫触", result.msg, Source); return result; } + + } else { @@ -213,7 +228,7 @@ } else if (taskData.taskType == 3)//绉诲簱娴佺▼锛岀洿鎺ヤ娇鐢ㄨ捣鐐硅揣浣嶅拰缁堢偣璐т綅鐢熸垚浠诲姟锛� { - note = "鍑哄簱"; + note = "鍏ュ簱"; //鍒涘缓鎵樼洏鐗╂枡缁戝畾淇℃伅锛屽苟璁$畻缁堢偣璐т綅 startloc = db.Queryable<Location>().Where(a => a.S_CODE.Trim() == taskData.pickStation).First(); if (startloc != null) @@ -832,7 +847,7 @@ type = "骞冲簱绌哄伐瑁呭懠鍙�; break; case "4": - type = "骞冲簱浣欐枡鍥炲簱"; + type = "浣欐枡杩斿洖"; break; case "5": type = "绮夋枡绌烘墭杩斿洖"; @@ -858,25 +873,7 @@ AddErrorInfo("璐т綅鏌ユ壘澶辫触", result.msg, Source); return result; } - else - { - //鍒ゆ柇璧风偣鏄惁缁戝畾鍏朵粬鎵樼洏 - var CntrRel = LocationHelper.GetLocCntrRel(startloc.S_CODE).OrderBy(a => a.T_CREATE).FirstOrDefault(); - if (CntrRel != null) - { - if (CntrRel.S_CNTR_CODE != model.Rfid) - { - result.code = "1"; - result.msg = $"鏍规嵁璧风偣锛歿model.InitialLocation}鑾峰彇鎵樼洏:{CntrRel.S_CNTR_CODE}涓庝笅鍙戞墭鐩橈細{model.Rfid}涓嶄竴鑷达紝璇锋鏌ユ墭鐩樼爜鏄惁姝g‘"; - AddErrorInfo("鎵樼洏鐮佹牎妫�け璐�, result.msg, Source); - return result; - } - } - else - { - LocationHelper.BindingLoc(startloc.S_CODE, new List<string> { model.Rfid }); - } - } + endloc = db.Queryable<Location>().Where(a => a.S_CODE.Trim() == model.TargetLocation).First(); if (endloc == null) { @@ -934,8 +931,7 @@ } } - LocationHelper.LockLoc(startloc.S_CODE, 2); - LocationHelper.LockLoc(endloc.S_CODE, 1); + LogHelper.Info("鍒涘缓浠诲姟鎴愬姛"); } else -- Gitblit v1.9.1