refactor:将AppDataCenterService改为AppCenterService,将AppDataStorageService改为AppStorageService,将触发器的增删改成合并

This commit is contained in:
2025-10-18 17:18:09 +08:00
parent 816827e5e9
commit 595139fb02
64 changed files with 1159 additions and 599 deletions

View File

@@ -101,7 +101,7 @@ namespace DMS.Application.Services.Triggers.Impl
/// <summary>
/// 内部方法:评估单个触发器的条件
/// </summary>
private bool EvaluateCondition(TriggerDefinitionDto trigger, object currentValueObj)
private bool EvaluateCondition(TriggerDefinition trigger, object currentValueObj)
{
if (currentValueObj == null)
{
@@ -139,7 +139,7 @@ namespace DMS.Application.Services.Triggers.Impl
/// <summary>
/// 内部方法:检查触发器是否处于抑制窗口期内
/// </summary>
private bool IsWithinSuppressionWindow(TriggerDefinitionDto trigger)
private bool IsWithinSuppressionWindow(TriggerDefinition trigger)
{
if (!trigger.SuppressionDuration.HasValue || !trigger.LastTriggeredAt.HasValue)
return false;

View File

@@ -1,6 +1,7 @@
using DMS.Application.DTOs;
using DMS.Core.Models;
using System;
using DMS.Core.Models.Triggers;
namespace DMS.Application.Services.Triggers
{
@@ -10,5 +11,5 @@ namespace DMS.Application.Services.Triggers
/// <param name="Trigger">被触发的触发器定义</param>
/// <param name="CurrentValue">触发时变量的当前值</param>
/// <param name="Variable">关联的变量信息</param>
public record TriggerContext(TriggerDefinitionDto Trigger, object CurrentValue, Variable Variable);
public record TriggerContext(TriggerDefinition Trigger, object CurrentValue, Variable Variable);
}