|
|
@ -42,7 +42,7 @@ public class MenuModel {
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
public String getMenuJson() throws JsonProcessingException {
|
|
|
|
public String getMenuJson() throws JsonProcessingException {
|
|
|
|
List<Menu> rootMenu = fetchMenu(-1); // 从父ID为-1开始递归
|
|
|
|
List<Menu> rootMenu = fetchMenu(160); // 从父ID为-1开始递归
|
|
|
|
//输出JSON格式
|
|
|
|
//输出JSON格式
|
|
|
|
ObjectMapper mapper = new ObjectMapper();
|
|
|
|
ObjectMapper mapper = new ObjectMapper();
|
|
|
|
String json = mapper.writeValueAsString(rootMenu.getFirst());
|
|
|
|
String json = mapper.writeValueAsString(rootMenu.getFirst());
|
|
|
|