fix: move to inner (#6289)

This commit is contained in:
Zeke Zhang 2025-02-25 20:23:17 +08:00 committed by GitHub
parent 76e5e7c1c0
commit e1d891ed3a
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -463,11 +463,23 @@ export const MenuDesigner = () => {
afterEnd: 'insertAfter',
};
// 'beforeEnd' 表示的是插入到一个分组的里面
const options =
position === 'beforeEnd'
? {
targetScope: {
parentId: current.__route__.id,
},
}
: {
targetId: current.__route__.id,
};
await moveRoute({
sourceId: (fieldSchema as any).__route__.id,
targetId: current.__route__.id,
sortField: 'sort',
method: positionToMethod[position],
...options,
});
dn.loadAPIClientEvents();