心跳、读缓存调整

This commit is contained in:
2024-07-25 14:59:44 +08:00
parent 65eed56fad
commit 201293b82f
4 changed files with 92 additions and 56 deletions

View File

@@ -800,7 +800,7 @@ namespace Tnb.WarehouseMgr
string data = await _redisData.GetHash(strs[0], strs[1]);
Logger.Information("wcs请求CheckPut接口查询X2Server数据:" + data);
JObject? res = JsonConvert.DeserializeObject<JObject>(data);
bool result = res != null && res["Value"] != null ? res.Value<bool>("Value") : false;
bool result = res != null && res["Value"] != null && res["StatusCode"].ToString() == "0" ? res.Value<bool>("Value") : false;
if (!result)
throw new AppFriendlyException("点位" + input.targetName + "不可放", 500);
Logger.Information("wcs请求CheckPut接口结果CTU可放货" + data);
@@ -921,7 +921,7 @@ namespace Tnb.WarehouseMgr
}
string data = _redisData.GetHash(strs[0], strs[1]).Result;
JObject? res = JsonConvert.DeserializeObject<JObject>(data);
bool result = res != null && res["Value"] != null ? res.Value<bool>("Value") : false;
bool result = res != null && res["Value"] != null && res["StatusCode"].ToString() == "0" ? res.Value<bool>("Value") : false;
Logger.Information($"【Check】{action} 判断KIVA是否可以取货(信号是否允许) 获取{code}的标签{strs[1]}信号值 结果为:{result} ");
if (!result)
{
@@ -943,7 +943,7 @@ namespace Tnb.WarehouseMgr
}
string data = _redisData.GetHash(strs[0], strs[1]).Result;
JObject? res = JsonConvert.DeserializeObject<JObject>(data);
bool result = res != null && res["Value"] != null ? res.Value<bool>("Value") : false;
bool result = res != null && res["Value"] != null && res["StatusCode"].ToString() == "0" ? res.Value<bool>("Value") : false;
Logger.Information($"【Check】 判断CTU是否可以放货(信号是否允许) 获取{code}的标签{strs[1]}信号值 结果为:{result}");
if (!result)
{