diff --git a/ProductionMgr/Tnb.ProductionMgr/PrdMoTaskService.cs b/ProductionMgr/Tnb.ProductionMgr/PrdMoTaskService.cs index c7438c96..b9f90097 100644 --- a/ProductionMgr/Tnb.ProductionMgr/PrdMoTaskService.cs +++ b/ProductionMgr/Tnb.ProductionMgr/PrdMoTaskService.cs @@ -1062,7 +1062,7 @@ namespace Tnb.ProductionMgr throw new ArgumentNullException(nameof(input.TaskIds)); } // if (input.Behavior.IsNullOrWhiteSpace()) - if (input.Behavior!=null && !input.Behavior.IsEmpty()) + if (input.Behavior==null || input.Behavior.IsEmpty()) { throw new ArgumentException($"{nameof(input.Behavior)} not be null or empty"); } diff --git a/ProductionMgr/Tnb.ProductionMgr/TimeWorkService.cs b/ProductionMgr/Tnb.ProductionMgr/TimeWorkService.cs index 821c94b9..73330d23 100644 --- a/ProductionMgr/Tnb.ProductionMgr/TimeWorkService.cs +++ b/ProductionMgr/Tnb.ProductionMgr/TimeWorkService.cs @@ -216,8 +216,8 @@ namespace Tnb.ProductionMgr public async Task FixedPointDelivery() { string msg = ""; - bool? value = await _redisData.TryGetValueByKeyField("hxjC", "DB100.132.3"); - bool valueFlag = _redisData.Get("hxjC_DB100.132.3_flag"); + bool? value = await _redisData.TryGetValueByKeyField("hxjC", "A2允许入空箱"); + bool valueFlag = _redisData.Get("hxjC_A2允许入空箱_flag"); if (value==true && !valueFlag) { bool? cs01 = await _redisData.TryGetValueByKeyField("YTCS", "CallCtuEmptyIn_CS01"); @@ -252,7 +252,7 @@ namespace Tnb.ProductionMgr { msg = "注塑定点配送成功"; Log.Information("【FixedPointDelivery】注塑定点配送成功"); - _redisData.Set("hxjC_DB100.132.3_flag", true, TimeSpan.FromMinutes(20)); + _redisData.Set("hxjC_A2允许入空箱_flag", true, TimeSpan.FromMinutes(20)); } else { diff --git a/system/Tnb.Systems/Permission/DepartmentService.cs b/system/Tnb.Systems/Permission/DepartmentService.cs index 98f97aa8..0e00d473 100644 --- a/system/Tnb.Systems/Permission/DepartmentService.cs +++ b/system/Tnb.Systems/Permission/DepartmentService.cs @@ -518,7 +518,7 @@ public class DepartmentService : IDepartmentService, IDynamicApiController, ITra { var jsonObj = input.propertyJson; var eqpVal = jsonObj.GetValue("roweqp"); - if (eqpVal is not null) + if (eqpVal is not null && eqpVal.Count()>0) { var eqpList = (jsonObj.Value("roweqp")); var eqpIds = eqpList.Select(x => x.Value("id")).ToList(); @@ -550,7 +550,7 @@ public class DepartmentService : IDepartmentService, IDynamicApiController, ITra await _repository.AsSugarClient().Insertable(OrganizeRelationEntitys).ExecuteCommandAsync(); } var processVal = jsonObj.GetValue("rowprocess"); - if (processVal is not null) + if (processVal is not null && processVal.Count()>0) { //modifyby zhoukeda 2023.06.25 var dic = _repository.GetList(x => x.DeleteMark == null).ToDictionary(x => x.FullName, x => x.Id); @@ -583,7 +583,7 @@ public class DepartmentService : IDepartmentService, IDynamicApiController, ITra } } var correlation = jsonObj.GetValue("correlation"); - if (correlation is not null) + if (correlation is not null && correlation.Count()>0) { await _repository.AsSugarClient().Deleteable(p => p.OrganizeId == id && p.ObjectType == "User").ExecuteCommandAsync(); var OrganizeRelationEntitys = new List();