mirror of
https://github.com/PlayEdu/PlayEdu
synced 2025-06-22 11:52:43 +08:00
部门和分类的删除预检查api返回后台children
This commit is contained in:
parent
06bc8c639c
commit
4b653361fe
@ -1,6 +1,5 @@
|
||||
package xyz.playedu.api.controller.backend;
|
||||
|
||||
import cn.hutool.core.lang.hash.Hash;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
import org.apache.commons.collections4.MapUtils;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
|
@ -94,6 +94,7 @@ public class DepartmentController {
|
||||
HashMap<String, Object> data = new HashMap<>();
|
||||
data.put("courses", new ArrayList<>());
|
||||
data.put("users", new ArrayList<>());
|
||||
data.put("children", departmentService.listByParentId(id));
|
||||
|
||||
if (courseIds != null && courseIds.size() > 0) {
|
||||
data.put("courses", courseService.chunks(courseIds, new ArrayList<>() {{
|
||||
|
@ -92,6 +92,7 @@ public class ResourceCategoryController {
|
||||
List<Integer> rids = categoryService.getRidsById(id);
|
||||
|
||||
HashMap<String, Object> data = new HashMap<>();
|
||||
data.put("children", categoryService.listByParentId(id));
|
||||
data.put("courses", new ArrayList<>());
|
||||
data.put("videos", new ArrayList<>());
|
||||
data.put("images", new ArrayList<>());
|
||||
|
Loading…
x
Reference in New Issue
Block a user