mirror of
https://github.com/PlayEdu/PlayEdu
synced 2025-07-24 02:09:35 +08:00
课程和资源列表返回总数(无任何筛选)
This commit is contained in:
parent
4b653361fe
commit
1ea456bdcf
@ -74,6 +74,7 @@ public class CourseController {
|
||||
data.put("data", result.getData());
|
||||
data.put("total", result.getTotal());
|
||||
data.put("category_count", courseService.getCategoryCount());
|
||||
data.put("pure_total", courseService.total());
|
||||
|
||||
return JsonResponse.data(data);
|
||||
}
|
||||
|
@ -78,6 +78,7 @@ public class ResourceController {
|
||||
HashMap<String, Object> data = new HashMap<>();
|
||||
data.put("result", result);
|
||||
data.put("category_count", resourceService.getCategoryCount(type));
|
||||
data.put("pure_total", resourceService.total(type));
|
||||
|
||||
if (type.equals(BackendConstant.RESOURCE_TYPE_VIDEO)) {
|
||||
List<ResourceVideo> resourceVideos = resourceVideoService.chunksByRids(result.getData().stream().map(Resource::getId).toList());
|
||||
|
Loading…
x
Reference in New Issue
Block a user