提交roll日创建

This commit is contained in:
2026-07-14 18:46:20 +08:00
parent 6971daf9a7
commit 01444937bd
6 changed files with 66 additions and 11 deletions
@@ -122,21 +122,13 @@ public class SysMenuController extends BaseController
}
/**
* 删除菜单
* 删除菜单(存在子菜单时级联删除)
*/
@PreAuthorize("@ss.hasPermi('system:menu:remove')")
@Log(title = "菜单管理", businessType = BusinessType.DELETE)
@DeleteMapping("/{menuId}")
public AjaxResult remove(@PathVariable("menuId") Long menuId)
{
if (menuService.hasChildByMenuId(menuId))
{
return warn("存在子菜单,不允许删除");
}
if (menuService.checkMenuExistRole(menuId))
{
return warn("菜单已分配,不允许删除");
}
return toAjax(menuService.deleteMenuById(menuId));
}
}