diff --git a/SPMS.Application/DTOs/Stats/DashboardResponseDto.cs b/SPMS.Application/DTOs/Stats/DashboardResponseDto.cs index 0d72d5b..a3fdce9 100644 --- a/SPMS.Application/DTOs/Stats/DashboardResponseDto.cs +++ b/SPMS.Application/DTOs/Stats/DashboardResponseDto.cs @@ -69,4 +69,7 @@ public class TopMessageDto [JsonPropertyName("success_count")] public int SuccessCount { get; set; } + + [JsonPropertyName("status")] + public string Status { get; set; } = string.Empty; } diff --git a/SPMS.Application/Services/StatsService.cs b/SPMS.Application/Services/StatsService.cs index 45e1741..6a8776c 100644 --- a/SPMS.Application/Services/StatsService.cs +++ b/SPMS.Application/Services/StatsService.cs @@ -457,7 +457,8 @@ public class StatsService : IStatsService Title = m.Title, ServiceName = m.ServiceName, TotalSendCount = m.TotalSendCount, - SuccessCount = m.SuccessCount + SuccessCount = m.SuccessCount, + Status = SendStatus.Determine(m.TotalSendCount, m.SuccessCount) }).ToList() }; }