From 51bfc0d99c5d95ec2f5bc68ff034f8c94bb0aac6 Mon Sep 17 00:00:00 2001 From: majian <780924089@qq.com> Date: Fri, 7 Jun 2024 17:30:47 +0800 Subject: [PATCH] =?UTF-8?q?bug=E4=BF=AE=E5=A4=8D?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../Tnb.BasicData.Entities.csproj | 1 - .../Tnb.BasicData.Interfaces.csproj | 1 - BasicData/Tnb.BasicData/Tnb.BasicData.csproj | 1 - .../Tnb.EquipMgr.Entities.csproj | 1 - .../Tnb.EquipMgr.Interfaces.csproj | 1 - EquipMgr/Tnb.EquipMgr/Tnb.EquipMgr.csproj | 1 - .../Tnb.PerMgr.Entities.csproj | 1 - .../Tnb.PerMgr.Interfaces.csproj | 1 - PerMgr/Tnb.PerMgr/Tnb.PerMgr.csproj | 1 - .../Tnb.ProductionMgr.Entities.csproj | 1 - .../Tnb.ProductionMgr.Interfaces.csproj | 1 - .../Tnb.ProductionMgr/RedisBackGround.cs | 409 +++++++++--------- .../Tnb.QcMgr.Entities.csproj | 1 - .../Tnb.QcMgr.Interfaces.csproj | 1 - QcMgr/Tnb.QcMgr/Tnb.QcMgr.csproj | 1 - ...pDownMachineInput.cs => CarryBindInput.cs} | 8 +- .../Entity/WmsElevatorH.cs | 4 + .../Tnb.WarehouseMgr.Entities.csproj | 1 - .../IWmsCarryBindService.cs | 5 +- .../Tnb.WarehouseMgr.Interfaces.csproj | 1 - .../Tnb.WarehouseMgr/DevServBase`1.cs | 3 +- .../Tnb.WarehouseMgr/DeviceProviderService.cs | 11 +- .../Tnb.WarehouseMgr/Tnb.WarehouseMgr.csproj | 1 - .../Tnb.WarehouseMgr/WareHouseService.cs | 21 +- .../Tnb.WarehouseMgr/WmsCarryBindService.cs | 97 +++-- .../WmsMaterialTransferService.cs | 51 ++- apihost/Tnb.API.Entry/Program.cs | 5 +- apihost/Tnb.API.Entry/Tnb.API.Entry.csproj | 4 +- app/Tnb.Apps.Entitys/Tnb.Apps.Entitys.csproj | 1 - .../Tnb.Apps.Interfaces.csproj | 1 - app/Tnb.Apps/Tnb.Apps.csproj | 1 - .../Tnb.CollectiveOAuth.csproj | 1 - common/Tnb.Common.Core/Tnb.Common.Core.csproj | 1 - common/Tnb.Common/Redis/StackExRedisHelper.cs | 10 +- common/Tnb.Common/Tnb.Common.csproj | 1 - common/Tnb.SqlSugar/Tnb.SqlSugar.csproj | 1 - common/Tnb.Thirdparty/Tnb.Thirdparty.csproj | 1 - common/Tnb.WebSockets/Tnb.WebSockets.csproj | 1 - .../Tnb.Message.Entitys.csproj | 1 - .../Tnb.Message.Interfaces.csproj | 1 - message/Tnb.Message/Tnb.Message.csproj | 1 - system/Tnb.OAuth/Tnb.OAuth.csproj | 1 - .../Tnb.Systems.Entitys.csproj | 1 - .../Tnb.Systems.Interfaces.csproj | 1 - system/Tnb.Systems/Tnb.Systems.csproj | 1 - .../Tnb.TaskScheduler.Entitys.csproj | 1 - .../Tnb.TaskScheduler.Interfaces.csproj | 1 - .../Tnb.TaskScheduler.csproj | 1 - visualdev/Tnb.Vengine/Tnb.Vengine.csproj | 1 - .../Tnb.VisualDev.Engine.csproj | 1 - .../Tnb.VisualDev.Entitys.csproj | 1 - .../Tnb.VisualDev.Interfaces.csproj | 1 - visualdev/Tnb.VisualDev/Tnb.VisualDev.csproj | 1 - .../Tnb.WorkFlow.Entitys.csproj | 1 - .../Tnb.WorkFlow.Interfaces.csproj | 1 - workflow/Tnb.WorkFlow/Tnb.WorkFlow.csproj | 1 - 56 files changed, 357 insertions(+), 315 deletions(-) rename WarehouseMgr/Tnb.WarehouseMgr.Entities/Dto/Inputs/{CarryBindFloor2UpDownMachineInput.cs => CarryBindInput.cs} (64%) diff --git a/BasicData/Tnb.BasicData.Entities/Tnb.BasicData.Entities.csproj b/BasicData/Tnb.BasicData.Entities/Tnb.BasicData.Entities.csproj index d955e280..57e42217 100644 --- a/BasicData/Tnb.BasicData.Entities/Tnb.BasicData.Entities.csproj +++ b/BasicData/Tnb.BasicData.Entities/Tnb.BasicData.Entities.csproj @@ -6,7 +6,6 @@ enable False Debug;Release;tianyi - false diff --git a/BasicData/Tnb.BasicData.Interfaces/Tnb.BasicData.Interfaces.csproj b/BasicData/Tnb.BasicData.Interfaces/Tnb.BasicData.Interfaces.csproj index 0cd246dc..862aac48 100644 --- a/BasicData/Tnb.BasicData.Interfaces/Tnb.BasicData.Interfaces.csproj +++ b/BasicData/Tnb.BasicData.Interfaces/Tnb.BasicData.Interfaces.csproj @@ -6,7 +6,6 @@ enable False Debug;Release;tianyi - false diff --git a/BasicData/Tnb.BasicData/Tnb.BasicData.csproj b/BasicData/Tnb.BasicData/Tnb.BasicData.csproj index 261ba199..349cdb7c 100644 --- a/BasicData/Tnb.BasicData/Tnb.BasicData.csproj +++ b/BasicData/Tnb.BasicData/Tnb.BasicData.csproj @@ -6,7 +6,6 @@ enable True Debug;Release;tianyi - false diff --git a/EquipMgr/Tnb.EquipMgr.Entities/Tnb.EquipMgr.Entities.csproj b/EquipMgr/Tnb.EquipMgr.Entities/Tnb.EquipMgr.Entities.csproj index 88ce72e2..bd191439 100644 --- a/EquipMgr/Tnb.EquipMgr.Entities/Tnb.EquipMgr.Entities.csproj +++ b/EquipMgr/Tnb.EquipMgr.Entities/Tnb.EquipMgr.Entities.csproj @@ -5,7 +5,6 @@ enable enable Debug;Release;tianyi - false diff --git a/EquipMgr/Tnb.EquipMgr.Interfaces/Tnb.EquipMgr.Interfaces.csproj b/EquipMgr/Tnb.EquipMgr.Interfaces/Tnb.EquipMgr.Interfaces.csproj index 9c8c0608..ab92314f 100644 --- a/EquipMgr/Tnb.EquipMgr.Interfaces/Tnb.EquipMgr.Interfaces.csproj +++ b/EquipMgr/Tnb.EquipMgr.Interfaces/Tnb.EquipMgr.Interfaces.csproj @@ -5,7 +5,6 @@ enable enable Debug;Release;tianyi - false diff --git a/EquipMgr/Tnb.EquipMgr/Tnb.EquipMgr.csproj b/EquipMgr/Tnb.EquipMgr/Tnb.EquipMgr.csproj index 51d59244..b5cf8e54 100644 --- a/EquipMgr/Tnb.EquipMgr/Tnb.EquipMgr.csproj +++ b/EquipMgr/Tnb.EquipMgr/Tnb.EquipMgr.csproj @@ -6,7 +6,6 @@ enable True Debug;Release;tianyi - false diff --git a/PerMgr/Tnb.PerMgr.Entities/Tnb.PerMgr.Entities.csproj b/PerMgr/Tnb.PerMgr.Entities/Tnb.PerMgr.Entities.csproj index de76ccff..27dc0316 100644 --- a/PerMgr/Tnb.PerMgr.Entities/Tnb.PerMgr.Entities.csproj +++ b/PerMgr/Tnb.PerMgr.Entities/Tnb.PerMgr.Entities.csproj @@ -5,7 +5,6 @@ enable enable Debug;Release;tianyi - false diff --git a/PerMgr/Tnb.PerMgr.Interfaces/Tnb.PerMgr.Interfaces.csproj b/PerMgr/Tnb.PerMgr.Interfaces/Tnb.PerMgr.Interfaces.csproj index 41983b16..33c6f24b 100644 --- a/PerMgr/Tnb.PerMgr.Interfaces/Tnb.PerMgr.Interfaces.csproj +++ b/PerMgr/Tnb.PerMgr.Interfaces/Tnb.PerMgr.Interfaces.csproj @@ -5,7 +5,6 @@ enable enable Debug;Release;tianyi - false diff --git a/PerMgr/Tnb.PerMgr/Tnb.PerMgr.csproj b/PerMgr/Tnb.PerMgr/Tnb.PerMgr.csproj index 017c2ce4..f61d2bcb 100644 --- a/PerMgr/Tnb.PerMgr/Tnb.PerMgr.csproj +++ b/PerMgr/Tnb.PerMgr/Tnb.PerMgr.csproj @@ -5,7 +5,6 @@ enable enable Debug;Release;tianyi - false diff --git a/ProductionMgr/Tnb.ProductionMgr.Entities/Tnb.ProductionMgr.Entities.csproj b/ProductionMgr/Tnb.ProductionMgr.Entities/Tnb.ProductionMgr.Entities.csproj index ca97f34a..4adc18f3 100644 --- a/ProductionMgr/Tnb.ProductionMgr.Entities/Tnb.ProductionMgr.Entities.csproj +++ b/ProductionMgr/Tnb.ProductionMgr.Entities/Tnb.ProductionMgr.Entities.csproj @@ -6,7 +6,6 @@ enable False Debug;Release;tianyi - false diff --git a/ProductionMgr/Tnb.ProductionMgr.Interfaces/Tnb.ProductionMgr.Interfaces.csproj b/ProductionMgr/Tnb.ProductionMgr.Interfaces/Tnb.ProductionMgr.Interfaces.csproj index 79a1815e..34f5f41f 100644 --- a/ProductionMgr/Tnb.ProductionMgr.Interfaces/Tnb.ProductionMgr.Interfaces.csproj +++ b/ProductionMgr/Tnb.ProductionMgr.Interfaces/Tnb.ProductionMgr.Interfaces.csproj @@ -6,7 +6,6 @@ enable False Debug;Release;tianyi - false diff --git a/ProductionMgr/Tnb.ProductionMgr/RedisBackGround.cs b/ProductionMgr/Tnb.ProductionMgr/RedisBackGround.cs index 4778ee14..85c2df5d 100644 --- a/ProductionMgr/Tnb.ProductionMgr/RedisBackGround.cs +++ b/ProductionMgr/Tnb.ProductionMgr/RedisBackGround.cs @@ -2,6 +2,7 @@ using System.Data; using System.DirectoryServices.ActiveDirectory; using System.Dynamic; +using System.Security.Cryptography.X509Certificates; using System.Security.Policy; using System.Text; using System.Text.RegularExpressions; @@ -112,12 +113,13 @@ namespace Tnb.ProductionMgr //ctu取货 private async void CheckGet(object? state) { + Console.WriteLine($"{DateTime.Now.ToString("yyyy-MM-dd HH:mm:ss")} 执行CheckGet"); Dictionary getdic = new Dictionary(); getdic.Add("SSX-021-005", new string[] { "YTCS", "AllowFullOut_CS05", "LiftCode" }); getdic.Add("SSX-011-002", new string[] { "YTCS", "AllowAgvFullIn_CS02", "Code_CS02" }); getdic.Add("SSX-011-004", new string[] { "YTCS", "AllowCtuFullOut_CS04", "Code_CS04" }); - getdic.Add("SSX-011-008", new string[] { "东面提升机输送线", "入库输送线8允许出箱", "入库输送线7条码" }); + getdic.Add("SSX-011-008", new string[] { "东面提升机输送线", "入库输送线8允许出箱", "入库输送线8条码" }); getdic.Add("SSX-111-011", new string[] { "东面提升机输送线", "下升降机11允许出箱", "下升降机11条码" }); getdic.Add("SSX-111-012", new string[] { "东面提升机输送线", "下升降机12允许出箱", "下升降机12条码" }); @@ -137,7 +139,7 @@ namespace Tnb.ProductionMgr if (!string.IsNullOrEmpty(strs[2])) { string coderesult = await GetStringTag(strs[0], strs[2]); - coderesult = coderesult.Replace("\r", "").Replace(" ", ""); + coderesult = coderesult.Replace("\r", "").Replace("\\r", "").Replace(" ", ""); if (string.IsNullOrEmpty(coderesult)) { @@ -374,6 +376,7 @@ where carry_code = '{coderesult}' and status = '{WmsWareHouseConst.TASK_BILL_STA //扫码入库 private async void ScanInStock(object? state) { + Console.WriteLine($"{DateTime.Now.ToString("yyyy-MM-dd HH:mm:ss")} 执行ScanInStock"); Dictionary getdic = new Dictionary(); getdic.Add("BGWRKYCL02", new string[] { "CP8", "AllowGetFullBox1", "code1", "PutDoneEmptyBox", "false" }); getdic.Add("BGWRKYCL01", new string[] { "CP8", "AllowGetFullBox2", "code2", "PutDoneEmptyBox", "false" }); @@ -405,37 +408,40 @@ where carry_code = '{coderesult}' and status = '{WmsWareHouseConst.TASK_BILL_STA Logger.LogInformation($"【ScanInStock】 八工位 {key} 获取到扫码信息: {coderesult}"); - WmsCarryH? carry = _repository.AsSugarClient().Queryable().Single(it => it.carry_code == coderesult); - Logger.LogInformation($"【ScanInStock】 八工位 {key} 查找{coderesult}绑定的托盘: {JsonConvert.SerializeObject(carry)}"); - if (carry != null) + using (var _db = _repository.AsSugarClient().CopyNew()) { - if (_repository.AsSugarClient().Queryable().Where(p => p.carry_id == carry.id && p.status != WmsWareHouseConst.TASK_BILL_STATUS_COMPLE_ID).Any()) + WmsCarryH? carry = _db.Queryable().Single(it => it.carry_code == coderesult); + Logger.LogInformation($"【ScanInStock】 八工位 {key} 查找{coderesult}绑定的托盘: {JsonConvert.SerializeObject(carry)}"); + if (carry != null) { - Logger.LogInformation($"【ScanInStock】 八工位 {key} 托盘 {carry.id} 对应的执行任务状态(status)不是26126860808229(已完成),此时不能执行入库"); - continue; - } + if (_db.Queryable().Where(p => p.carry_id == carry.id && p.status != WmsWareHouseConst.TASK_BILL_STATUS_COMPLE_ID).Any()) + { + Logger.LogInformation($"【ScanInStock】 八工位 {key} 托盘 {carry.id} 对应的执行任务状态(status)不是26126860808229(已完成),此时不能执行入库"); + continue; + } - var WmsCarryCode = _repository.AsSugarClient().Queryable().Where(it => it.carry_id == carry.id).OrderByDescending(it => it.id).First(); - // 用适当的字段替换 YourTimestampField + var WmsCarryCode = _db.Queryable().Where(it => it.carry_id == carry.id).OrderByDescending(it => it.id).First(); + // 用适当的字段替换 YourTimestampField - if (WmsCarryCode != null) - { - Logger.LogInformation($"【ScanInStock】 八工位 {key} 查找到托盘{carry.carry_code}在WmsCarryCode中存在"); + if (WmsCarryCode != null) + { + Logger.LogInformation($"【ScanInStock】 八工位 {key} 查找到托盘{carry.carry_code}在WmsCarryCode中存在"); - VisualDevModelDataCrInput input = new VisualDevModelDataCrInput(); - input.data = new Dictionary(); - input.data.Add("barcode", coderesult); - input.data.Add("codeqty", WmsCarryCode.codeqty);//条码数量 - input.data.Add("material_code", WmsCarryCode.material_code); - input.data.Add("extras", key);//location_code - input.data.Add("warehouse_id", "1");//TEST - input.data.Add("bill_code", "");//采购收货单号 - input.data.Add("code_batch", WmsCarryCode.code_batch!);//批次 - input.data.Add("material_specification", WmsCarryCode.material_specification!);//规格型号 - input.data.Add("container_no", WmsCarryCode.container_no!);//箱号 - input.data.Add("material_id", WmsCarryCode.material_id); - input.data.Add("id", null); - _wmsPDAScanInStock.ScanInStockByRedis(input).Wait(); + VisualDevModelDataCrInput input = new VisualDevModelDataCrInput(); + input.data = new Dictionary(); + input.data.Add("barcode", coderesult); + input.data.Add("codeqty", WmsCarryCode.codeqty);//条码数量 + input.data.Add("material_code", WmsCarryCode.material_code); + input.data.Add("extras", key);//location_code + input.data.Add("warehouse_id", "1");//TEST + input.data.Add("bill_code", "");//采购收货单号 + input.data.Add("code_batch", WmsCarryCode.code_batch!);//批次 + input.data.Add("material_specification", WmsCarryCode.material_specification!);//规格型号 + input.data.Add("container_no", WmsCarryCode.container_no!);//箱号 + input.data.Add("material_id", WmsCarryCode.material_id); + input.data.Add("id", null); + _wmsPDAScanInStock.ScanInStockByRedis(input).Wait(); + } } } } @@ -453,6 +459,7 @@ where carry_code = '{coderesult}' and status = '{WmsWareHouseConst.TASK_BILL_STA /// private async void BGWCarrySupplement(object? state) { + Console.WriteLine($"{DateTime.Now.ToString("yyyy-MM-dd HH:mm:ss")} 执行BGWCarrySupplement"); Dictionary getdic = new Dictionary(); getdic.Add("YCLCKBGW", new string[] { "CP8", "AllowPutEmptyBox1" }); @@ -464,44 +471,77 @@ where carry_code = '{coderesult}' and status = '{WmsWareHouseConst.TASK_BILL_STA bool result = await GetBoolTag(strs[0], strs[1]); if (result) { - //LoggerBGWCarrySupplement.LogInformation($"【BGWCarrySupplementtimer】 八工位 {key} {strs[1]}采集到 {result}"); + LoggerBGWCarrySupplement.LogInformation($"【BGWCarrySupplementtimer】读取到信号{strs[1]} 值为{result} "); - BasLocation endLocation = _repository.AsSugarClient().Queryable().Where(r => r.location_code == key).First(); - if (endLocation == null) + using (var _db = _repository.AsSugarClient().CopyNew()) { - //LoggerBGWCarrySupplement.LogWarning($"【BGWCarrySupplementtimer】 {key}未维护库位信息"); - continue; + BasLocation endLocation = _db.Queryable().Where(r => r.location_code == key).First(); + if (endLocation == null) + { + LoggerBGWCarrySupplement.LogWarning($"【BGWCarrySupplementtimer】 {key}未维护库位信息"); + continue; + } + if (endLocation.is_lock == 1) + { + LoggerBGWCarrySupplement.LogInformation($"【BGWCarrySupplementtimer】 八工位 {key} 已锁定"); + continue; + } + + // 未锁定且已占用且库位中没有记录托盘 此时认为是叠盘机送过来的 + var wmsLoc = _db.Queryable() + .LeftJoin((a, b) => a.id == b.location_id) + .Where((a, b) => a.is_lock == 0 && a.is_use == "1" + && a.wh_id == WmsWareHouseConst.WAREHOUSE_YCL_ID && a.location_code.Contains("YCL-") + && a.is_type == "0") + .OrderBy((a, b) => a.location_code) // 当前是按库位排序出库 + .Select((a, b) => new + { + BasLocation = a, + WmsCarryH = b + }).ToList().GroupBy(p => p.BasLocation) + .Where(group => + { + // 是否存在托盘 + bool isExistsCarry = false; + foreach (var item in group) + { + if (!string.IsNullOrEmpty(item.WmsCarryH.carry_code)) + { + isExistsCarry = true; + break; + } + } + if (isExistsCarry) + return false; + else + return true; + }).Select(r => r.Key); + + + if (wmsLoc.Count() == 0) + { + LoggerBGWCarrySupplement.LogInformation($"【BGWCarrySupplementtimer】 没有未锁定且已占用且库位中没有记录托盘的数据"); + continue; + } + BasLocation startLocation = wmsLoc.First(); + + //锁定起点库位 + await _db.Updateable().SetColumns(r => r.is_lock == 1).Where(r => r.id == startLocation.id).ExecuteCommandAsync(); + ////锁定终点库位 更新为空闲 + //await _db.Updateable().SetColumns(r => new BasLocation { is_lock = 1, is_use = "0" }).Where(r => r.id == endLocation.id).ExecuteCommandAsync(); + + + LoggerBGWCarrySupplement.LogInformation($"【BGWCarrySupplementtimer】锁定起点库位 开始生成 {startLocation.location_code} 到 {endLocation.location_code} 预任务 "); + bool result_createPretask = await createPretask(startLocation.id, endLocation.id, "", "", LoggerBGWCarrySupplement); + if (!result_createPretask) + { + LoggerBGWCarrySupplement.LogWarning($"【BGWCarrySupplementtimer】 {startLocation.location_code} 到 {endLocation.location_code} 预任务生成失败 "); + continue; + } + LoggerBGWCarrySupplement.LogInformation($"【BGWCarrySupplementtimer】 {startLocation.location_code} 到 {endLocation.location_code} 预任务生成成功"); + + } - if (endLocation.is_lock == 1) - { - //LoggerBGWCarrySupplement.LogInformation($"【BGWCarrySupplementtimer】 八工位 {key} 已锁定"); - continue; - } - - // 找到库位未锁定的空托盘 todo 待修改为使用出库策略 - var wmsLoc = _repository.AsSugarClient().Queryable() - .LeftJoin((a, b) => a.id == b.location_id) - .Where((a, b) => a.wh_id == WmsWareHouseConst.WAREHOUSE_YCL_ID - && a.is_lock == 0 && a.location_code.Contains("YCL-") && a.is_use == "1") - .OrderBy((a, b) => a.location_code); - - - - BasLocation startLocation = wmsLoc.First(); - - //锁定起点库位 - await _repository.AsSugarClient().Updateable().SetColumns(r => r.is_lock == 1).Where(r => r.id == startLocation.id).ExecuteCommandAsync(); - //锁定终点库位 更新为空闲 - await _repository.AsSugarClient().Updateable().SetColumns(r => new BasLocation { is_lock = 1, is_use = "0" }).Where(r => r.id == endLocation.id).ExecuteCommandAsync(); - - - bool result_createPretask = await createPretask(startLocation.id, endLocation.id, "", "", LoggerBGWCarrySupplement); - if (!result_createPretask) - { - LoggerBGWCarrySupplement.LogWarning($"【BGWCarrySupplementtimer】 {startLocation.location_code} 到 {endLocation.location_code} 预任务生成失败 "); - continue; - } - LoggerBGWCarrySupplement.LogWarning($"【BGWCarrySupplementtimer】 {startLocation.location_code} 到 {endLocation.location_code} 预任务生成成功"); _ = _wareHouseService.GenTaskExecute(); @@ -519,14 +559,14 @@ where carry_code = '{coderesult}' and status = '{WmsWareHouseConst.TASK_BILL_STA //获取redis数据 - private void GetRedisData(object? state) + private async void GetRedisData(object? state) { var _redisReadConfigs = _repository.AsQueryable().Where(p => p.enabled == 1).ToList(); foreach (var config in _redisReadConfigs) { try { - var json = _redisData.GetHash(config.dev_name!, config.tag_name!); + var json = await _redisData.GetHash(config.dev_name!, config.tag_name!); if (json == null) { continue; @@ -599,86 +639,6 @@ where carry_code = '{coderesult}' and status = '{WmsWareHouseConst.TASK_BILL_STA } } - - ///// - ///// 7号输送线空料箱补充 (弃用) - ///// - //private async void SSX7Supplement(object? state) - //{ - // Dictionary getdic = new Dictionary(); - // getdic.Add("SSX-021-007", new string[] { "东面提升机输送线", "出库输送线7呼叫CTU" }); - - // foreach (var key in getdic.Keys) - // { - // try - // { - // var strs = getdic.Where(p => p.Key == key).First().Value; - // string data = await _redisData.GetHash(strs[0], strs[1]); - // if (data == null) - // { - // continue; - // } - // JObject? res = JsonConvert.DeserializeObject(data); - - // bool result = res != null && res["Value"] != null ? res.Value("Value") : false; - // if (result) - // { - // LoggerBGWCarrySupplement.LogInformation($"【SSX7Supplement】 7号输送线 {key} {strs[1]}采集到 {res["Value"]}"); - - // BasLocation endLocation = _repository.AsSugarClient().Queryable().Where(r => r.location_code == key).First(); - // if (endLocation == null) - // { - // LoggerBGWCarrySupplement.LogWarning($"【SSX7Supplement】 {key}未维护库位信息"); - // continue; - // } - // if (endLocation.is_lock == 1) - // { - // LoggerBGWCarrySupplement.LogInformation($"【SSX7Supplement】 7号输送线 {key} 已锁定"); - // continue; - // } - - // BasLocation location = await _repository.AsSugarClient().Queryable().SingleAsync(it => it.location_code == key && it.is_type != EnumLocationType.存储库位.ToString()) ?? throw new AppFriendlyException("无此库位或为存储库位", 500); - // //锁定起点库位 - // await _repository.AsSugarClient().Updateable().SetColumns(r => r.is_lock == 1).Where(r => r.id == location.id).ExecuteCommandAsync(); - - // Dictionary dic = new() - // { - // [nameof(WmsEmptyOutstockH.id)] = SnowflakeIdHelper.NextId(), - // [nameof(WmsEmptyOutstockH.org_id)] = WmsWareHouseConst.AdministratorOrgId, - // [nameof(WmsEmptyOutstockH.location_id)] = location.id, - // [nameof(WmsEmptyOutstockH.carrystd_id)] = WmsWareHouseConst.LIAOXIANGID, - // [nameof(WmsEmptyOutstockH.bill_code)] = _billRullService.GetBillNumber(WmsWareHouseConst.WMS_EMPTYOUTSTK_ENCODE).GetAwaiter().GetResult(), - // [nameof(WmsEmptyOutstockH.status)] = WmsWareHouseConst.BILLSTATUS_ADD_ID, - // [nameof(WmsEmptyOutstockH.qty)] = 1, - // [nameof(WmsEmptyOutstockH.biz_type)] = WmsWareHouseConst.BIZTYPE_WMSEPTYOUTSTK_ID, - // ["warehouse_id"] = WmsWareHouseConst.WAREHOUSE_ZC_ID, - // [nameof(WmsEmptyOutstockH.create_id)] = WmsWareHouseConst.AdministratorUserId, - // [nameof(WmsEmptyOutstockH.create_time)] = DateTime.Now - // }; - - // VisualDevModelDataCrInput visualDevModelDataCrInput = new() - // { - // data = dic, - // }; - // var result_WmsEmptyOut = await _wmsEmptyOutstockService.WmsEmptyOut(visualDevModelDataCrInput); - - // if (result_WmsEmptyOut.code2 != "200") - // { - // LoggerBGWCarrySupplement.LogWarning($"【SSX7Supplement】 预任务生成失败 {result_WmsEmptyOut.msg}"); - // continue; - // } - // LoggerBGWCarrySupplement.LogWarning($"【SSX7Supplement】 预任务生成成功"); - - // _ = _wareHouseService.GenTaskExecute(); - // } - // } - // catch (Exception ex) - // { - // LoggerBGWCarrySupplement.LogInformation($"【SSX7Supplement】 7号输送线空料箱补充发生异常:{ex}"); - // } - // } - //} - #endregion /// @@ -686,6 +646,7 @@ where carry_code = '{coderesult}' and status = '{WmsWareHouseConst.TASK_BILL_STA /// private async void YCLGLDPJInstock(object? state) { + Console.WriteLine($"{DateTime.Now.ToString("yyyy-MM-dd HH:mm:ss")} 执行YCLGLDPJInstock"); Dictionary getdic = new Dictionary(); getdic.Add("SGW-YCL", new string[] { "CP3-5", "AllowGetFullBox" }); @@ -828,6 +789,7 @@ where carry_code = '{coderesult}' and status = '{WmsWareHouseConst.TASK_BILL_STA private async void SSXcode(object? state) { + Console.WriteLine($"{DateTime.Now.ToString("yyyy-MM-dd HH:mm:ss")} 执行SSXcode"); Dictionary dic = new Dictionary(); dic.Add("东面提升机输送线", new string[] { "下升降机判断请求", "下升降机判断条码", "下升降机判断完毕", "下升降机判断结果" }); Dictionary putdic = new Dictionary(); @@ -928,6 +890,7 @@ where carry_code = '{coderesult}' and status = '{WmsWareHouseConst.TASK_BILL_STA // 上升降机扫码 需要等待空料架区 此处需要轮询 private async void Floor2UpMachinecode(object? args) { + Console.WriteLine($"{DateTime.Now.ToString("yyyy-MM-dd HH:mm:ss")} 执行Floor2UpMachinecode"); string barcode = await GetStringTag("东面提升机输送线", MechanicalArmConsts.上升降机条码); if (string.IsNullOrEmpty(barcode)) { @@ -1060,14 +1023,14 @@ where carry_code = '{coderesult}' and status = '{WmsWareHouseConst.TASK_BILL_STA LoggerFloor2UpDownMachine.LogInformation($@"【上升降机】回写转库单的剩余可绑定料架数量"); // 绑定料箱到料架 - CarryBindFloor2UpDownMachineInput carryBindFloor2UpDownMachineInput = new() { }; - carryBindFloor2UpDownMachineInput.carry_id = target.rackid; - carryBindFloor2UpDownMachineInput.carry_code = target.rackcode; - carryBindFloor2UpDownMachineInput.membercarry_id = LX.id; - carryBindFloor2UpDownMachineInput.membercarry_code = LX.carry_code; - carryBindFloor2UpDownMachineInput.carrystd_id = rack.carrystd_id; + CarryBindInput carryBindInput = new(); + carryBindInput.carry_id = target.rackid; + carryBindInput.carry_code = target.rackcode; + carryBindInput.membercarry_id = LX.id; + carryBindInput.membercarry_code = LX.carry_code; + carryBindInput.carrystd_id = rack.carrystd_id; - await _wmsCarryBindService.CarryBindFloor2UpDownMachine(carryBindFloor2UpDownMachineInput); + await _wmsCarryBindService.CarryBind(carryBindInput); await db.Ado.CommitTranAsync(); } @@ -1102,6 +1065,7 @@ where carry_code = '{coderesult}' and status = '{WmsWareHouseConst.TASK_BILL_STA /// public async void 送空托到上升降区(object? args) { + Console.WriteLine($"{DateTime.Now.ToString("yyyy-MM-dd HH:mm:ss")} 执行送空托到上升降区"); #region 检查信号 List configs_upMachine = new List(); if (await GetBoolTag("东面提升机输送线", $"上升降机请求送空托1")) @@ -1215,6 +1179,7 @@ where carry_code = '{coderesult}' and status = '{WmsWareHouseConst.TASK_BILL_STA /// public async void 送满托到下升降区(object? args) { + Console.WriteLine($"{DateTime.Now.ToString("yyyy-MM-dd HH:mm:ss")} 执行送满托到下升降区"); #region 检查信号 List configs_upMachine = new List(); if (await GetBoolTag("东面提升机输送线", $"下升降机请求送满托1")) @@ -1352,6 +1317,7 @@ where carry_code = '{coderesult}' and status = '{WmsWareHouseConst.TASK_BILL_STA /// public async void 移走上升降区未生成预任务且满托的料架(object? args) { + Console.WriteLine($"{DateTime.Now.ToString("yyyy-MM-dd HH:mm:ss")} 执行移走上升降区未生成预任务且满托的料架"); #region 检查信号 List configs_upMachine = new List(); if (await GetBoolTag("东面提升机输送线", $"上升降机请求取满托1")) @@ -1445,6 +1411,7 @@ where carry_code = '{coderesult}' and status = '{WmsWareHouseConst.TASK_BILL_STA /// public async void 移走下升降区未生成预任务且空托的料架(object? args) { + Console.WriteLine($"{DateTime.Now.ToString("yyyy-MM-dd HH:mm:ss")} 执行移走下升降区未生成预任务且空托的料架"); #region 检查信号 List configs_upMachine = new List(); if (await GetBoolTag("东面提升机输送线", $"下升降机请求取空托1")) @@ -1497,11 +1464,11 @@ where carry_code = '{coderesult}' and status = '{WmsWareHouseConst.TASK_BILL_STA BasLocation endLocation = rackEndLocations.First(); // 解除绑定料箱到料架 - CarryBindFloor2UpDownMachineInput carryBindFloor2UpDownMachineInput = new() { }; - carryBindFloor2UpDownMachineInput.carry_id = wmsMechanicalArmH.rackid; - carryBindFloor2UpDownMachineInput.carry_code = wmsMechanicalArmH.rackcode; + CarryBindInput carryBindInput = new() { }; + carryBindInput.carry_id = wmsMechanicalArmH.rackid; + carryBindInput.carry_code = wmsMechanicalArmH.rackcode; - await _wmsCarryBindService.CarryUnbindFloor2UpDownMachine(carryBindFloor2UpDownMachineInput); + await _wmsCarryBindService.CarryUnbind(carryBindInput); // 锁住终点库位 await db.Updateable(r => new BasLocation @@ -1557,18 +1524,76 @@ where carry_code = '{coderesult}' and status = '{WmsWareHouseConst.TASK_BILL_STA return false; } + + #region 内存测试 + public async Task GetBoolTag(string DevName, string field) { try { - string jsonString = _redisData.GetHash(DevName, field); + string jsonString = await _redisData.GetHash(DevName, field); - string pattern = @"""Value"":\s*(true|false)"; + JObject jsonObject = JObject.Parse(jsonString); + + if (jsonObject.TryGetValue("Value", out JToken valueToken2)) + { + return bool.Parse(valueToken2.ToString()); + } + else + { + Console.WriteLine($"未找到匹配项 {DevName} {field}"); + } + } + catch (Exception ex) + { + Console.WriteLine($"未找到匹配项{DevName} {field}"); + } + + return false; + } + + public async Task GetStringTag(string DevName, string field) + { + #region + //try + //{ + // string jsonString = await _redisData.GetHash(DevName, field); + + // JObject jsonObject = JObject.Parse(jsonString); + // if (jsonObject.TryGetValue("StatusCode", out JToken valueToken1)) + // { + // if (valueToken1.ToString() == "-1") + // return ""; + // } + // if (jsonObject.TryGetValue("Value", out JToken valueToken2)) + // { + // return valueToken2.ToString(); + // } + // else + // { + // Console.WriteLine($"未找到匹配项 {DevName} {field}"); + // } + //} + //catch (Exception ex) + //{ + // // 捕获并处理异常 + // Console.WriteLine($"发生异常: {ex.Message}"); + //} + + //return $"未找到匹配项 {DevName} {field}"; + #endregion + + try + { + string jsonString = await _redisData.GetHash(DevName, field); + + string pattern = "\"Value\":\"(.*?)\""; System.Text.RegularExpressions.Match match = Regex.Match(jsonString, pattern); if (match.Success) { - return bool.Parse(match.Groups[1].Value); + + return match.Groups[1].Value; } else { @@ -1580,56 +1605,7 @@ where carry_code = '{coderesult}' and status = '{WmsWareHouseConst.TASK_BILL_STA Console.WriteLine($"未找到匹配项{DevName} {field}"); } - return false; - } - public async Task GetStringTag(string DevName, string field) - { - try - { - string jsonString = _redisData.GetHash(DevName, field); - - JObject jsonObject = JObject.Parse(jsonString); - - if (jsonObject.TryGetValue("Value", out JToken valueToken)) - { - return valueToken.ToString(); - } - else - { - Console.WriteLine($"未找到匹配项 {DevName} {field}"); - } - } - catch (Exception ex) - { - // 捕获并处理异常 - Console.WriteLine($"发生异常: {ex.Message}"); - } - return $"未找到匹配项 {DevName} {field}"; - //try - //{ - - // string jsonString = _redisData.GetHash(DevName, field); - - // string pattern = @"""Value"":\s*""([^""]+)"""; - - // System.Text.RegularExpressions.Match match = Regex.Match(jsonString, pattern); - // if (match.Success) - // { - - // return match.Groups[1].Value; - // } - // else - // { - // Console.WriteLine($"未找到匹配项{DevName} {field}"); - // } - //} - //catch (Exception ex) - //{ - // Console.WriteLine($"未找到匹配项{DevName} {field}"); - //} - - //return $"未找到匹配项 {DevName} {field}"; } private async Task Floor2UpDownMachinecode_SetTag(string tag, string value) @@ -1652,10 +1628,13 @@ where carry_code = '{coderesult}' and status = '{WmsWareHouseConst.TASK_BILL_STA //JObject valueJson = new JObject(); //valueJson["Value"] = value; - //bool res = await _redisData.HSet(DevName, tag, valueJson.ToString()); - //return true; + //_redisData.SetHash(DevName, tag, valueJson.ToString()); + return true; } + #endregion + + #endregion public Task StartAsync(CancellationToken cancellationToken) @@ -1674,13 +1653,13 @@ where carry_code = '{coderesult}' and status = '{WmsWareHouseConst.TASK_BILL_STA //YCLWXDPJInstocktimer = new Timer(YCLWXDPJInstock, null, TimeSpan.Zero, TimeSpan.FromSeconds(100000)); // 二楼上升降机 - Floor2UpMachinecodetimer = new Timer(Floor2UpMachinecode, null, TimeSpan.Zero, TimeSpan.FromSeconds(30)); + Floor2UpMachinecodetimer = new Timer(Floor2UpMachinecode, null, TimeSpan.Zero, TimeSpan.FromSeconds(20)); // 二楼料架配送 - Floor2timer送空托到上升降区 = new Timer(送空托到上升降区, null, TimeSpan.Zero, TimeSpan.FromSeconds(60)); - Floor2timer送满托到下升降区 = new Timer(送满托到下升降区, null, TimeSpan.Zero, TimeSpan.FromSeconds(60)); - Floor2timer移走上升降区未生成预任务且满托的料架 = new Timer(移走上升降区未生成预任务且满托的料架, null, TimeSpan.Zero, TimeSpan.FromSeconds(60)); - Floor2timer移走下升降区未生成预任务且空托的料架 = new Timer(移走下升降区未生成预任务且空托的料架, null, TimeSpan.Zero, TimeSpan.FromSeconds(60)); + Floor2timer送空托到上升降区 = new Timer(送空托到上升降区, null, TimeSpan.Zero, TimeSpan.FromSeconds(30)); + Floor2timer送满托到下升降区 = new Timer(送满托到下升降区, null, TimeSpan.Zero, TimeSpan.FromSeconds(30)); + Floor2timer移走上升降区未生成预任务且满托的料架 = new Timer(移走上升降区未生成预任务且满托的料架, null, TimeSpan.Zero, TimeSpan.FromSeconds(30)); + Floor2timer移走下升降区未生成预任务且空托的料架 = new Timer(移走下升降区未生成预任务且空托的料架, null, TimeSpan.Zero, TimeSpan.FromSeconds(30)); // 7号线补充空料箱 (弃用) //SSX7Supplementtimer = new Timer(SSX7Supplement, null, TimeSpan.Zero, TimeSpan.FromSeconds(30)); diff --git a/QcMgr/Tnb.QcMgr.Entities/Tnb.QcMgr.Entities.csproj b/QcMgr/Tnb.QcMgr.Entities/Tnb.QcMgr.Entities.csproj index 88ce72e2..bd191439 100644 --- a/QcMgr/Tnb.QcMgr.Entities/Tnb.QcMgr.Entities.csproj +++ b/QcMgr/Tnb.QcMgr.Entities/Tnb.QcMgr.Entities.csproj @@ -5,7 +5,6 @@ enable enable Debug;Release;tianyi - false diff --git a/QcMgr/Tnb.QcMgr.Interfaces/Tnb.QcMgr.Interfaces.csproj b/QcMgr/Tnb.QcMgr.Interfaces/Tnb.QcMgr.Interfaces.csproj index add463b1..83334969 100644 --- a/QcMgr/Tnb.QcMgr.Interfaces/Tnb.QcMgr.Interfaces.csproj +++ b/QcMgr/Tnb.QcMgr.Interfaces/Tnb.QcMgr.Interfaces.csproj @@ -5,7 +5,6 @@ enable enable Debug;Release;tianyi - false diff --git a/QcMgr/Tnb.QcMgr/Tnb.QcMgr.csproj b/QcMgr/Tnb.QcMgr/Tnb.QcMgr.csproj index ee840965..1cf08455 100644 --- a/QcMgr/Tnb.QcMgr/Tnb.QcMgr.csproj +++ b/QcMgr/Tnb.QcMgr/Tnb.QcMgr.csproj @@ -5,7 +5,6 @@ enable enable Debug;Release;tianyi - false diff --git a/WarehouseMgr/Tnb.WarehouseMgr.Entities/Dto/Inputs/CarryBindFloor2UpDownMachineInput.cs b/WarehouseMgr/Tnb.WarehouseMgr.Entities/Dto/Inputs/CarryBindInput.cs similarity index 64% rename from WarehouseMgr/Tnb.WarehouseMgr.Entities/Dto/Inputs/CarryBindFloor2UpDownMachineInput.cs rename to WarehouseMgr/Tnb.WarehouseMgr.Entities/Dto/Inputs/CarryBindInput.cs index 4d60b738..fa60b017 100644 --- a/WarehouseMgr/Tnb.WarehouseMgr.Entities/Dto/Inputs/CarryBindFloor2UpDownMachineInput.cs +++ b/WarehouseMgr/Tnb.WarehouseMgr.Entities/Dto/Inputs/CarryBindInput.cs @@ -6,8 +6,14 @@ using System.Threading.Tasks; namespace Tnb.WarehouseMgr.Entities.Dto.Inputs { - public class CarryBindFloor2UpDownMachineInput + public class CarryBatchBindInput + { + public List carryBindInputs { get; set; } + } + public class CarryBindInput { + public string? org { get; set; } + public string? create_id { get; set; } public string? carry_id { get; set; } public string? carry_code { get; set; } public string? carrystd_id { get; set; } diff --git a/WarehouseMgr/Tnb.WarehouseMgr.Entities/Entity/WmsElevatorH.cs b/WarehouseMgr/Tnb.WarehouseMgr.Entities/Entity/WmsElevatorH.cs index 83c7b068..7887ec70 100644 --- a/WarehouseMgr/Tnb.WarehouseMgr.Entities/Entity/WmsElevatorH.cs +++ b/WarehouseMgr/Tnb.WarehouseMgr.Entities/Entity/WmsElevatorH.cs @@ -92,5 +92,9 @@ public partial class WmsElevatorH : BaseEntity /// 当前电梯所在楼层 /// public int current_floor { get; set; } + /// + /// 电梯占用状态 + /// + public int is_use { get; set; } } diff --git a/WarehouseMgr/Tnb.WarehouseMgr.Entities/Tnb.WarehouseMgr.Entities.csproj b/WarehouseMgr/Tnb.WarehouseMgr.Entities/Tnb.WarehouseMgr.Entities.csproj index 88ce72e2..bd191439 100644 --- a/WarehouseMgr/Tnb.WarehouseMgr.Entities/Tnb.WarehouseMgr.Entities.csproj +++ b/WarehouseMgr/Tnb.WarehouseMgr.Entities/Tnb.WarehouseMgr.Entities.csproj @@ -5,7 +5,6 @@ enable enable Debug;Release;tianyi - false diff --git a/WarehouseMgr/Tnb.WarehouseMgr.Interfaces/IWmsCarryBindService.cs b/WarehouseMgr/Tnb.WarehouseMgr.Interfaces/IWmsCarryBindService.cs index 97a07702..6bbbf338 100644 --- a/WarehouseMgr/Tnb.WarehouseMgr.Interfaces/IWmsCarryBindService.cs +++ b/WarehouseMgr/Tnb.WarehouseMgr.Interfaces/IWmsCarryBindService.cs @@ -1,5 +1,6 @@ using JNPF.Common.Dtos.VisualDev; using Tnb.WarehouseMgr.Entities.Dto.Inputs; +using Tnb.WarehouseMgr.Entities.Dto.Outputs; namespace Tnb.WarehouseMgr.Interfaces { @@ -10,8 +11,8 @@ namespace Tnb.WarehouseMgr.Interfaces { Task CarryBind(VisualDevModelDataCrInput input); - Task CarryBindFloor2UpDownMachine(CarryBindFloor2UpDownMachineInput input); - Task CarryUnbindFloor2UpDownMachine(CarryBindFloor2UpDownMachineInput input); + Task CarryBind(CarryBindInput input); + Task CarryUnbind(CarryBindInput input); Task CarryCodeUnbind(CarryCodeUnbindInput input); } } diff --git a/WarehouseMgr/Tnb.WarehouseMgr.Interfaces/Tnb.WarehouseMgr.Interfaces.csproj b/WarehouseMgr/Tnb.WarehouseMgr.Interfaces/Tnb.WarehouseMgr.Interfaces.csproj index 8dbb0ac5..abcaef0a 100644 --- a/WarehouseMgr/Tnb.WarehouseMgr.Interfaces/Tnb.WarehouseMgr.Interfaces.csproj +++ b/WarehouseMgr/Tnb.WarehouseMgr.Interfaces/Tnb.WarehouseMgr.Interfaces.csproj @@ -5,7 +5,6 @@ enable enable Debug;Release;tianyi - false diff --git a/WarehouseMgr/Tnb.WarehouseMgr/DevServBase`1.cs b/WarehouseMgr/Tnb.WarehouseMgr/DevServBase`1.cs index 99efc58e..0190670d 100644 --- a/WarehouseMgr/Tnb.WarehouseMgr/DevServBase`1.cs +++ b/WarehouseMgr/Tnb.WarehouseMgr/DevServBase`1.cs @@ -47,13 +47,12 @@ namespace Tnb.WarehouseMgr context = new(cfg); s_elevatorMap = await context.Queryable().ToDictionaryAsync(x => x.elevator_id, x => x.elevator_code); - + s_loadedStatusDic = context.Queryable().ToList().ToDictionary(x => x.elevator_id, x => x.is_use); if (s_eleUseStatusDic.Count < 1) { foreach (var (k, _) in s_elevatorMap) { - s_eleUseStatusDic[k] = 0; s_loadedStatusDic[k] = 0; } } diff --git a/WarehouseMgr/Tnb.WarehouseMgr/DeviceProviderService.cs b/WarehouseMgr/Tnb.WarehouseMgr/DeviceProviderService.cs index 7cb6d678..fcd17960 100644 --- a/WarehouseMgr/Tnb.WarehouseMgr/DeviceProviderService.cs +++ b/WarehouseMgr/Tnb.WarehouseMgr/DeviceProviderService.cs @@ -83,8 +83,7 @@ namespace Tnb.WarehouseMgr [HttpPost, NonUnify, AllowAnonymous] public async Task LoadConfirm(ConfirmInput input) { - - Logger.Information("【LoadConfirm】接收到WCS取货确认信号.................. "); + Logger.Information($"【LoadConfirm】接收到WCS取货确认信号.................. {JsonConvert.SerializeObject(input)}"); var dis = _db.Queryable().Where(P => P.bill_code == input.taskCode).First(); if (dis.area_code == "ZSCJ001") @@ -324,7 +323,8 @@ namespace Tnb.WarehouseMgr if (sysStatus == (int)EnumSysStatus.正常状态 && runStatus == (int)EnumRunStatus.停梯 && doorStatus == (int)EnumDoorStatus.开门到位保持 && s_eleUseStatusDic[elevator.device_id] == (int)EnumElevatorUseStatus.空闲) { - Logger.Information($"【UnloadConfirm】 成功"); + Logger.Information($"【UnloadConfirm】 成功 {devName} 变更为占用"); + await _db.Updateable().SetColumns(r => r.is_use == (int)EnumElevatorUseStatus.占用).Where(r => r.elevator_id == elevator.device_id).ExecuteCommandAsync(); s_eleUseStatusDic[elevator.device_id] = (int)EnumElevatorUseStatus.占用; return await ToApiResult(HttpStatusCode.OK, "成功"); } @@ -458,10 +458,11 @@ namespace Tnb.WarehouseMgr Logger.Information($"【TaskCallback】 根据任务单查找电梯结果 {JsonConvert.SerializeObject(elevator)}"); if (!elevator?.device_id.IsNullOrEmpty() ?? false) { + await _db.Updateable().SetColumns(r => r.is_use == (int)EnumElevatorUseStatus.空闲).Where(r => r.elevator_id == elevator.device_id).ExecuteCommandAsync(); s_eleUseStatusDic[elevator.device_id] = (int)EnumElevatorUseStatus.空闲; - // 根据disTask StartLocationId 起始库位关联电梯获取设备ID location_code.Continas("") + // 根据disTask StartLocationId 起始库位关联电梯获取设备ID location_code.Continas("") var devName = s_elevatorMap[elevator.device_id]?.ToString(); - Logger.Information($"【TaskCallback】 {devName.Match(@"\d+")}#梯,设备名称:{devName},开始进入关门流程"); + Logger.Information($"【TaskCallback】 {devName.Match(@"\d+")}#梯,设备名称:{devName},开始进入关门流程 {devName} 变更为空闲"); int doorStatus = await _elevatorControlService.GetTagAsync(devName, ElevatorConsts.DoorStatus); Logger.Information($"【TaskCallback】 设备:{devName},门状态:{doorStatus.ToEnum().ToString()}"); if (doorStatus.ToEnum() != EnumDoorStatus.关门到位保持 diff --git a/WarehouseMgr/Tnb.WarehouseMgr/Tnb.WarehouseMgr.csproj b/WarehouseMgr/Tnb.WarehouseMgr/Tnb.WarehouseMgr.csproj index 45a62e7c..60b81e8b 100644 --- a/WarehouseMgr/Tnb.WarehouseMgr/Tnb.WarehouseMgr.csproj +++ b/WarehouseMgr/Tnb.WarehouseMgr/Tnb.WarehouseMgr.csproj @@ -7,7 +7,6 @@ enable True Debug;Release - false diff --git a/WarehouseMgr/Tnb.WarehouseMgr/WareHouseService.cs b/WarehouseMgr/Tnb.WarehouseMgr/WareHouseService.cs index 23218026..5c985023 100644 --- a/WarehouseMgr/Tnb.WarehouseMgr/WareHouseService.cs +++ b/WarehouseMgr/Tnb.WarehouseMgr/WareHouseService.cs @@ -71,7 +71,7 @@ namespace Tnb.WarehouseMgr private readonly ElevatorControlConfiguration _eleCtlCfg = App.Configuration.Build(); private static Dictionary locMap = new Dictionary(StringComparer.OrdinalIgnoreCase); private readonly IConfiguration _configuration; - private readonly RedisData _redisData; + private readonly StackExRedisHelper _redisData; private readonly IVisualDevService _visualDevService; private readonly IRunService _runService; @@ -80,7 +80,7 @@ namespace Tnb.WarehouseMgr public Func AddUnExecuteTask { get; set; } - public WareHouseService(ISqlSugarRepository repository, IDictionaryDataService dictionaryDataService, RedisData redisData, + public WareHouseService(ISqlSugarRepository repository, IDictionaryDataService dictionaryDataService, StackExRedisHelper redisData, IBillRullService billRullService, IUserManager userManager, ICacheManager cacheManager, IElevatorControlService elevatorControlService, IWmsCarryBindService wmsCarryBindService, IRunService runService, @@ -389,7 +389,7 @@ namespace Tnb.WarehouseMgr throw new AppFriendlyException("点位" + input.targetName + "不存在", 500); strs = putdic.Where(p => p.Key == input.targetName).First().Value; - bool flag = await _redisData.HashExist(strs[0], strs[1]); + bool flag = await _redisData.HashExists(strs[0], strs[1]); if (!flag) { throw new AppFriendlyException("点位" + input.targetName + "不存在", 500); @@ -423,7 +423,7 @@ namespace Tnb.WarehouseMgr putdic.Add("ZS-C02-1", new string[] { "hxjC", "A3允许入空箱", }); getdic.Add("ZS-C02-2", new string[] { "hxjC", "A3允许取满箱" }); - + putdic.Add("ZS-C03-1", new string[] { "hxjC", "A4允许入空箱", }); getdic.Add("ZS-C03-2", new string[] { "hxjC", "A4允许取满箱" }); @@ -436,6 +436,7 @@ namespace Tnb.WarehouseMgr putdic.Add("ZS-C06-1", new string[] { "hxjC", "A7允许入空箱", }); getdic.Add("ZS-C06-2", new string[] { "hxjC", "A7允许取满箱" }); var strs = new string[] { }; + if (action == "LOAD")//取货 { if (!getdic.ContainsKey(code)) @@ -444,15 +445,16 @@ namespace Tnb.WarehouseMgr } strs = getdic.Where(p => p.Key == code).First().Value; - bool flag = _redisData.HashExist(strs[0], strs[1]).Result; + bool flag = await _redisData.HashExists(strs[0], strs[1]); + Logger.Information($"【Check】 判断CTU是否可以取货1 {code} {action} flag:{flag} "); if (!flag) { - Logger.Information($"【Check】 判断CTU是否可以取货 {code} {action} flag:{flag} "); return false; } string data = _redisData.GetHash(strs[0], strs[1]).Result; JObject? res = JsonConvert.DeserializeObject(data); bool result = res != null && res["Value"] != null ? res.Value("Value") : false; + Logger.Information($"【Check】 判断CTU是否可以取货2 {code} {action} result:{result} "); if (!result) return false; return true; @@ -463,15 +465,16 @@ namespace Tnb.WarehouseMgr return false; strs = putdic.Where(p => p.Key == code).First().Value; - bool flag = _redisData.HashExist(strs[0], strs[1]).Result; + bool flag = await _redisData.HashExists(strs[0], strs[1]); + Logger.Information($"【Check】 判断CTU是否可以取货1 {code} {action} flag:{flag} "); if (!flag) { - Logger.Information($"【Check】 判断CTU是否可以取货 {code} {action} flag:{flag} "); return false; } string data = _redisData.GetHash(strs[0], strs[1]).Result; JObject? res = JsonConvert.DeserializeObject(data); bool result = res != null && res["Value"] != null ? res.Value("Value") : false; + Logger.Information($"【Check】 判断CTU是否可以取货2 {code} {action} result:{result} "); if (!result) return false; return true; @@ -749,7 +752,7 @@ namespace Tnb.WarehouseMgr //JObject valueJson = new JObject(); //valueJson["Value"] = value; - //bool res = await _redisData.HSet(DevName, tag, valueJson.ToString()); + //_redisData.SetHash(DevName, tag, valueJson.ToString()); //return true; } diff --git a/WarehouseMgr/Tnb.WarehouseMgr/WmsCarryBindService.cs b/WarehouseMgr/Tnb.WarehouseMgr/WmsCarryBindService.cs index c0173ca5..1179aeca 100644 --- a/WarehouseMgr/Tnb.WarehouseMgr/WmsCarryBindService.cs +++ b/WarehouseMgr/Tnb.WarehouseMgr/WmsCarryBindService.cs @@ -18,6 +18,7 @@ using SqlSugar; using Tnb.WarehouseMgr.Entities; using Tnb.WarehouseMgr.Entities.Dto; using Tnb.WarehouseMgr.Entities.Dto.Inputs; +using Tnb.WarehouseMgr.Entities.Dto.Outputs; using Tnb.WarehouseMgr.Entities.Enums; using Tnb.WarehouseMgr.Interfaces; @@ -177,14 +178,14 @@ namespace Tnb.WarehouseMgr /// - /// 二楼机械手 + /// 绑定料箱到料架 /// /// /// /// /// [NonAction] - public async Task CarryBindFloor2UpDownMachine(CarryBindFloor2UpDownMachineInput input) + public async Task CarryBind(CarryBindInput input) { bool isOk = false; @@ -197,6 +198,7 @@ namespace Tnb.WarehouseMgr throw new ArgumentNullException(nameof(input)); } + await db.Ado.BeginTranAsync(); WmsCarryH? carry = await db.Queryable().SingleAsync(it => it.id == input.carry_id); WmsCarryH? subCarry = await db.Queryable().SingleAsync(it => it.id == input.membercarry_id); if (carry != null && subCarry != null) @@ -215,6 +217,22 @@ namespace Tnb.WarehouseMgr { throw Oops.Oh(ErrorCode.COM1001); } + + // 插入子载具绑定记录 + VisualDevModelDataCrInput visualDevModelCrInput = new() { data = new Dictionary() }; + visualDevModelCrInput.data[nameof(WmsCarrybindH.carry_id)] = input.carry_id; + visualDevModelCrInput.data[nameof(WmsCarrybindH.carry_code)] = input.carry_code; + visualDevModelCrInput.data[nameof(WmsCarrybindH.membercarry_id)] = input.membercarry_id; + visualDevModelCrInput.data[nameof(WmsCarrybindH.membercarry_code)] = input.membercarry_code; + visualDevModelCrInput.data[nameof(WmsCarrybindH.type)] = 0; + visualDevModelCrInput.data[nameof(WmsCarrybindH.carrystd_id)] = carry.carrystd_id; + visualDevModelCrInput.data[nameof(WmsCarrybindH.create_id)] = input.create_id; + visualDevModelCrInput.data[nameof(WmsCarrybindH.create_time)] = DateTime.Now; + visualDevModelCrInput.data[nameof(WmsCarrybindH.loc)] = 1; + VisualDevEntity? templateEntity = await _visualDevService.GetInfoById(ModuleConsts.MODULE_WMSCARRYBIND_ID, true); + await _runService.Create(templateEntity, visualDevModelCrInput); + + await db.Ado.CommitTranAsync(); } else { @@ -226,54 +244,78 @@ namespace Tnb.WarehouseMgr } catch (Exception ex) { + await db.Ado.RollbackTranAsync(); + return await ToApiResult(JNPF.Common.Enums.HttpStatusCode.InternalServerError, ex.Message); } } - - return Task.FromResult(true); + return await ToApiResult(JNPF.Common.Enums.HttpStatusCode.OK, "成功"); } /// - /// 二楼机械手解绑定 + /// 解绑定料箱到料架 /// /// /// /// /// [NonAction] - public async Task CarryUnbindFloor2UpDownMachine(CarryBindFloor2UpDownMachineInput input) + public async Task CarryUnbind(CarryBindInput input) { bool isOk = false; - try + using (var db = _db.CopyNew()) { - if (input == null) + try { - throw new ArgumentNullException(nameof(input)); - } + if (input == null) + { + throw new ArgumentNullException(nameof(input)); + } - WmsCarryH? carry = await _db.Queryable().SingleAsync(it => it.id == input.carry_id); - if (carry != null) - { - int row = await _db.Deleteable().Where(r => r.carry_id == input.carry_id).ExecuteCommandAsync(); - isOk = row > 0; - - if (!isOk) + WmsCarryH? carry = await _db.Queryable().SingleAsync(it => it.id == input.carry_id); + if (carry != null) { - throw Oops.Oh(ErrorCode.COM1001); + int row = await _db.Deleteable().Where(r => r.carry_id == input.carry_id).ExecuteCommandAsync(); + isOk = row > 0; + + if (!isOk) + { + throw Oops.Oh(ErrorCode.COM1001); + } + + + // 插入子载具绑定记录 + VisualDevModelDataCrInput visualDevModelCrInput = new() { data = new Dictionary() }; + visualDevModelCrInput.data[nameof(WmsCarrybindH.carry_id)] = input.carry_id; + visualDevModelCrInput.data[nameof(WmsCarrybindH.carry_code)] = input.carry_code; + visualDevModelCrInput.data[nameof(WmsCarrybindH.membercarry_id)] = input.membercarry_id; + visualDevModelCrInput.data[nameof(WmsCarrybindH.membercarry_code)] = input.membercarry_code; + visualDevModelCrInput.data[nameof(WmsCarrybindH.type)] = 0; + visualDevModelCrInput.data[nameof(WmsCarrybindH.carrystd_id)] = carry.carrystd_id; + visualDevModelCrInput.data[nameof(WmsCarrybindH.create_id)] = input.create_id; + visualDevModelCrInput.data[nameof(WmsCarrybindH.create_time)] = DateTime.Now; + visualDevModelCrInput.data[nameof(WmsCarrybindH.loc)] = 1; + VisualDevEntity? templateEntity = await _visualDevService.GetInfoById(ModuleConsts.MODULE_WMSCARRYBIND_ID, true); + await _runService.Create(templateEntity, visualDevModelCrInput); + + await db.Ado.CommitTranAsync(); + } + else + { + if (carry == null) + { + throw new AppFriendlyException("没有可用的主载具", 500); + } } } - else + catch (Exception ex) { - if (carry == null) - { - throw new AppFriendlyException("没有可用的主载具", 500); - } + await db.Ado.RollbackTranAsync(); + return await ToApiResult(JNPF.Common.Enums.HttpStatusCode.InternalServerError, ex.Message); } } - catch (Exception ex) - { - } - return Task.FromResult(true); + + return await ToApiResult(JNPF.Common.Enums.HttpStatusCode.OK, "成功"); } /// @@ -315,6 +357,7 @@ namespace Tnb.WarehouseMgr } catch (Exception ex) { + return await ToApiResult(JNPF.Common.Enums.HttpStatusCode.InternalServerError, ex.Message); } return Task.FromResult(true); } diff --git a/WarehouseMgr/Tnb.WarehouseMgr/WmsMaterialTransferService.cs b/WarehouseMgr/Tnb.WarehouseMgr/WmsMaterialTransferService.cs index e54c8c74..ea4ac6af 100644 --- a/WarehouseMgr/Tnb.WarehouseMgr/WmsMaterialTransferService.cs +++ b/WarehouseMgr/Tnb.WarehouseMgr/WmsMaterialTransferService.cs @@ -35,6 +35,8 @@ using JNPF.Systems.Entitys.System; using JNPF.Systems.Entitys.Permission; using Aop.Api.Domain; using Senparc.Weixin.Work.AdvancedAPIs.OaDataOpen; +using NPOI.SS.Formula.Functions; +using Org.BouncyCastle.Asn1.X509; namespace Tnb.WarehouseMgr { @@ -52,6 +54,7 @@ namespace Tnb.WarehouseMgr private readonly IWareHouseService _wareHouseService; private readonly IBillRullService _billRullService; private readonly IUserManager _userManager; + private readonly IWmsCarryBindService _wmsCarryBindService; public static SemaphoreSlim s_taskDistributeToZCC = new(1); @@ -62,7 +65,8 @@ namespace Tnb.WarehouseMgr IWareHouseService wareHouseService, IUserManager userManager, IBillRullService billRullService, - IEventPublisher eventPublisher) + IEventPublisher eventPublisher, + IWmsCarryBindService wmsCarryBindService) { _db = repository.AsSugarClient(); _runService = runService; @@ -70,6 +74,7 @@ namespace Tnb.WarehouseMgr _wareHouseService = wareHouseService; _userManager = userManager; _billRullService = billRullService; + _wmsCarryBindService = wmsCarryBindService; OverideFuncs.GetListAsync = GetList; } @@ -650,8 +655,8 @@ namespace Tnb.WarehouseMgr .Where((a, b) => input.details.Select(r => r.carry_code).Contains(a.carry_code)).Select((a, b) => b).ToList(); if (wmsCarryCodes.Count > 0) { - Logger.LogWarning($"【RackEmptyInstock】存在非空料箱{string.Join(',', wmsCarryCodes.Select(r => r.carry_code).Distinct())},不能入库!{input.carry_code}"); - throw new AppFriendlyException($"【RackEmptyInstock】存在非空料箱{string.Join(',', wmsCarryCodes.Select(r => r.carry_code).Distinct())},不能入库!{input.carry_code}!", 500); + Logger.LogWarning($"【RackEmptyInstock】存在非空料箱,不能入库!{input.carry_code}"); + throw new AppFriendlyException($"【RackEmptyInstock】存在非空料箱,不能入库!{input.carry_code}!", 500); } } @@ -668,10 +673,45 @@ namespace Tnb.WarehouseMgr BasLocation endlocation = rackEndLocations.First(); + WmsCarryH wmsCarryH = await _db.Queryable().Where(r => r.carry_code == input.carry_code).FirstAsync(); + // 重新绑定料箱到料架 + // 清空料架 + Logger.LogWarning($"【RackEmptyInstock】清空料架"); - CommonCreatePretaskInput commonCreatePretaskInput = new CommonCreatePretaskInput(); + List membercarrys = _db.Queryable().Where(r => input.details.Select(r => r.carry_code).Contains(r.carry_code)).ToList(); + + await _db.Ado.BeginTranAsync(); + // 解除绑定料箱到料架 + CarryBindInput carryBindInput = new(); + carryBindInput.carry_id = wmsCarryH.id; + carryBindInput.carry_code = wmsCarryH.carry_code; + var resCarryUnbind = await _wmsCarryBindService.CarryUnbind(carryBindInput); + if (resCarryUnbind.code != JNPF.Common.Enums.HttpStatusCode.OK) + { + throw new AppFriendlyException($"解除绑定料箱到料架失败 载具 {input.carry_code}", 500); + } + Logger.LogWarning($"【RackEmptyInstock】绑定料箱到料架"); + foreach (WmsCarryH membercarry in membercarrys) + { + // 绑定料箱到料架 + CarryBindInput _carryBindInput = new(); + _carryBindInput.carry_id = wmsCarryH.id; + _carryBindInput.carry_code = wmsCarryH.carry_code; + _carryBindInput.membercarry_id = membercarry.id; + _carryBindInput.membercarry_code = membercarry.carry_code; + _carryBindInput.carrystd_id = wmsCarryH.carrystd_id; + var resCarrybind = await _wmsCarryBindService.CarryBind(_carryBindInput); + if (resCarrybind.code != JNPF.Common.Enums.HttpStatusCode.OK) + { + throw new AppFriendlyException($"绑定料箱到料架失败 载具 {input.carry_code}", 500); + } + } + + Logger.LogWarning($"【RackEmptyInstock】开始生成预任务"); + CommonCreatePretaskInput commonCreatePretaskInput = new (); commonCreatePretaskInput.startlocation_id = startlocation.id; commonCreatePretaskInput.endlocation_id = endlocation.id; + commonCreatePretaskInput.carry_id = wmsCarryH.id; commonCreatePretaskInput.carry_code = input.carry_code; commonCreatePretaskInput.task_type = ""; commonCreatePretaskInput.biz_type = "FloorCallMaterial"; @@ -682,11 +722,14 @@ namespace Tnb.WarehouseMgr Logger.LogInformation($"【RackEmptyInstock】生成预任务失败 载具 {input.carry_code}"); throw new AppFriendlyException($"生成预任务失败 载具 {input.carry_code}", 500); } + Logger.LogWarning($"【RackEmptyInstock】生成预任务成功"); + await _db.Ado.CommitTranAsync(); } catch (Exception ex) { Logger.LogError("【RackEmptyInstock】" + ex.Message); Logger.LogError("【RackEmptyInstock】" + ex.StackTrace); + await _db.Ado.RollbackTranAsync(); return await ToApiResult(HttpStatusCode.InternalServerError, ex.Message); } diff --git a/apihost/Tnb.API.Entry/Program.cs b/apihost/Tnb.API.Entry/Program.cs index 45b830c4..5717f4d0 100644 --- a/apihost/Tnb.API.Entry/Program.cs +++ b/apihost/Tnb.API.Entry/Program.cs @@ -1,3 +1,5 @@ +using System.Text.RegularExpressions; + Serve.Run(RunOptions.Default .AddWebComponent().WithArgs(args)); @@ -7,7 +9,6 @@ public class WebComponent : IWebComponent { builder.Host.UseWindowsService(); builder.Configuration.AddJsonFile("Location.json", optional: true, reloadOnChange: true); - //// 日志过滤 //builder.Logging.AddFilter((provider, category, logLevel) => //{ @@ -24,4 +25,6 @@ public class WebComponent : IWebComponent // options.DateFormat = "yyyy-MM-dd HH:mm:ss(zzz) dddd"; //}); } + + } \ No newline at end of file diff --git a/apihost/Tnb.API.Entry/Tnb.API.Entry.csproj b/apihost/Tnb.API.Entry/Tnb.API.Entry.csproj index ad989d53..694abb46 100644 --- a/apihost/Tnb.API.Entry/Tnb.API.Entry.csproj +++ b/apihost/Tnb.API.Entry/Tnb.API.Entry.csproj @@ -5,8 +5,8 @@ enable enable none - false - true + diff --git a/app/Tnb.Apps.Entitys/Tnb.Apps.Entitys.csproj b/app/Tnb.Apps.Entitys/Tnb.Apps.Entitys.csproj index 3c7dd513..91e9762b 100644 --- a/app/Tnb.Apps.Entitys/Tnb.Apps.Entitys.csproj +++ b/app/Tnb.Apps.Entitys/Tnb.Apps.Entitys.csproj @@ -7,7 +7,6 @@ False $(NoWarn);CS8618; Debug;Release;tianyi - false diff --git a/app/Tnb.Apps.Interfaces/Tnb.Apps.Interfaces.csproj b/app/Tnb.Apps.Interfaces/Tnb.Apps.Interfaces.csproj index d7c2cfa5..f86b6da1 100644 --- a/app/Tnb.Apps.Interfaces/Tnb.Apps.Interfaces.csproj +++ b/app/Tnb.Apps.Interfaces/Tnb.Apps.Interfaces.csproj @@ -6,7 +6,6 @@ enable False Debug;Release;tianyi - false diff --git a/app/Tnb.Apps/Tnb.Apps.csproj b/app/Tnb.Apps/Tnb.Apps.csproj index 32d1a872..602d4ac6 100644 --- a/app/Tnb.Apps/Tnb.Apps.csproj +++ b/app/Tnb.Apps/Tnb.Apps.csproj @@ -7,7 +7,6 @@ True $(NoWarn);CS8600;CS8601;CS8602;CS8603;CS8604;CS8625;CS1572;CS1573; Debug;Release;tianyi - false diff --git a/common/Tnb.CollectiveOAuth/Tnb.CollectiveOAuth.csproj b/common/Tnb.CollectiveOAuth/Tnb.CollectiveOAuth.csproj index 640d90e9..d6e59035 100644 --- a/common/Tnb.CollectiveOAuth/Tnb.CollectiveOAuth.csproj +++ b/common/Tnb.CollectiveOAuth/Tnb.CollectiveOAuth.csproj @@ -6,7 +6,6 @@ False $(NoWarn);CS8600;CS8601;CS8602;CS8603;CS8604;CS8618;CS8625;CS1572;CS1573;CS0168; Debug;Release;tianyi - false diff --git a/common/Tnb.Common.Core/Tnb.Common.Core.csproj b/common/Tnb.Common.Core/Tnb.Common.Core.csproj index 01637727..08b9033e 100644 --- a/common/Tnb.Common.Core/Tnb.Common.Core.csproj +++ b/common/Tnb.Common.Core/Tnb.Common.Core.csproj @@ -7,7 +7,6 @@ False $(NoWarn);CS8600;CS8601;CS8602;CS8603;CS8604;CS8618;CS8625;CS1572;CS1573;CS0168;CS1998; Debug;Release;tianyi - false diff --git a/common/Tnb.Common/Redis/StackExRedisHelper.cs b/common/Tnb.Common/Redis/StackExRedisHelper.cs index d9b52d1d..1c7649c1 100644 --- a/common/Tnb.Common/Redis/StackExRedisHelper.cs +++ b/common/Tnb.Common/Redis/StackExRedisHelper.cs @@ -41,9 +41,13 @@ namespace Tnb.Common.Redis } // 获取哈希值 - public string GetHash(string key, string field) + public async Task GetHash(string key, string field) { - return _db.HashGet(key, field); + return await _db.HashGetAsync(key, field); + } + public async Task HashExists(string key, string field) + { + return await _db.HashExistsAsync(key, field); } // 存储列表值 @@ -65,7 +69,7 @@ namespace Tnb.Common.Redis { if (_db.HashExists(key, field)) { - string data = GetHash(key, field); + string data = await GetHash(key, field); Dictionary json = JsonConvert.DeserializeObject>(data); Type type = typeof(T); if ((!type.IsValueType && type.GetGenericArguments().Length > 0) || (type.IsGenericType && type.GetGenericTypeDefinition() == typeof(Nullable<>))) diff --git a/common/Tnb.Common/Tnb.Common.csproj b/common/Tnb.Common/Tnb.Common.csproj index 75a65b14..e27edd45 100644 --- a/common/Tnb.Common/Tnb.Common.csproj +++ b/common/Tnb.Common/Tnb.Common.csproj @@ -9,7 +9,6 @@ False $(NoWarn);CS8600;CS8601;CS8602;CS8603;CS8604;CS8605;CS8618;CS8619;CS8625;CS1572;CS1573; Debug;Release;tianyi - false diff --git a/common/Tnb.SqlSugar/Tnb.SqlSugar.csproj b/common/Tnb.SqlSugar/Tnb.SqlSugar.csproj index 3b764930..87c80703 100644 --- a/common/Tnb.SqlSugar/Tnb.SqlSugar.csproj +++ b/common/Tnb.SqlSugar/Tnb.SqlSugar.csproj @@ -11,7 +11,6 @@ $(NoWarn);CS1591; False Debug;Release;tianyi - false diff --git a/common/Tnb.Thirdparty/Tnb.Thirdparty.csproj b/common/Tnb.Thirdparty/Tnb.Thirdparty.csproj index d7f6fece..a89997d5 100644 --- a/common/Tnb.Thirdparty/Tnb.Thirdparty.csproj +++ b/common/Tnb.Thirdparty/Tnb.Thirdparty.csproj @@ -8,7 +8,6 @@ False $(NoWarn);CS8600;CS8601;CS8602;CS8603;CS8604;CS8618;CS8625;CS1572;CS1573;CS0168;CS0618; Debug;Release;tianyi - false diff --git a/common/Tnb.WebSockets/Tnb.WebSockets.csproj b/common/Tnb.WebSockets/Tnb.WebSockets.csproj index a64773e5..7800fba6 100644 --- a/common/Tnb.WebSockets/Tnb.WebSockets.csproj +++ b/common/Tnb.WebSockets/Tnb.WebSockets.csproj @@ -8,7 +8,6 @@ False $(NoWarn);CS8600;CS8601;CS8602;CS8603;CS8604;CS8618;CS1572;CS1573;CS1998; Debug;Release;tianyi - false diff --git a/message/Tnb.Message.Entitys/Tnb.Message.Entitys.csproj b/message/Tnb.Message.Entitys/Tnb.Message.Entitys.csproj index 3c7dd513..91e9762b 100644 --- a/message/Tnb.Message.Entitys/Tnb.Message.Entitys.csproj +++ b/message/Tnb.Message.Entitys/Tnb.Message.Entitys.csproj @@ -7,7 +7,6 @@ False $(NoWarn);CS8618; Debug;Release;tianyi - false diff --git a/message/Tnb.Message.Interfaces/Tnb.Message.Interfaces.csproj b/message/Tnb.Message.Interfaces/Tnb.Message.Interfaces.csproj index f0a2ec26..82a14c27 100644 --- a/message/Tnb.Message.Interfaces/Tnb.Message.Interfaces.csproj +++ b/message/Tnb.Message.Interfaces/Tnb.Message.Interfaces.csproj @@ -7,7 +7,6 @@ False $(NoWarn);CS8625; Debug;Release;tianyi - false diff --git a/message/Tnb.Message/Tnb.Message.csproj b/message/Tnb.Message/Tnb.Message.csproj index f532b044..532b9e1f 100644 --- a/message/Tnb.Message/Tnb.Message.csproj +++ b/message/Tnb.Message/Tnb.Message.csproj @@ -7,7 +7,6 @@ True $(NoWarn);CS8600;CS8601;CS8602;CS8603;CS8604;CS8625;CS1572;CS1573;CS0168; Debug;Release;tianyi - false diff --git a/system/Tnb.OAuth/Tnb.OAuth.csproj b/system/Tnb.OAuth/Tnb.OAuth.csproj index afe5680d..0abba9be 100644 --- a/system/Tnb.OAuth/Tnb.OAuth.csproj +++ b/system/Tnb.OAuth/Tnb.OAuth.csproj @@ -7,7 +7,6 @@ True $(NoWarn);CS8600;CS8601;CS8602;CS8603;CS8604;CS8618;CS8625;CS1572;CS1573; Debug;Release;tianyi - false diff --git a/system/Tnb.Systems.Entitys/Tnb.Systems.Entitys.csproj b/system/Tnb.Systems.Entitys/Tnb.Systems.Entitys.csproj index 742281bb..3eb5ce90 100644 --- a/system/Tnb.Systems.Entitys/Tnb.Systems.Entitys.csproj +++ b/system/Tnb.Systems.Entitys/Tnb.Systems.Entitys.csproj @@ -7,7 +7,6 @@ False $(NoWarn);CS8603;CS8618; Debug;Release;tianyi - false diff --git a/system/Tnb.Systems.Interfaces/Tnb.Systems.Interfaces.csproj b/system/Tnb.Systems.Interfaces/Tnb.Systems.Interfaces.csproj index 59e33b4b..2cc455e7 100644 --- a/system/Tnb.Systems.Interfaces/Tnb.Systems.Interfaces.csproj +++ b/system/Tnb.Systems.Interfaces/Tnb.Systems.Interfaces.csproj @@ -7,7 +7,6 @@ False $(NoWarn);CS8625; Debug;Release;tianyi - false diff --git a/system/Tnb.Systems/Tnb.Systems.csproj b/system/Tnb.Systems/Tnb.Systems.csproj index 2d32bc3a..ef1765d0 100644 --- a/system/Tnb.Systems/Tnb.Systems.csproj +++ b/system/Tnb.Systems/Tnb.Systems.csproj @@ -7,7 +7,6 @@ True $(NoWarn);CS8600;CS8601;CS8602;CS8603;CS8604;CS8619;CS8625;CS8629;CS1572;CS1573;CS0168;CS4014;CS1998; Debug;Release;tianyi - false diff --git a/taskschedule/Tnb.TaskScheduler.Entitys/Tnb.TaskScheduler.Entitys.csproj b/taskschedule/Tnb.TaskScheduler.Entitys/Tnb.TaskScheduler.Entitys.csproj index 5bcb8c4a..76ff6275 100644 --- a/taskschedule/Tnb.TaskScheduler.Entitys/Tnb.TaskScheduler.Entitys.csproj +++ b/taskschedule/Tnb.TaskScheduler.Entitys/Tnb.TaskScheduler.Entitys.csproj @@ -7,7 +7,6 @@ False $(NoWarn)CS8604;CS8618; Debug;Release;tianyi - false diff --git a/taskschedule/Tnb.TaskScheduler.Interfaces/Tnb.TaskScheduler.Interfaces.csproj b/taskschedule/Tnb.TaskScheduler.Interfaces/Tnb.TaskScheduler.Interfaces.csproj index 7aa58aee..06e5f273 100644 --- a/taskschedule/Tnb.TaskScheduler.Interfaces/Tnb.TaskScheduler.Interfaces.csproj +++ b/taskschedule/Tnb.TaskScheduler.Interfaces/Tnb.TaskScheduler.Interfaces.csproj @@ -6,7 +6,6 @@ enable False Debug;Release;tianyi - false diff --git a/taskschedule/Tnb.TaskScheduler/Tnb.TaskScheduler.csproj b/taskschedule/Tnb.TaskScheduler/Tnb.TaskScheduler.csproj index a78c6a54..64004e32 100644 --- a/taskschedule/Tnb.TaskScheduler/Tnb.TaskScheduler.csproj +++ b/taskschedule/Tnb.TaskScheduler/Tnb.TaskScheduler.csproj @@ -7,7 +7,6 @@ True $(NoWarn);CS8600;CS8601;CS8602;CS8603;CS8604;CS8625;CS1572;CS1573; Debug;Release;tianyi - false diff --git a/visualdev/Tnb.Vengine/Tnb.Vengine.csproj b/visualdev/Tnb.Vengine/Tnb.Vengine.csproj index d1e6e0a6..76ce863d 100644 --- a/visualdev/Tnb.Vengine/Tnb.Vengine.csproj +++ b/visualdev/Tnb.Vengine/Tnb.Vengine.csproj @@ -5,7 +5,6 @@ enable enable Debug;Release;tianyi - false diff --git a/visualdev/Tnb.VisualDev.Engine/Tnb.VisualDev.Engine.csproj b/visualdev/Tnb.VisualDev.Engine/Tnb.VisualDev.Engine.csproj index 9d962edb..39aadc75 100644 --- a/visualdev/Tnb.VisualDev.Engine/Tnb.VisualDev.Engine.csproj +++ b/visualdev/Tnb.VisualDev.Engine/Tnb.VisualDev.Engine.csproj @@ -7,7 +7,6 @@ False $(NoWarn);CS8600;CS8601;CS8602;CS8603;CS8604;CS8618;CS8625;CS8629;CS1572;CS1573;CS0168; Debug;Release;tianyi - false diff --git a/visualdev/Tnb.VisualDev.Entitys/Tnb.VisualDev.Entitys.csproj b/visualdev/Tnb.VisualDev.Entitys/Tnb.VisualDev.Entitys.csproj index 3c7dd513..91e9762b 100644 --- a/visualdev/Tnb.VisualDev.Entitys/Tnb.VisualDev.Entitys.csproj +++ b/visualdev/Tnb.VisualDev.Entitys/Tnb.VisualDev.Entitys.csproj @@ -7,7 +7,6 @@ False $(NoWarn);CS8618; Debug;Release;tianyi - false diff --git a/visualdev/Tnb.VisualDev.Interfaces/Tnb.VisualDev.Interfaces.csproj b/visualdev/Tnb.VisualDev.Interfaces/Tnb.VisualDev.Interfaces.csproj index 89bbc55e..b05836bd 100644 --- a/visualdev/Tnb.VisualDev.Interfaces/Tnb.VisualDev.Interfaces.csproj +++ b/visualdev/Tnb.VisualDev.Interfaces/Tnb.VisualDev.Interfaces.csproj @@ -6,7 +6,6 @@ enable False Debug;Release;tianyi - false diff --git a/visualdev/Tnb.VisualDev/Tnb.VisualDev.csproj b/visualdev/Tnb.VisualDev/Tnb.VisualDev.csproj index 8ec137c9..737ec225 100644 --- a/visualdev/Tnb.VisualDev/Tnb.VisualDev.csproj +++ b/visualdev/Tnb.VisualDev/Tnb.VisualDev.csproj @@ -7,7 +7,6 @@ True $(NoWarn);CS8600;CS8601;CS8602;CS8603;CS8604;CS8625;CS8629;CS1572;CS1573;CS0168; Debug;Release;tianyi - false diff --git a/workflow/Tnb.WorkFlow.Entitys/Tnb.WorkFlow.Entitys.csproj b/workflow/Tnb.WorkFlow.Entitys/Tnb.WorkFlow.Entitys.csproj index bd8d37cf..1d28267e 100644 --- a/workflow/Tnb.WorkFlow.Entitys/Tnb.WorkFlow.Entitys.csproj +++ b/workflow/Tnb.WorkFlow.Entitys/Tnb.WorkFlow.Entitys.csproj @@ -7,7 +7,6 @@ False $(NoWarn);CS8618; Debug;Release;tianyi - false diff --git a/workflow/Tnb.WorkFlow.Interfaces/Tnb.WorkFlow.Interfaces.csproj b/workflow/Tnb.WorkFlow.Interfaces/Tnb.WorkFlow.Interfaces.csproj index 5e4df15c..f6218d45 100644 --- a/workflow/Tnb.WorkFlow.Interfaces/Tnb.WorkFlow.Interfaces.csproj +++ b/workflow/Tnb.WorkFlow.Interfaces/Tnb.WorkFlow.Interfaces.csproj @@ -7,7 +7,6 @@ False $(NoWarn);CS8625; Debug;Release;tianyi - false diff --git a/workflow/Tnb.WorkFlow/Tnb.WorkFlow.csproj b/workflow/Tnb.WorkFlow/Tnb.WorkFlow.csproj index 8072e9b3..5d764794 100644 --- a/workflow/Tnb.WorkFlow/Tnb.WorkFlow.csproj +++ b/workflow/Tnb.WorkFlow/Tnb.WorkFlow.csproj @@ -7,7 +7,6 @@ True $(NoWarn);CS8600;CS8601;CS8602;CS8603;CS8604;CS8619;CS8620;CS8625;CS8629;CS1572;CS1573;CS0168;CS4014;CS1998; Debug;Release;tianyi - false