fix:修复完整预警命中规则逻辑缺失验证检查点状态
This commit is contained in:
parent
53723e87b6
commit
0e88bd23fb
@ -51,28 +51,18 @@ public sealed class CompleteWarningRuleItemEntity : IFullAuditedBasicEntitys, IE
|
|||||||
.ToList();
|
.ToList();
|
||||||
}
|
}
|
||||||
|
|
||||||
// 查看是否能命中这个规则
|
|
||||||
public bool CanHitRule(int orderType, int trackStatusId)
|
|
||||||
{
|
|
||||||
var orderTypes = GetRuleOrderTypes();
|
|
||||||
//没有命中订单类型
|
|
||||||
if (!orderTypes.Contains(orderType))
|
|
||||||
return false;
|
|
||||||
//没有命中状态检查点
|
|
||||||
if (trackStatusId != CheckPointTrackStatusId)
|
|
||||||
return false;
|
|
||||||
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
|
|
||||||
// 查看是否能命中这个规则
|
// 查看是否能命中这个规则
|
||||||
public bool CanHitRule(int orderType, HashSet<int> trackStatusIds)
|
public bool CanHitRule(int orderType, HashSet<int> trackStatusIds)
|
||||||
{
|
{
|
||||||
var orderTypes = GetRuleOrderTypes();
|
var orderTypes = GetRuleOrderTypes();
|
||||||
//没有命中订单类型
|
// 没有命中订单类型
|
||||||
if (!orderTypes.Contains(orderType))
|
if (!orderTypes.Contains(orderType))
|
||||||
return false;
|
return false;
|
||||||
|
|
||||||
|
// 没有命中检查点
|
||||||
|
if (!trackStatusIds.Contains(CheckPointTrackStatusId))
|
||||||
|
return false;
|
||||||
|
|
||||||
//缺失轨迹状态?
|
//缺失轨迹状态?
|
||||||
return ExistsMissingTrackStatus(trackStatusIds);
|
return ExistsMissingTrackStatus(trackStatusIds);
|
||||||
}
|
}
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user