李昊 4 年之前
父節點
當前提交
41830ffd48
共有 1 個文件被更改,包括 1 次插入1 次删除
  1. 1 1
      gx_api/GxPress/Repository/GxPress.Repository.Implement/Media/MediaRepository.cs

+ 1 - 1
gx_api/GxPress/Repository/GxPress.Repository.Implement/Media/MediaRepository.cs

@@ -793,7 +793,6 @@ namespace GxPress.Repository.Implement.Media
                 query.WhereIn(nameof(Entity.tede2.Media.Media.Id), request.MediaIds);
             if (request.TeacherId != null && request.TeacherId.Count > 0)
                 query.WhereIn(nameof(Entity.tede2.Media.Media.TeacherId), request.TeacherId);
-            resut.Total = await _repository.CountAsync(query);
             if (!string.IsNullOrEmpty(request.BeginTime) && !string.IsNullOrEmpty(request.EndTime))
             {
                 query.Where(nameof(Entity.tede2.Media.Media.AddDate), ">=", request.BeginTime);
@@ -803,6 +802,7 @@ namespace GxPress.Repository.Implement.Media
             {
                 query.OrWhereIn(nameof(Entity.tede2.Media.Media.Press), request.Press);
             }
+            resut.Total = await _repository.CountAsync(query);
             if (!string.IsNullOrEmpty(request.Sort))
             {
                 if (request.Sort.Equals("0"))