using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Threading.Tasks; using Hotline.FlowEngine.Notifications; using Hotline.Orders; using MediatR; namespace Hotline.Application.Handlers.FlowEngine { public class OrderFinalManageHandler : INotificationHandler { private readonly IOrderDomainService _orderDomainService; public OrderFinalManageHandler(IOrderDomainService orderDomainService) { _orderDomainService = orderDomainService; } /// Handles a notification /// The notification /// Cancellation token public async Task Handle(OrderFinalManageNotify notification, CancellationToken cancellationToken) { await _orderDomainService.FinalManageAsync(notification.Workflow.Id, cancellationToken); } } }