add(); } /** * 修改菜单 * @param AuthRequest $request * @return array * @throws ContainerExceptionInterface * @throws NotFoundExceptionInterface */ #[RequestMapping(path: "menu_edit", methods: "POST")] #[Scene(scene: "menu_edit")] public function menuEdit(AuthRequest $request) { return (new RoleMenuService)->edit(); } /** * @param AuthRequest $request * @return array * @throws ContainerExceptionInterface * @throws NotFoundExceptionInterface * @throws \RedisException */ #[RequestMapping(path: "menu_del", methods: "GET")] #[Scene(scene: "menu_del")] public function menuDel(AuthRequest $request) { return (new RoleMenuService)->del(); } /** * 菜单列表 * @return array * @throws ContainerExceptionInterface * @throws NotFoundExceptionInterface * @throws \RedisException */ #[RequestMapping(path: "menu_list", methods: "GET")] public function menuList() { return (new RoleMenuService)->handle(); } /** * 菜单详情 * @param AuthRequest $request * @return array */ #[RequestMapping(path: "menu", methods: "GET")] #[Scene(scene: "menu_info")] public function menu(AuthRequest $request) { return (new RoleMenuService)->details(); } /** * 构建菜单缓存 * @return array * @throws ContainerExceptionInterface * @throws NotFoundExceptionInterface * @throws \RedisException */ #[RequestMapping(path: "menu_build_cache", methods: "GET")] public function buildMenuCache() { return (new RoleMenuService)->buildCache(); } public function role_add(AuthRequest $request) { return (new RoleService)->add(); } public function role_edit() { return (new RoleService)->edit(); } public function role_status() { return (new RoleService)->changeStatus(); } public function role_list() { return (new RoleService)->handle(); } #[RequestMapping(path: "role", methods: "GET")] #[Scene(scene: "role_info")] public function role(AuthRequest $request) { return (new RoleService)->details(); } }