leiy 1 год назад
Родитель
Сommit
cd75ef2599

+ 1 - 3
OASystem/OASystem.Api/Controllers/SystemController.cs

@@ -179,10 +179,8 @@ namespace OASystem.API.Controllers
                     }
                     else if (dto.Type == 2) //2 任务操作通知
                     {
-
                         //任务通知 TaskNotification
-                        List<int> taskTypeList = new List<int>() { 6 };
-                        var taskNotificationData = _readableMsgList.Where(it => taskTypeList.Contains(it.Type)).OrderBy(it => it.IsRead).ToList();
+                        var taskNotificationData = _readableMsgList.Where(it => _taskTypeList.Contains(it.Type)).OrderBy(it => it.IsRead).ToList();
                         int taskNotificationDataCount = taskNotificationData.Count;
                         // 计算起始索引和结束索引
                         int taskStartIndex = (currentPage - 1) * pageSize;

+ 2 - 2
OASystem/OASystem.Infrastructure/Repositories/System/MessageRepository.cs

@@ -222,8 +222,8 @@ namespace OASystem.Infrastructure.Repositories.System
                     foreach (var item in msgTypeData)
                     {
                         //1021	团组操作通知 1020	任务操作通知
-                        if (item.Id == 1020) item.UnReadCount = operationNotificationDataCount;
-                        else if (item.Id == 1021) item.UnReadCount = taskNotificationDataCount;
+                        if (item.Id == 1020) item.UnReadCount = taskNotificationDataCount;
+                        else if (item.Id == 1021) item.UnReadCount = operationNotificationDataCount ;
                     }
 
                     result.Code = 0;