|
@@ -1,4 +1,5 @@
|
|
using Hotline.FlowEngine.Notifies;
|
|
using Hotline.FlowEngine.Notifies;
|
|
|
|
+using Hotline.KnowledgeBase;
|
|
using Hotline.Settings;
|
|
using Hotline.Settings;
|
|
using Hotline.Share.Enums.Order;
|
|
using Hotline.Share.Enums.Order;
|
|
using MediatR;
|
|
using MediatR;
|
|
@@ -7,10 +8,10 @@ namespace Hotline.Application.Handlers.FlowEngine;
|
|
|
|
|
|
public class EndWorkflowHandler : INotificationHandler<EndWorkflowNotify>
|
|
public class EndWorkflowHandler : INotificationHandler<EndWorkflowNotify>
|
|
{
|
|
{
|
|
-
|
|
|
|
- public EndWorkflowHandler()
|
|
|
|
|
|
+ private readonly KnowledgeDomainService _knowledgeDomainService;
|
|
|
|
+ public EndWorkflowHandler(KnowledgeDomainService knowledgeDomainService)
|
|
{
|
|
{
|
|
-
|
|
|
|
|
|
+ _knowledgeDomainService = knowledgeDomainService;
|
|
}
|
|
}
|
|
|
|
|
|
/// <summary>Handles a notification</summary>
|
|
/// <summary>Handles a notification</summary>
|
|
@@ -22,6 +23,11 @@ public class EndWorkflowHandler : INotificationHandler<EndWorkflowNotify>
|
|
|
|
|
|
switch (workflow.ModuleCode)
|
|
switch (workflow.ModuleCode)
|
|
{
|
|
{
|
|
|
|
+ case WorkflowModuleConsts.KnowledgeAdd://新增
|
|
|
|
+ case WorkflowModuleConsts.KnowledgeUpdate://修改
|
|
|
|
+ case WorkflowModuleConsts.KnowledgeDelete://删除
|
|
|
|
+ await _knowledgeDomainService.EndWorkKnowledge(workflow, cancellationToken);
|
|
|
|
+ break;
|
|
case WorkflowModuleConsts.TelRestApply:
|
|
case WorkflowModuleConsts.TelRestApply:
|
|
//TODO 审核通过
|
|
//TODO 审核通过
|
|
//notification.Workflow.ExternalId;
|
|
//notification.Workflow.ExternalId;
|