com-angel-authorization 1.0.14 → 1.0.15

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,5 +1,5 @@
1
1
  import * as vue from 'vue';
2
- import { InjectionKey, ComputedRef, Plugin, Directive, PropType } from 'vue';
2
+ import { InjectionKey, ComputedRef, Plugin, Directive, PropType, VNode } from 'vue';
3
3
 
4
4
  type PermissionCode = string;
5
5
  type RoleCode = string;
@@ -448,7 +448,99 @@ declare const MenuManager: vue.DefineComponent<vue.ExtractPropTypes<{
448
448
  pageSize: string;
449
449
  }, {}, {}, {}, string, vue.ComponentProvideOptions, true, {}, any>;
450
450
 
451
- type SystemAdminMenuKey = 'menu' | 'resource';
451
+ type SystemRole = {
452
+ roleId: string;
453
+ name: string;
454
+ description: string;
455
+ };
456
+ type SystemRoleFormValues = {
457
+ name: string;
458
+ description: string;
459
+ };
460
+ type CreateSystemRoleBody = SystemRoleFormValues;
461
+ type UpdateSystemRoleBody = Partial<SystemRoleFormValues>;
462
+ type FetchSystemRolesParams = {
463
+ keyword?: string;
464
+ pagination?: ListPaginationParams;
465
+ };
466
+ type SystemRoleListResult = {
467
+ records: SystemRole[];
468
+ pageToken: string;
469
+ hasPreviousPage: boolean;
470
+ hasNextPage: boolean;
471
+ };
472
+ /** 角色授权树节点 */
473
+ type RolePermissionTreeNode = {
474
+ resourceId: string;
475
+ name: string;
476
+ children: RolePermissionTreeNode[];
477
+ };
478
+ /** GET /system/roles/{role-id}/permissions */
479
+ type RolePermissionsResult = {
480
+ /** 当前角色已授予的资源 ID,用于树回显勾选 */
481
+ resourceIds: string[];
482
+ resourceTree: RolePermissionTreeNode[];
483
+ };
484
+ /** POST /system/roles/{role-id}/permissions */
485
+ type SaveRolePermissionsBody = {
486
+ resourceIds: string[];
487
+ };
488
+
489
+ type SystemRoleApi = {
490
+ list: (params?: FetchSystemRolesParams, signal?: AbortSignal) => Promise<SystemRoleListResult>;
491
+ create: (values: SystemRoleFormValues, signal?: AbortSignal) => Promise<unknown>;
492
+ update: (roleId: string, values: SystemRoleFormValues, signal?: AbortSignal) => Promise<unknown>;
493
+ remove: (roleId: string, signal?: AbortSignal) => Promise<unknown>;
494
+ getPermissions: (roleId: string, signal?: AbortSignal) => Promise<RolePermissionsResult>;
495
+ savePermissions: (roleId: string, resourceIds: string[], signal?: AbortSignal) => Promise<unknown>;
496
+ };
497
+ declare function mapSystemRole(item: unknown): SystemRole | null;
498
+ declare function mapPermissionTreeNode(item: unknown): RolePermissionTreeNode | null;
499
+ declare function mapRolePermissions(payload: unknown): RolePermissionsResult;
500
+ /** 收集节点及其全部子孙 resourceId */
501
+ declare function collectTreeResourceIds(node: RolePermissionTreeNode): string[];
502
+ declare function buildCreateRoleBody(values: SystemRoleFormValues): CreateSystemRoleBody;
503
+ declare function buildUpdateRoleBody(values: SystemRoleFormValues): UpdateSystemRoleBody;
504
+ declare function buildSavePermissionsBody(resourceIds: string[]): SaveRolePermissionsBody;
505
+ declare function createSystemRoleApi(request: ResourceHttpRequest): SystemRoleApi;
506
+
507
+ /**
508
+ * 角色管理页面(Vue 3)
509
+ */
510
+ declare const RoleManager: vue.DefineComponent<vue.ExtractPropTypes<{
511
+ api: {
512
+ type: PropType<SystemRoleApi>;
513
+ required: true;
514
+ };
515
+ title: {
516
+ type: StringConstructor;
517
+ default: string;
518
+ };
519
+ pageSize: {
520
+ type: StringConstructor;
521
+ default: string;
522
+ };
523
+ }>, () => VNode<vue.RendererNode, vue.RendererElement, {
524
+ [key: string]: any;
525
+ }>, {}, {}, {}, vue.ComponentOptionsMixin, vue.ComponentOptionsMixin, {}, string, vue.PublicProps, Readonly<vue.ExtractPropTypes<{
526
+ api: {
527
+ type: PropType<SystemRoleApi>;
528
+ required: true;
529
+ };
530
+ title: {
531
+ type: StringConstructor;
532
+ default: string;
533
+ };
534
+ pageSize: {
535
+ type: StringConstructor;
536
+ default: string;
537
+ };
538
+ }>> & Readonly<{}>, {
539
+ title: string;
540
+ pageSize: string;
541
+ }, {}, {}, {}, string, vue.ComponentProvideOptions, true, {}, any>;
542
+
543
+ type SystemAdminMenuKey = 'menu' | 'resource' | 'role';
452
544
  type SystemAdminSubMenu = {
453
545
  key: SystemAdminMenuKey;
454
546
  label: string;
@@ -458,12 +550,12 @@ type SystemAdminMenuGroup = {
458
550
  label: string;
459
551
  children: SystemAdminSubMenu[];
460
552
  };
461
- /** 系统管理菜单结构:菜单管理、权限点管理为其子菜单 */
553
+ /** 系统管理菜单结构 */
462
554
  declare const SYSTEM_ADMIN_MENU: SystemAdminMenuGroup;
463
555
  declare const SYSTEM_ADMIN_DEFAULT_KEY: SystemAdminMenuKey;
464
556
 
465
557
  /**
466
- * 系统管理:侧栏父菜单「系统管理」,子菜单为「菜单管理」「权限点管理」。
558
+ * 系统管理:侧栏父菜单「系统管理」,子菜单为菜单 / 权限点 / 角色管理。
467
559
  */
468
560
  declare const SystemAdmin: vue.DefineComponent<vue.ExtractPropTypes<{
469
561
  menuApi: {
@@ -474,6 +566,10 @@ declare const SystemAdmin: vue.DefineComponent<vue.ExtractPropTypes<{
474
566
  type: PropType<AuthorizationResourceApi>;
475
567
  required: true;
476
568
  };
569
+ roleApi: {
570
+ type: PropType<SystemRoleApi>;
571
+ required: true;
572
+ };
477
573
  defaultActiveKey: {
478
574
  type: PropType<SystemAdminMenuKey>;
479
575
  default: SystemAdminMenuKey;
@@ -500,6 +596,10 @@ declare const SystemAdmin: vue.DefineComponent<vue.ExtractPropTypes<{
500
596
  type: PropType<AuthorizationResourceApi>;
501
597
  required: true;
502
598
  };
599
+ roleApi: {
600
+ type: PropType<SystemRoleApi>;
601
+ required: true;
602
+ };
503
603
  defaultActiveKey: {
504
604
  type: PropType<SystemAdminMenuKey>;
505
605
  default: SystemAdminMenuKey;
@@ -551,4 +651,4 @@ declare const snowyflake: ConfigurableSnowflake;
551
651
  declare function getAppClientId(): string;
552
652
  declare function getDeviceWorkerId(): string;
553
653
 
554
- export { type ApiResourceType, type AuthorizationResource, type AuthorizationResourceApi, type AuthorizationResourceFormValues, type AuthorizationResourceListResult, Can, type CheckOptions, type CreateAuthorizationResourceBody, type CreateDefaultResourceRequestOptions, type CreateMenuResourceBody, type FetchAuthorizationResourcesParams, type FetchMenuResourcesParams, type HttpMethod, type ListPaginationParams, type ListPaginationResult, MENU_LEAF_NO, MENU_LEAF_YES, MENU_LIST_TYPE_PARAM, MENU_TYPE_BUTTON, MENU_TYPE_LABEL, MENU_TYPE_MENU, MENU_TYPE_OPTIONS, MENU_TYPE_PAGE, MENU_VISIBILITY_OPTIONS, type MatchMode, MenuManager, type MenuResource, type MenuResourceApi, type MenuResourceFormValues, type MenuResourceListResult, type MenuResourceType, PERMISSION_STORE_KEY, type PageDirection, type PermissionChecker, type PermissionCode, type PermissionDirectiveValue, type PermissionListener, type PermissionPluginOptions, type PermissionState, PermissionStore, type PermissionStoreAPI, RESOURCE_PRIVATE_OPTIONS, RESOURCE_STATUS_DISABLED, RESOURCE_STATUS_ENABLED, RESOURCE_STATUS_OPTIONS, RESOURCE_TYPE_API, ROOT_MENU_DEPTH, ROOT_PARENT_ID, type ResourceHttpRequest, ResourceManager, type ResourceRequestOptions, type ResourceStatus, type ResourceType, type RoleCode, SYSTEM_ADMIN_DEFAULT_KEY, SYSTEM_ADMIN_MENU, SystemAdmin, type SystemAdminMenuGroup, type SystemAdminMenuKey, type SystemAdminSubMenu, type UpdateAuthorizationResourceBody, type UpdateMenuResourceBody, type UsePermissionResult, appendQueryParam, buildCreateBody, buildCreateMenuBody, buildUpdateBody, buildUpdateMenuBody, createAuthorizationResourceApi, createDefaultResourceRequest, createMenuResourceApi, createPermissionPlugin, createPermissionStore, createVPermission, extractPagination, extractRecords, getAppClientId, getDeviceWorkerId, isMenuLeaf, mapAuthorizationResource, mapMenuResource, resolveMenuDepth, snowyflake, useHasPermission, useHasRole, usePermission };
654
+ export { type ApiResourceType, type AuthorizationResource, type AuthorizationResourceApi, type AuthorizationResourceFormValues, type AuthorizationResourceListResult, Can, type CheckOptions, type CreateAuthorizationResourceBody, type CreateDefaultResourceRequestOptions, type CreateMenuResourceBody, type CreateSystemRoleBody, type FetchAuthorizationResourcesParams, type FetchMenuResourcesParams, type FetchSystemRolesParams, type HttpMethod, type ListPaginationParams, type ListPaginationResult, MENU_LEAF_NO, MENU_LEAF_YES, MENU_LIST_TYPE_PARAM, MENU_TYPE_BUTTON, MENU_TYPE_LABEL, MENU_TYPE_MENU, MENU_TYPE_OPTIONS, MENU_TYPE_PAGE, MENU_VISIBILITY_OPTIONS, type MatchMode, MenuManager, type MenuResource, type MenuResourceApi, type MenuResourceFormValues, type MenuResourceListResult, type MenuResourceType, PERMISSION_STORE_KEY, type PageDirection, type PermissionChecker, type PermissionCode, type PermissionDirectiveValue, type PermissionListener, type PermissionPluginOptions, type PermissionState, PermissionStore, type PermissionStoreAPI, RESOURCE_PRIVATE_OPTIONS, RESOURCE_STATUS_DISABLED, RESOURCE_STATUS_ENABLED, RESOURCE_STATUS_OPTIONS, RESOURCE_TYPE_API, ROOT_MENU_DEPTH, ROOT_PARENT_ID, type ResourceHttpRequest, ResourceManager, type ResourceRequestOptions, type ResourceStatus, type ResourceType, type RoleCode, RoleManager, type RolePermissionTreeNode, type RolePermissionsResult, SYSTEM_ADMIN_DEFAULT_KEY, SYSTEM_ADMIN_MENU, type SaveRolePermissionsBody, SystemAdmin, type SystemAdminMenuGroup, type SystemAdminMenuKey, type SystemAdminSubMenu, type SystemRole, type SystemRoleApi, type SystemRoleFormValues, type SystemRoleListResult, type UpdateAuthorizationResourceBody, type UpdateMenuResourceBody, type UpdateSystemRoleBody, type UsePermissionResult, appendQueryParam, buildCreateBody, buildCreateMenuBody, buildCreateRoleBody, buildSavePermissionsBody, buildUpdateBody, buildUpdateMenuBody, buildUpdateRoleBody, collectTreeResourceIds, createAuthorizationResourceApi, createDefaultResourceRequest, createMenuResourceApi, createPermissionPlugin, createPermissionStore, createSystemRoleApi, createVPermission, extractPagination, extractRecords, getAppClientId, getDeviceWorkerId, isMenuLeaf, mapAuthorizationResource, mapMenuResource, mapPermissionTreeNode, mapRolePermissions, mapSystemRole, resolveMenuDepth, snowyflake, useHasPermission, useHasRole, usePermission };
@@ -1,5 +1,5 @@
1
1
  import * as vue from 'vue';
2
- import { InjectionKey, ComputedRef, Plugin, Directive, PropType } from 'vue';
2
+ import { InjectionKey, ComputedRef, Plugin, Directive, PropType, VNode } from 'vue';
3
3
 
4
4
  type PermissionCode = string;
5
5
  type RoleCode = string;
@@ -448,7 +448,99 @@ declare const MenuManager: vue.DefineComponent<vue.ExtractPropTypes<{
448
448
  pageSize: string;
449
449
  }, {}, {}, {}, string, vue.ComponentProvideOptions, true, {}, any>;
450
450
 
451
- type SystemAdminMenuKey = 'menu' | 'resource';
451
+ type SystemRole = {
452
+ roleId: string;
453
+ name: string;
454
+ description: string;
455
+ };
456
+ type SystemRoleFormValues = {
457
+ name: string;
458
+ description: string;
459
+ };
460
+ type CreateSystemRoleBody = SystemRoleFormValues;
461
+ type UpdateSystemRoleBody = Partial<SystemRoleFormValues>;
462
+ type FetchSystemRolesParams = {
463
+ keyword?: string;
464
+ pagination?: ListPaginationParams;
465
+ };
466
+ type SystemRoleListResult = {
467
+ records: SystemRole[];
468
+ pageToken: string;
469
+ hasPreviousPage: boolean;
470
+ hasNextPage: boolean;
471
+ };
472
+ /** 角色授权树节点 */
473
+ type RolePermissionTreeNode = {
474
+ resourceId: string;
475
+ name: string;
476
+ children: RolePermissionTreeNode[];
477
+ };
478
+ /** GET /system/roles/{role-id}/permissions */
479
+ type RolePermissionsResult = {
480
+ /** 当前角色已授予的资源 ID,用于树回显勾选 */
481
+ resourceIds: string[];
482
+ resourceTree: RolePermissionTreeNode[];
483
+ };
484
+ /** POST /system/roles/{role-id}/permissions */
485
+ type SaveRolePermissionsBody = {
486
+ resourceIds: string[];
487
+ };
488
+
489
+ type SystemRoleApi = {
490
+ list: (params?: FetchSystemRolesParams, signal?: AbortSignal) => Promise<SystemRoleListResult>;
491
+ create: (values: SystemRoleFormValues, signal?: AbortSignal) => Promise<unknown>;
492
+ update: (roleId: string, values: SystemRoleFormValues, signal?: AbortSignal) => Promise<unknown>;
493
+ remove: (roleId: string, signal?: AbortSignal) => Promise<unknown>;
494
+ getPermissions: (roleId: string, signal?: AbortSignal) => Promise<RolePermissionsResult>;
495
+ savePermissions: (roleId: string, resourceIds: string[], signal?: AbortSignal) => Promise<unknown>;
496
+ };
497
+ declare function mapSystemRole(item: unknown): SystemRole | null;
498
+ declare function mapPermissionTreeNode(item: unknown): RolePermissionTreeNode | null;
499
+ declare function mapRolePermissions(payload: unknown): RolePermissionsResult;
500
+ /** 收集节点及其全部子孙 resourceId */
501
+ declare function collectTreeResourceIds(node: RolePermissionTreeNode): string[];
502
+ declare function buildCreateRoleBody(values: SystemRoleFormValues): CreateSystemRoleBody;
503
+ declare function buildUpdateRoleBody(values: SystemRoleFormValues): UpdateSystemRoleBody;
504
+ declare function buildSavePermissionsBody(resourceIds: string[]): SaveRolePermissionsBody;
505
+ declare function createSystemRoleApi(request: ResourceHttpRequest): SystemRoleApi;
506
+
507
+ /**
508
+ * 角色管理页面(Vue 3)
509
+ */
510
+ declare const RoleManager: vue.DefineComponent<vue.ExtractPropTypes<{
511
+ api: {
512
+ type: PropType<SystemRoleApi>;
513
+ required: true;
514
+ };
515
+ title: {
516
+ type: StringConstructor;
517
+ default: string;
518
+ };
519
+ pageSize: {
520
+ type: StringConstructor;
521
+ default: string;
522
+ };
523
+ }>, () => VNode<vue.RendererNode, vue.RendererElement, {
524
+ [key: string]: any;
525
+ }>, {}, {}, {}, vue.ComponentOptionsMixin, vue.ComponentOptionsMixin, {}, string, vue.PublicProps, Readonly<vue.ExtractPropTypes<{
526
+ api: {
527
+ type: PropType<SystemRoleApi>;
528
+ required: true;
529
+ };
530
+ title: {
531
+ type: StringConstructor;
532
+ default: string;
533
+ };
534
+ pageSize: {
535
+ type: StringConstructor;
536
+ default: string;
537
+ };
538
+ }>> & Readonly<{}>, {
539
+ title: string;
540
+ pageSize: string;
541
+ }, {}, {}, {}, string, vue.ComponentProvideOptions, true, {}, any>;
542
+
543
+ type SystemAdminMenuKey = 'menu' | 'resource' | 'role';
452
544
  type SystemAdminSubMenu = {
453
545
  key: SystemAdminMenuKey;
454
546
  label: string;
@@ -458,12 +550,12 @@ type SystemAdminMenuGroup = {
458
550
  label: string;
459
551
  children: SystemAdminSubMenu[];
460
552
  };
461
- /** 系统管理菜单结构:菜单管理、权限点管理为其子菜单 */
553
+ /** 系统管理菜单结构 */
462
554
  declare const SYSTEM_ADMIN_MENU: SystemAdminMenuGroup;
463
555
  declare const SYSTEM_ADMIN_DEFAULT_KEY: SystemAdminMenuKey;
464
556
 
465
557
  /**
466
- * 系统管理:侧栏父菜单「系统管理」,子菜单为「菜单管理」「权限点管理」。
558
+ * 系统管理:侧栏父菜单「系统管理」,子菜单为菜单 / 权限点 / 角色管理。
467
559
  */
468
560
  declare const SystemAdmin: vue.DefineComponent<vue.ExtractPropTypes<{
469
561
  menuApi: {
@@ -474,6 +566,10 @@ declare const SystemAdmin: vue.DefineComponent<vue.ExtractPropTypes<{
474
566
  type: PropType<AuthorizationResourceApi>;
475
567
  required: true;
476
568
  };
569
+ roleApi: {
570
+ type: PropType<SystemRoleApi>;
571
+ required: true;
572
+ };
477
573
  defaultActiveKey: {
478
574
  type: PropType<SystemAdminMenuKey>;
479
575
  default: SystemAdminMenuKey;
@@ -500,6 +596,10 @@ declare const SystemAdmin: vue.DefineComponent<vue.ExtractPropTypes<{
500
596
  type: PropType<AuthorizationResourceApi>;
501
597
  required: true;
502
598
  };
599
+ roleApi: {
600
+ type: PropType<SystemRoleApi>;
601
+ required: true;
602
+ };
503
603
  defaultActiveKey: {
504
604
  type: PropType<SystemAdminMenuKey>;
505
605
  default: SystemAdminMenuKey;
@@ -551,4 +651,4 @@ declare const snowyflake: ConfigurableSnowflake;
551
651
  declare function getAppClientId(): string;
552
652
  declare function getDeviceWorkerId(): string;
553
653
 
554
- export { type ApiResourceType, type AuthorizationResource, type AuthorizationResourceApi, type AuthorizationResourceFormValues, type AuthorizationResourceListResult, Can, type CheckOptions, type CreateAuthorizationResourceBody, type CreateDefaultResourceRequestOptions, type CreateMenuResourceBody, type FetchAuthorizationResourcesParams, type FetchMenuResourcesParams, type HttpMethod, type ListPaginationParams, type ListPaginationResult, MENU_LEAF_NO, MENU_LEAF_YES, MENU_LIST_TYPE_PARAM, MENU_TYPE_BUTTON, MENU_TYPE_LABEL, MENU_TYPE_MENU, MENU_TYPE_OPTIONS, MENU_TYPE_PAGE, MENU_VISIBILITY_OPTIONS, type MatchMode, MenuManager, type MenuResource, type MenuResourceApi, type MenuResourceFormValues, type MenuResourceListResult, type MenuResourceType, PERMISSION_STORE_KEY, type PageDirection, type PermissionChecker, type PermissionCode, type PermissionDirectiveValue, type PermissionListener, type PermissionPluginOptions, type PermissionState, PermissionStore, type PermissionStoreAPI, RESOURCE_PRIVATE_OPTIONS, RESOURCE_STATUS_DISABLED, RESOURCE_STATUS_ENABLED, RESOURCE_STATUS_OPTIONS, RESOURCE_TYPE_API, ROOT_MENU_DEPTH, ROOT_PARENT_ID, type ResourceHttpRequest, ResourceManager, type ResourceRequestOptions, type ResourceStatus, type ResourceType, type RoleCode, SYSTEM_ADMIN_DEFAULT_KEY, SYSTEM_ADMIN_MENU, SystemAdmin, type SystemAdminMenuGroup, type SystemAdminMenuKey, type SystemAdminSubMenu, type UpdateAuthorizationResourceBody, type UpdateMenuResourceBody, type UsePermissionResult, appendQueryParam, buildCreateBody, buildCreateMenuBody, buildUpdateBody, buildUpdateMenuBody, createAuthorizationResourceApi, createDefaultResourceRequest, createMenuResourceApi, createPermissionPlugin, createPermissionStore, createVPermission, extractPagination, extractRecords, getAppClientId, getDeviceWorkerId, isMenuLeaf, mapAuthorizationResource, mapMenuResource, resolveMenuDepth, snowyflake, useHasPermission, useHasRole, usePermission };
654
+ export { type ApiResourceType, type AuthorizationResource, type AuthorizationResourceApi, type AuthorizationResourceFormValues, type AuthorizationResourceListResult, Can, type CheckOptions, type CreateAuthorizationResourceBody, type CreateDefaultResourceRequestOptions, type CreateMenuResourceBody, type CreateSystemRoleBody, type FetchAuthorizationResourcesParams, type FetchMenuResourcesParams, type FetchSystemRolesParams, type HttpMethod, type ListPaginationParams, type ListPaginationResult, MENU_LEAF_NO, MENU_LEAF_YES, MENU_LIST_TYPE_PARAM, MENU_TYPE_BUTTON, MENU_TYPE_LABEL, MENU_TYPE_MENU, MENU_TYPE_OPTIONS, MENU_TYPE_PAGE, MENU_VISIBILITY_OPTIONS, type MatchMode, MenuManager, type MenuResource, type MenuResourceApi, type MenuResourceFormValues, type MenuResourceListResult, type MenuResourceType, PERMISSION_STORE_KEY, type PageDirection, type PermissionChecker, type PermissionCode, type PermissionDirectiveValue, type PermissionListener, type PermissionPluginOptions, type PermissionState, PermissionStore, type PermissionStoreAPI, RESOURCE_PRIVATE_OPTIONS, RESOURCE_STATUS_DISABLED, RESOURCE_STATUS_ENABLED, RESOURCE_STATUS_OPTIONS, RESOURCE_TYPE_API, ROOT_MENU_DEPTH, ROOT_PARENT_ID, type ResourceHttpRequest, ResourceManager, type ResourceRequestOptions, type ResourceStatus, type ResourceType, type RoleCode, RoleManager, type RolePermissionTreeNode, type RolePermissionsResult, SYSTEM_ADMIN_DEFAULT_KEY, SYSTEM_ADMIN_MENU, type SaveRolePermissionsBody, SystemAdmin, type SystemAdminMenuGroup, type SystemAdminMenuKey, type SystemAdminSubMenu, type SystemRole, type SystemRoleApi, type SystemRoleFormValues, type SystemRoleListResult, type UpdateAuthorizationResourceBody, type UpdateMenuResourceBody, type UpdateSystemRoleBody, type UsePermissionResult, appendQueryParam, buildCreateBody, buildCreateMenuBody, buildCreateRoleBody, buildSavePermissionsBody, buildUpdateBody, buildUpdateMenuBody, buildUpdateRoleBody, collectTreeResourceIds, createAuthorizationResourceApi, createDefaultResourceRequest, createMenuResourceApi, createPermissionPlugin, createPermissionStore, createSystemRoleApi, createVPermission, extractPagination, extractRecords, getAppClientId, getDeviceWorkerId, isMenuLeaf, mapAuthorizationResource, mapMenuResource, mapPermissionTreeNode, mapRolePermissions, mapSystemRole, resolveMenuDepth, snowyflake, useHasPermission, useHasRole, usePermission };