diff --git a/waynboot-mobile-api/src/main/java/com/wayn/mobile/api/controller/CategoryController.java b/waynboot-mobile-api/src/main/java/com/wayn/mobile/api/controller/CategoryController.java index 7ff7d45..d44dc94 100644 --- a/waynboot-mobile-api/src/main/java/com/wayn/mobile/api/controller/CategoryController.java +++ b/waynboot-mobile-api/src/main/java/com/wayn/mobile/api/controller/CategoryController.java @@ -38,4 +38,14 @@ public class CategoryController { success.add("subCategoryList", subCategoryList); return success; } + + @GetMapping("content") + public R content(Long id) { + R success = R.success(); + Category currentCategory = iCategoryService.getById(id); + List subCategoryList = iCategoryService.selectCategoryByPid(id); + success.add("currentCategory", currentCategory); + success.add("subCategoryList", subCategoryList); + return success; + } }