halo/ui/console-src
Ryan Wang 3f5b69d5d0
Support async permission checks in route menu generator (#7688)
#### What type of PR is this?

/area ui
/kind feature
/milestone 2.21.x

#### What this PR does / why we need it:

Support async permission checks in route menu generator

example:

```ts
{
  path: "",
  name: "Foo",
  component: Foo,
  meta: {
    title: "Foo",
    searchable: true,
    permissions: async () => {
      const { data } = await checkPermission();
      return data;
    },
    menu: {
      name: "Foo",
      group: "content",
      icon: markRaw(MingcuteBook2Line),
      priority: 4,
      mobile: false,
    },
  },
}
```

#### Which issue(s) this PR fixes:

Fixes #

#### Special notes for your reviewer:

#### Does this PR introduce a user-facing change?

```release-note
开发者相关:路由的权限检查支持函数
```
2025-08-17 15:43:10 +00:00
..
composables fix: post slug generation not following selected strategy (#6914) 2024-10-22 06:52:28 +00:00
layouts Support async permission checks in route menu generator (#7688) 2025-08-17 15:43:10 +00:00
modules Support async permission checks in route menu generator (#7688) 2025-08-17 15:43:10 +00:00
router feat: add multi-role assignment support for users (#7037) 2024-11-24 15:48:21 +00:00
setup feat: add prompt for users to reload page after plugin update 2024-08-15 17:30:01 +08:00
stores chore: remove unused code related to system configMap (#6695) 2024-09-24 06:57:20 +00:00
App.vue Move folder console to ui 2024-02-02 22:22:51 +08:00
main.ts chore: use rolldown-vite (#7489) 2025-06-19 16:31:11 +00:00