查看所有的menu
Api/menu/findAll
get
response
[
{
"_id": "5b6939f9ec4c344a54413b99",
"title": "menu22222",
"subMenu": {
"89ef761ba5874a4b9d8d296abb2da413": {
"_id": "89ef761ba5874a4b9d8d296abb2da413",
"title": "2-1",
"subMenu": {}
},
"ac612ac36484480bab8f74be3da59fc0": {
"_id": "ac612ac36484480bab8f74be3da59fc0",
"title": "2-2",
"subMenu": {}
}
}
},
{
"_id": "1",
"title": "title_xiugai",
"subMenu": {}
}
]
get sub menu
/Api/menu/findById
get
request:{
_id:"5b6939f9ec4c344a54413b99"
}
response:
{
"_id": "5b6939f9ec4c344a54413b99",
"title": "menu22222",
"subMenu": {
"89ef761ba5874a4b9d8d296abb2da413": {
"_id": "89ef761ba5874a4b9d8d296abb2da413",
"title": "2-1",
"subMenu": {}
},
"ac612ac36484480bab8f74be3da59fc0": {
"_id": "ac612ac36484480bab8f74be3da59fc0",
"title": "2-2",
"subMenu": {}
}
}
}
save/修改 menu
url:/Api/menu/save
request:
{
"_id":"",
"title":"menu1"
}
respones
save ok
delete menu
url:/Api/menu/delete
delete
request:
?id=1
delete submenu
url:/Api/menu/deleteSubMenu
delete
@RequestParam String menuId, @RequestParam String subMenuId
add sub menu
url :/Api/menu/saveSubMenu
post
{
menuId
subMenu:{
_id:
title:
}
}
网友评论