|
@@ -95,11 +95,12 @@ export function useSubmit({
|
|
|
e.preventDefault();
|
|
|
|
|
|
const listStr = list.join(',');
|
|
|
- const {menu} = parseMenuTreeList(listStr);
|
|
|
+ const {menu, antd} = parseMenuTreeList(listStr);
|
|
|
|
|
|
mutate({
|
|
|
id,
|
|
|
menu,
|
|
|
+ menuBefore: antd,
|
|
|
});
|
|
|
}
|
|
|
|
|
@@ -121,7 +122,7 @@ export function useWatchId(id: string, visible: boolean) {
|
|
|
const res = data?.find(val => String(val.id) === id);
|
|
|
|
|
|
if (res) {
|
|
|
- const menuList = res?.menu ? res.menu.split(',').slice(0, -1) : [];
|
|
|
+ const menuList = res?.menuBefore ? res.menuBefore.split(',') : [];
|
|
|
|
|
|
dispatch(menuList);
|
|
|
}
|