@pubinfo/module-rbac 2.0.0-beta.3
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.
- package/package.json +53 -0
- package/src/api/modules/assist/gonggaofuwu.ts +109 -0
- package/src/api/modules/assist/index.ts +5 -0
- package/src/api/modules/assist/qunzujiekou.ts +95 -0
- package/src/api/modules/assist/quyujiekou.ts +97 -0
- package/src/api/modules/assist/typings.d.ts +364 -0
- package/src/api/modules/configData/heibaimingdanfuwu.ts +95 -0
- package/src/api/modules/configData/index.ts +5 -0
- package/src/api/modules/configData/typings.d.ts +347 -0
- package/src/api/modules/configData/xitongpeizhifuwu.ts +322 -0
- package/src/api/modules/configData/zidianfuwu.ts +151 -0
- package/src/api/modules/log/caozuorizhifuwu.ts +37 -0
- package/src/api/modules/log/denglurizhifuwu.ts +37 -0
- package/src/api/modules/log/index.ts +4 -0
- package/src/api/modules/log/typings.d.ts +179 -0
- package/src/api/modules/rbac/gangweijiekou.ts +93 -0
- package/src/api/modules/rbac/index.ts +13 -0
- package/src/api/modules/rbac/jiaosejiekou.ts +124 -0
- package/src/api/modules/rbac/pubJiaosezukongzhiqi.ts +113 -0
- package/src/api/modules/rbac/shujuquanxianzhubiaokongzhiqi.ts +186 -0
- package/src/api/modules/rbac/typings.d.ts +2001 -0
- package/src/api/modules/rbac/yonghujiekou.ts +225 -0
- package/src/api/modules/rbac/yonghushoucangbiaojiekou.ts +93 -0
- package/src/api/modules/rbac/yonghuzuijinchangyongbiaojiekou.ts +72 -0
- package/src/api/modules/rbac/ziyuanjiekou.ts +223 -0
- package/src/api/modules/rbac/zuhuguanlijiekou.ts +91 -0
- package/src/api/modules/rbac/zuzhijiaosebiaokongzhiqi.ts +76 -0
- package/src/api/modules/rbac/zuzhijiekou.ts +171 -0
- package/src/api/request.ts +3 -0
- package/src/assets/icons/403.svg +1 -0
- package/src/assets/icons/403_dark.svg +1 -0
- package/src/assets/icons/404.svg +1 -0
- package/src/assets/icons/404_dark.svg +1 -0
- package/src/assets/icons/add-child.svg +1 -0
- package/src/assets/icons/authority.svg +1 -0
- package/src/assets/icons/authorize.svg +1 -0
- package/src/assets/icons/blacklist-disable.svg +1 -0
- package/src/assets/icons/blacklist-enable.svg +1 -0
- package/src/assets/icons/browser-360.svg +1 -0
- package/src/assets/icons/browser-chrome.svg +1 -0
- package/src/assets/icons/browser-edge.svg +1 -0
- package/src/assets/icons/browser-ie.svg +1 -0
- package/src/assets/icons/browser-other.svg +1 -0
- package/src/assets/icons/browser-qq.svg +1 -0
- package/src/assets/icons/browser-safari.svg +1 -0
- package/src/assets/icons/browser-uc.svg +1 -0
- package/src/assets/icons/change-org.svg +1 -0
- package/src/assets/icons/edit.svg +1 -0
- package/src/assets/icons/empty-data.svg +1 -0
- package/src/assets/icons/favorites.svg +1 -0
- package/src/assets/icons/icard.svg +1 -0
- package/src/assets/icons/icon_animation.svg +1 -0
- package/src/assets/icons/icon_breadcrumb.svg +1 -0
- package/src/assets/icons/icon_copyright.svg +1 -0
- package/src/assets/icons/icon_jt.svg +1 -0
- package/src/assets/icons/icon_layout.svg +1 -0
- package/src/assets/icons/icon_mainpage.svg +1 -0
- package/src/assets/icons/icon_menu.svg +1 -0
- package/src/assets/icons/icon_page_size.svg +1 -0
- package/src/assets/icons/icon_position_type.svg +1 -0
- package/src/assets/icons/icon_safe_manage.svg +1 -0
- package/src/assets/icons/icon_screen_scale.svg +6 -0
- package/src/assets/icons/icon_system_manage.svg +1 -0
- package/src/assets/icons/icon_tabbar.svg +1 -0
- package/src/assets/icons/icon_toolbar.svg +1 -0
- package/src/assets/icons/icon_topbar.svg +1 -0
- package/src/assets/icons/icon_watermark.svg +1 -0
- package/src/assets/icons/image-load-fail.svg +1 -0
- package/src/assets/icons/log-center.svg +1 -0
- package/src/assets/icons/logo-sig.svg +1 -0
- package/src/assets/icons/logo.svg +1 -0
- package/src/assets/icons/mima.svg +1 -0
- package/src/assets/icons/not-data.svg +1 -0
- package/src/assets/icons/org-main.svg +1 -0
- package/src/assets/icons/org-unmain.svg +1 -0
- package/src/assets/icons/process-management.svg +1 -0
- package/src/assets/icons/project-management.svg +1 -0
- package/src/assets/icons/rbac.svg +1 -0
- package/src/assets/icons/remove.svg +1 -0
- package/src/assets/icons/resource-app.svg +1 -0
- package/src/assets/icons/resource-btn.svg +1 -0
- package/src/assets/icons/resource-index.svg +1 -0
- package/src/assets/icons/resource-menu.svg +1 -0
- package/src/assets/icons/resource-nonmenu.svg +1 -0
- package/src/assets/icons/setting-manage.svg +1 -0
- package/src/assets/icons/test.svg +1 -0
- package/src/assets/icons/theme-check-mark.svg +1 -0
- package/src/assets/icons/theme-title.svg +1 -0
- package/src/assets/icons/toolbar-collapse.svg +1 -0
- package/src/assets/icons/tree_icon.svg +1 -0
- package/src/assets/icons/tree_icon_checked.svg +1 -0
- package/src/assets/icons/view.svg +1 -0
- package/src/assets/icons/workbench.svg +1 -0
- package/src/assets/icons/zddata.svg +1 -0
- package/src/assets/icons/zy_checked.svg +1 -0
- package/src/assets/icons/zy_default.svg +1 -0
- package/src/assets/images/layout/item1.webp +0 -0
- package/src/assets/images/layout/item1_dark.webp +0 -0
- package/src/assets/images/layout/item2.webp +0 -0
- package/src/assets/images/layout/item2_dark.webp +0 -0
- package/src/assets/images/layout/item3.webp +0 -0
- package/src/assets/images/layout/item3_dark.webp +0 -0
- package/src/assets/images/layout/item4.webp +0 -0
- package/src/assets/images/layout/item4_dark.webp +0 -0
- package/src/assets/images/layout/item5.webp +0 -0
- package/src/assets/images/layout/item5_dark.webp +0 -0
- package/src/assets/images/page-width/anto_min_w_dark.webp +0 -0
- package/src/assets/images/page-width/auto.webp +0 -0
- package/src/assets/images/page-width/auto_dark.webp +0 -0
- package/src/assets/images/page-width/auto_min_w.webp +0 -0
- package/src/assets/images/page-width/auto_min_w_dark.webp +0 -0
- package/src/assets/images/page-width/icon_auto.webp +0 -0
- package/src/assets/images/page-width/icon_auto_dark.webp +0 -0
- package/src/assets/images/page-width/icon_auto_min_w.webp +0 -0
- package/src/assets/images/page-width/icon_auto_min_w_dark.webp +0 -0
- package/src/assets/images/page-width/icon_middle.webp +0 -0
- package/src/assets/images/page-width/icon_middle_dark.webp +0 -0
- package/src/assets/images/page-width/icon_middle_max_w.webp +0 -0
- package/src/assets/images/page-width/icon_middle_max_w_dark.webp +0 -0
- package/src/assets/images/page-width/middle.webp +0 -0
- package/src/assets/images/page-width/middle_dark.webp +0 -0
- package/src/assets/images/page-width/middle_max_w.webp +0 -0
- package/src/assets/images/page-width/middle_max_w_dark.webp +0 -0
- package/src/assets/lottie/breadcrumb/dark/enable.json +1 -0
- package/src/assets/lottie/breadcrumb/dark/enableMainMenu.json +1 -0
- package/src/assets/lottie/breadcrumb/dark/style.json +1 -0
- package/src/assets/lottie/breadcrumb/light/enable.json +1 -0
- package/src/assets/lottie/breadcrumb/light/enableMainMenu.json +1 -0
- package/src/assets/lottie/breadcrumb/light/style.json +1 -0
- package/src/assets/lottie/layout/data-test.json +1 -0
- package/src/assets/lottie/layout/data.json +1 -0
- package/src/assets/lottie/menu/dark/enableHotkeys.json +1 -0
- package/src/assets/lottie/menu/dark/enableSubMenuCollapseButton.json +1 -0
- package/src/assets/lottie/menu/dark/isRounded.json +1 -0
- package/src/assets/lottie/menu/dark/menuActiveStyle.json +1 -0
- package/src/assets/lottie/menu/dark/subMenuCollapse.json +1 -0
- package/src/assets/lottie/menu/dark/subMenuUniqueOpened.json +1 -0
- package/src/assets/lottie/menu/light/enableHotkeys.json +1 -0
- package/src/assets/lottie/menu/light/enableSubMenuCollapseButton.json +1 -0
- package/src/assets/lottie/menu/light/isRounded.json +1 -0
- package/src/assets/lottie/menu/light/menuActiveStyle.json +1 -0
- package/src/assets/lottie/menu/light/subMenuCollapse.json +1 -0
- package/src/assets/lottie/menu/light/subMenuUniqueOpened.json +1 -0
- package/src/assets/lottie/other/dark/enableCopyright.json +1 -0
- package/src/assets/lottie/other/dark/enableHotkeys.json +1 -0
- package/src/assets/lottie/other/dark/switchTabbarAndToolbar.json +1 -0
- package/src/assets/lottie/other/light/enableCopyright.json +1 -0
- package/src/assets/lottie/other/light/enableHotkeys.json +1 -0
- package/src/assets/lottie/other/light/switchTabbarAndToolbar.json +1 -0
- package/src/assets/lottie/page_animation/dark/fadeinout.json +1 -0
- package/src/assets/lottie/page_animation/dark/fadeinout_old.json +1 -0
- package/src/assets/lottie/page_animation/dark/tobottom.json +1 -0
- package/src/assets/lottie/page_animation/dark/tobottom_old.json +1 -0
- package/src/assets/lottie/page_animation/dark/toleft.json +1 -0
- package/src/assets/lottie/page_animation/dark/toleft_old.json +1 -0
- package/src/assets/lottie/page_animation/dark/toright.json +1 -0
- package/src/assets/lottie/page_animation/dark/toright_old.json +1 -0
- package/src/assets/lottie/page_animation/dark/totop.json +1 -0
- package/src/assets/lottie/page_animation/dark/totop_old.json +1 -0
- package/src/assets/lottie/page_animation/light/fadeinout.json +1 -0
- package/src/assets/lottie/page_animation/light/tobottom.json +1 -0
- package/src/assets/lottie/page_animation/light/toleft.json +1 -0
- package/src/assets/lottie/page_animation/light/toright.json +1 -0
- package/src/assets/lottie/page_animation/light/totop.json +1 -0
- package/src/assets/lottie/tabbar/dark/enable.json +1 -0
- package/src/assets/lottie/tabbar/dark/enableHotkeys.json +1 -0
- package/src/assets/lottie/tabbar/dark/enableIcon.json +1 -0
- package/src/assets/lottie/tabbar/dark/enableMemory.json +1 -0
- package/src/assets/lottie/tabbar/dark/style.json +1 -0
- package/src/assets/lottie/tabbar/light/enable.json +1 -0
- package/src/assets/lottie/tabbar/light/enableHotkeys.json +1 -0
- package/src/assets/lottie/tabbar/light/enableIcon.json +1 -0
- package/src/assets/lottie/tabbar/light/enableMemory.json +1 -0
- package/src/assets/lottie/tabbar/light/style.json +1 -0
- package/src/assets/lottie/toolbar/dark/enableColorScheme.json +1 -0
- package/src/assets/lottie/toolbar/dark/enableFullscreen.json +1 -0
- package/src/assets/lottie/toolbar/dark/enableI18n.json +1 -0
- package/src/assets/lottie/toolbar/dark/enableNotification.json +1 -0
- package/src/assets/lottie/toolbar/dark/enablePageReload.json +1 -0
- package/src/assets/lottie/toolbar/dark/enableUserPreferences.json +1 -0
- package/src/assets/lottie/toolbar/dark/navSearchEnable.json +1 -0
- package/src/assets/lottie/toolbar/dark/navSearchEnableHotkeys.json +1 -0
- package/src/assets/lottie/toolbar/light/enableColorScheme.json +1 -0
- package/src/assets/lottie/toolbar/light/enableFullscreen.json +1 -0
- package/src/assets/lottie/toolbar/light/enableI18n.json +1 -0
- package/src/assets/lottie/toolbar/light/enableNotification.json +1 -0
- package/src/assets/lottie/toolbar/light/enablePageReload.json +1 -0
- package/src/assets/lottie/toolbar/light/enableUserPreferences.json +1 -0
- package/src/assets/lottie/toolbar/light/navSearchEnable.json +1 -0
- package/src/assets/lottie/toolbar/light/navSearchEnableHotkeys.json +1 -0
- package/src/assets/lottie/watermark/dark/enableWatermark.json +1 -0
- package/src/assets/lottie/watermark/light/enableWatermark.json +1 -0
- package/src/assets/styles/vxe-table.css +13 -0
- package/src/components/GroupSelector/index.vue +311 -0
- package/src/components/OrgTree/index.vue +91 -0
- package/src/components/OrgUserSelector/OrgSelector.vue +135 -0
- package/src/components/OrgUserSelector/UserSelector.vue +164 -0
- package/src/components/OrgUserSelector/index.ts +47 -0
- package/src/components/OrgUserSelector/provider.ts +373 -0
- package/src/components/ResourceSelector/enum.ts +5 -0
- package/src/components/ResourceSelector/hooks/useAppAndResource.ts +96 -0
- package/src/components/ResourceSelector/index.vue +432 -0
- package/src/composables/useLottie.ts +65 -0
- package/src/index.ts +31 -0
- package/src/interface.ts +54 -0
- package/src/routes/index.ts +156 -0
- package/src/routes/modules/authority.manage.menu.ts +105 -0
- package/src/routes/modules/log.manage.menu.ts +45 -0
- package/src/routes/modules/safe.manage.menu.ts +71 -0
- package/src/routes/modules/stylesetting.manage.menu.ts +130 -0
- package/src/routes/modules/system.manage.menu.ts +92 -0
- package/src/stores/index.ts +1 -0
- package/src/views/blackWhiteList/components/drawerBlackWhiteList.vue +132 -0
- package/src/views/blackWhiteList/enum.ts +7 -0
- package/src/views/blackWhiteList/index.vue +309 -0
- package/src/views/blackWhiteList/types.ts +4 -0
- package/src/views/breadcrumb_setting/animationData.ts +15 -0
- package/src/views/breadcrumb_setting/index.vue +147 -0
- package/src/views/components/HCheckList.vue +47 -0
- package/src/views/components/animation_item.vue +37 -0
- package/src/views/components/setItem.vue +126 -0
- package/src/views/data-permission/components/createAndEditDataPermission.vue +354 -0
- package/src/views/data-permission/enum.ts +59 -0
- package/src/views/data-permission/index.vue +190 -0
- package/src/views/dictionary/components/drawerDictionary.vue +108 -0
- package/src/views/dictionary/components/drawerDictionaryItem.vue +115 -0
- package/src/views/dictionary/enum.ts +8 -0
- package/src/views/dictionary/index.vue +194 -0
- package/src/views/dictionary/itemlist.vue +164 -0
- package/src/views/group/components/drawerGroup.vue +177 -0
- package/src/views/group/enum.ts +25 -0
- package/src/views/group/index.vue +207 -0
- package/src/views/layout_setting/index.vue +306 -0
- package/src/views/log_center/components/browserType.vue +35 -0
- package/src/views/log_center/components/loginHistoryDetail.vue +71 -0
- package/src/views/log_center/components/operateHistoryDetail.vue +80 -0
- package/src/views/log_center/login_history.vue +239 -0
- package/src/views/log_center/operate_history.vue +233 -0
- package/src/views/menu_setting/animationData.ts +27 -0
- package/src/views/menu_setting/index.vue +207 -0
- package/src/views/organization/components/drawerOrganization.vue +161 -0
- package/src/views/organization/components/drawerRole.vue +159 -0
- package/src/views/organization/components/roleSelect.vue +258 -0
- package/src/views/organization/enum.ts +26 -0
- package/src/views/organization/index.vue +516 -0
- package/src/views/other_setting/animationData.ts +15 -0
- package/src/views/other_setting/index.vue +250 -0
- package/src/views/other_setting/interface.ts +26 -0
- package/src/views/page_animation_setting/animationData.ts +23 -0
- package/src/views/page_animation_setting/index.vue +200 -0
- package/src/views/page_w_setting/index.vue +238 -0
- package/src/views/position/components/drawerPosition.vue +131 -0
- package/src/views/position/enum.ts +8 -0
- package/src/views/position/index.vue +167 -0
- package/src/views/region/components/drawerRegion.vue +143 -0
- package/src/views/region/enum.ts +24 -0
- package/src/views/region/index.vue +246 -0
- package/src/views/resource/components/ResourceEdit.vue +209 -0
- package/src/views/resource/components/RoleRelation.vue +100 -0
- package/src/views/resource/enum.ts +35 -0
- package/src/views/resource/index.vue +237 -0
- package/src/views/resource/interface.ts +6 -0
- package/src/views/role/components/ResourceRelation.vue +113 -0
- package/src/views/role/components/drawerRole.vue +191 -0
- package/src/views/role/enum.ts +26 -0
- package/src/views/role/index.vue +183 -0
- package/src/views/role/interface.ts +6 -0
- package/src/views/role_group/components/ResourceRelation.vue +91 -0
- package/src/views/role_group/components/drawerRole.vue +153 -0
- package/src/views/role_group/components/roleSelect.vue +224 -0
- package/src/views/role_group/enum.ts +22 -0
- package/src/views/role_group/index.vue +170 -0
- package/src/views/role_group/interface.ts +6 -0
- package/src/views/safe_setting/index.vue +237 -0
- package/src/views/tabbar_setting/animationData.ts +23 -0
- package/src/views/tabbar_setting/index.vue +186 -0
- package/src/views/tenant/components/TenantEdit.vue +226 -0
- package/src/views/tenant/index.vue +192 -0
- package/src/views/tenant/interface.ts +4 -0
- package/src/views/theme_setting/index.vue +465 -0
- package/src/views/toolbar_setting/animationData.ts +42 -0
- package/src/views/toolbar_setting/index.vue +189 -0
- package/src/views/user/components/OrgAndPosition.vue +156 -0
- package/src/views/user/components/UserAuthorization.vue +260 -0
- package/src/views/user/components/UserEdit.vue +267 -0
- package/src/views/user/components/roleSelect.vue +258 -0
- package/src/views/user/enum.ts +13 -0
- package/src/views/user/index.vue +266 -0
- package/src/views/user/interface.ts +43 -0
- package/src/views/watermark_setting/animationData.ts +7 -0
- package/src/views/watermark_setting/index.vue +236 -0
|
@@ -0,0 +1,170 @@
|
|
|
1
|
+
<script setup lang="tsx">
|
|
2
|
+
import type { ProColumns } from '@pubinfo/pro-components';
|
|
3
|
+
import { deleteRbacPubRoleGroupDelete, postRbacPubRoleGroupPageQuery } from '@/api/modules/rbac';
|
|
4
|
+
import { ProTable } from '@pubinfo/pro-components';
|
|
5
|
+
import { Badge, message, Modal } from 'ant-design-vue';
|
|
6
|
+
import DrawerRole from './components/drawerRole.vue';
|
|
7
|
+
import { ACTION } from './enum';
|
|
8
|
+
|
|
9
|
+
defineOptions({
|
|
10
|
+
name: 'Role',
|
|
11
|
+
});
|
|
12
|
+
|
|
13
|
+
const { auth } = useAuth();
|
|
14
|
+
const tableRef = ref();
|
|
15
|
+
const drawerRoleRef = ref();
|
|
16
|
+
|
|
17
|
+
function getRoleData() {
|
|
18
|
+
tableRef.value.reload();
|
|
19
|
+
}
|
|
20
|
+
|
|
21
|
+
async function request(params: any) {
|
|
22
|
+
const { current, pageSize, ...rest } = params;
|
|
23
|
+
const res = await postRbacPubRoleGroupPageQuery({
|
|
24
|
+
currentPage: current,
|
|
25
|
+
pageSize,
|
|
26
|
+
...rest,
|
|
27
|
+
});
|
|
28
|
+
return {
|
|
29
|
+
success: res.success,
|
|
30
|
+
data: res.data?.records ?? [],
|
|
31
|
+
total: res.data?.total ?? 0,
|
|
32
|
+
};
|
|
33
|
+
}
|
|
34
|
+
const columns: ProColumns<API.PubRole> = [
|
|
35
|
+
{
|
|
36
|
+
valueType: 'a-input',
|
|
37
|
+
bind: 'value',
|
|
38
|
+
minWidth: 200,
|
|
39
|
+
title: '角色组名称',
|
|
40
|
+
dataIndex: 'name',
|
|
41
|
+
ellipsis: true,
|
|
42
|
+
fieldProps: {
|
|
43
|
+
placeholder: '请输入角色组名称',
|
|
44
|
+
allowClear: true,
|
|
45
|
+
},
|
|
46
|
+
},
|
|
47
|
+
{
|
|
48
|
+
hideInSearch: true,
|
|
49
|
+
minWidth: 80,
|
|
50
|
+
title: '创建人',
|
|
51
|
+
dataIndex: 'createUserName',
|
|
52
|
+
},
|
|
53
|
+
{
|
|
54
|
+
hideInSearch: true,
|
|
55
|
+
minWidth: 100,
|
|
56
|
+
title: '创建部门',
|
|
57
|
+
dataIndex: 'createOrgName',
|
|
58
|
+
},
|
|
59
|
+
{
|
|
60
|
+
hideInSearch: true,
|
|
61
|
+
minWidth: 100,
|
|
62
|
+
title: '创建时间',
|
|
63
|
+
dataIndex: 'createTime',
|
|
64
|
+
},
|
|
65
|
+
{
|
|
66
|
+
hideInSearch: true,
|
|
67
|
+
minWidth: 100,
|
|
68
|
+
title: '修改时间',
|
|
69
|
+
dataIndex: 'updateTime',
|
|
70
|
+
},
|
|
71
|
+
{
|
|
72
|
+
valueType: 'a-select',
|
|
73
|
+
minWidth: 80,
|
|
74
|
+
title: '角色组状态',
|
|
75
|
+
dataIndex: 'enable',
|
|
76
|
+
customRender: ({ text }: { text: boolean }) => {
|
|
77
|
+
return (
|
|
78
|
+
text
|
|
79
|
+
? <Badge status="success" text="正常" />
|
|
80
|
+
: <Badge status="error" text="关闭" />
|
|
81
|
+
);
|
|
82
|
+
},
|
|
83
|
+
fieldProps: {
|
|
84
|
+
placeholder: '请选择是否启用',
|
|
85
|
+
allowClear: true,
|
|
86
|
+
options: [
|
|
87
|
+
{ value: 1, label: '正常' },
|
|
88
|
+
{ value: 0, label: '关闭' },
|
|
89
|
+
],
|
|
90
|
+
},
|
|
91
|
+
},
|
|
92
|
+
{
|
|
93
|
+
hideInSearch: true,
|
|
94
|
+
width: 140,
|
|
95
|
+
title: '操作',
|
|
96
|
+
dataIndex: 'action',
|
|
97
|
+
fixed: 'right',
|
|
98
|
+
hideInTable() {
|
|
99
|
+
return !auth([
|
|
100
|
+
'role_group_edit',
|
|
101
|
+
'role_group_remove',
|
|
102
|
+
]);
|
|
103
|
+
},
|
|
104
|
+
},
|
|
105
|
+
];
|
|
106
|
+
function onAction(key: string, record?: API.PubRole): void {
|
|
107
|
+
switch (key) {
|
|
108
|
+
case ACTION.EDIT:
|
|
109
|
+
drawerRoleRef.value.open(key, record);
|
|
110
|
+
break;
|
|
111
|
+
case ACTION.ADD:
|
|
112
|
+
drawerRoleRef.value.open(key);
|
|
113
|
+
break;
|
|
114
|
+
case ACTION.REMOVE:
|
|
115
|
+
Modal.confirm({
|
|
116
|
+
title: '删除',
|
|
117
|
+
content: '确定要删除该角色组吗?',
|
|
118
|
+
onOk() {
|
|
119
|
+
deleteRbacPubRoleGroupDelete({ id: record?.id as string }).then((res) => {
|
|
120
|
+
if (res.success) {
|
|
121
|
+
message.success('删除成功');
|
|
122
|
+
getRoleData();
|
|
123
|
+
}
|
|
124
|
+
});
|
|
125
|
+
},
|
|
126
|
+
});
|
|
127
|
+
break;
|
|
128
|
+
}
|
|
129
|
+
}
|
|
130
|
+
</script>
|
|
131
|
+
|
|
132
|
+
<template>
|
|
133
|
+
<div
|
|
134
|
+
py-10px
|
|
135
|
+
px-10px
|
|
136
|
+
w-full
|
|
137
|
+
h-full
|
|
138
|
+
>
|
|
139
|
+
<ProTable
|
|
140
|
+
ref="tableRef"
|
|
141
|
+
row-key="id"
|
|
142
|
+
:request="request"
|
|
143
|
+
:columns="columns"
|
|
144
|
+
auto-height
|
|
145
|
+
:scroll="{ x: 1100 }"
|
|
146
|
+
>
|
|
147
|
+
<template #toolbar>
|
|
148
|
+
<a-button v-auth="'role_group_add'" type="primary" @click="onAction(ACTION.ADD)">
|
|
149
|
+
<PlusCircleOutlined />
|
|
150
|
+
{{ ACTION.ADD }}
|
|
151
|
+
</a-button>
|
|
152
|
+
</template>
|
|
153
|
+
<template #bodyCell="{ column, record }">
|
|
154
|
+
<template v-if="column.dataIndex === 'action'">
|
|
155
|
+
<a-space>
|
|
156
|
+
<a v-auth="'role_edit'" class="flex items-center" @click="onAction(ACTION.EDIT, record)">
|
|
157
|
+
<PubinfoIcon name="edit" class="text-base" />
|
|
158
|
+
<span class="ml-4px">{{ ACTION.EDIT }}</span>
|
|
159
|
+
</a>
|
|
160
|
+
<span v-auth="'role_remove'" class="flex items-center text-red-500 hover:cursor-pointer hover:opacity-80" @click="onAction(ACTION.REMOVE, record)">
|
|
161
|
+
<PubinfoIcon name="remove" class="text-base" />
|
|
162
|
+
<span class="ml-4px">{{ ACTION.REMOVE }}</span>
|
|
163
|
+
</span>
|
|
164
|
+
</a-space>
|
|
165
|
+
</template>
|
|
166
|
+
</template>
|
|
167
|
+
</ProTable>
|
|
168
|
+
<DrawerRole ref="drawerRoleRef" @submit="getRoleData()" />
|
|
169
|
+
</div>
|
|
170
|
+
</template>
|
|
@@ -0,0 +1,237 @@
|
|
|
1
|
+
<script setup lang="ts">
|
|
2
|
+
import type { Rule } from 'ant-design-vue/es/form';
|
|
3
|
+
import type { UnwrapRef } from 'vue';
|
|
4
|
+
import { getSysconfigGetSysSecurityConfig, postSysconfigEditSysSecurityConfig } from '@/api/modules/configData';
|
|
5
|
+
import { useToggle } from '@vueuse/core';
|
|
6
|
+
import { message } from 'ant-design-vue';
|
|
7
|
+
import { PassStrengthValidator } from 'pubinfo';
|
|
8
|
+
import { reactive, ref } from 'vue';
|
|
9
|
+
|
|
10
|
+
interface FormState {
|
|
11
|
+
blackWhiteListMode: string
|
|
12
|
+
// 是否开启密码错误后锁定账号: true开 false关
|
|
13
|
+
// 选择开的时候出现allowFailCount 和 lockMinutes 2个选项
|
|
14
|
+
lockEnable: boolean
|
|
15
|
+
allowFailCounts: number
|
|
16
|
+
lockMinutes: number
|
|
17
|
+
defaultPassword: string
|
|
18
|
+
expireDays: number
|
|
19
|
+
// 是否开启强制修改初始化密码: true开 false关
|
|
20
|
+
forceChangeInitPwd: boolean
|
|
21
|
+
}
|
|
22
|
+
|
|
23
|
+
const rules: Record<string, Rule[]> = {
|
|
24
|
+
blackWhiteListMode: [
|
|
25
|
+
{ required: true, message: '请选择黑白名单模式', trigger: 'change' },
|
|
26
|
+
],
|
|
27
|
+
lockEnable: [
|
|
28
|
+
{ required: true, message: '请选择密码错误后是否锁定账号', trigger: 'change' },
|
|
29
|
+
],
|
|
30
|
+
lockMinutes: [{ required: true, validator: validateLockMinutes, trigger: 'change' }],
|
|
31
|
+
allowFailCounts: [{ required: true, validator: validateAllowFailCount, trigger: 'change' }],
|
|
32
|
+
defaultPassword: [{ required: true, validator: validatePassword, trigger: 'change' }],
|
|
33
|
+
expireDays: [{ required: true, validator: validateExpireDays, trigger: 'change' }],
|
|
34
|
+
forceChangeInitPwd: [
|
|
35
|
+
{ required: true, message: '请选择是否开启强制修改初始化密码', trigger: 'change' },
|
|
36
|
+
],
|
|
37
|
+
};
|
|
38
|
+
|
|
39
|
+
const formRef = ref();
|
|
40
|
+
const labelCol = { style: { width: '240px' } };
|
|
41
|
+
const wrapperCol = { span: 9 };
|
|
42
|
+
const modeOptions = [
|
|
43
|
+
{
|
|
44
|
+
label: '无模式',
|
|
45
|
+
value: '0',
|
|
46
|
+
},
|
|
47
|
+
{
|
|
48
|
+
label: '黑名单模式',
|
|
49
|
+
value: '1',
|
|
50
|
+
},
|
|
51
|
+
{
|
|
52
|
+
label: '白名单模式',
|
|
53
|
+
value: '2',
|
|
54
|
+
},
|
|
55
|
+
];
|
|
56
|
+
|
|
57
|
+
const formState: UnwrapRef<FormState> = reactive({
|
|
58
|
+
// 黑白名单模式:'0'.无模式, '1':黑名单模式, '2':白名单模式
|
|
59
|
+
blackWhiteListMode: '0',
|
|
60
|
+
// 密码错误后是否锁定账号, true开 false关
|
|
61
|
+
lockEnable: true,
|
|
62
|
+
// 允许密码连续错误的次数
|
|
63
|
+
allowFailCounts: 5,
|
|
64
|
+
// 锁定多少分钟
|
|
65
|
+
lockMinutes: 10,
|
|
66
|
+
// 默认密码
|
|
67
|
+
defaultPassword: '',
|
|
68
|
+
// 密码过期天数
|
|
69
|
+
expireDays: 30,
|
|
70
|
+
// 是否强制初始化密码,即登录后必须修改默认密码. 1开 0关,
|
|
71
|
+
forceChangeInitPwd: true,
|
|
72
|
+
});
|
|
73
|
+
|
|
74
|
+
const isDefaultPasswordValid = ref(false);
|
|
75
|
+
|
|
76
|
+
onMounted(getSystemSafeConfig);
|
|
77
|
+
|
|
78
|
+
async function validateLockMinutes(_rule: Rule, value: string) {
|
|
79
|
+
if (formState.lockEnable && !value) {
|
|
80
|
+
return Promise.reject(new Error('请输入锁定分钟数'));
|
|
81
|
+
}
|
|
82
|
+
if (Number.isNaN(+value) || +value < 1 || +value > 360) {
|
|
83
|
+
return Promise.reject(new Error('锁定分钟数应为[1~360]之间的正整数'));
|
|
84
|
+
}
|
|
85
|
+
return Promise.resolve();
|
|
86
|
+
};
|
|
87
|
+
|
|
88
|
+
async function validateAllowFailCount(_rule: Rule, value: string) {
|
|
89
|
+
if (formState.lockEnable && !value) {
|
|
90
|
+
return Promise.reject(new Error('请输入允许密码连续错误次数'));
|
|
91
|
+
}
|
|
92
|
+
if (Number.isNaN(+value) || +value < 1 || +value > 20) {
|
|
93
|
+
return Promise.reject(new Error('允许密码连续错误次数应为[1~20]之间的正整数'));
|
|
94
|
+
}
|
|
95
|
+
return Promise.resolve();
|
|
96
|
+
};
|
|
97
|
+
|
|
98
|
+
async function validateExpireDays(_rule: Rule, value: string) {
|
|
99
|
+
if (formState.lockEnable && !value) {
|
|
100
|
+
return Promise.reject(new Error('请输入密码过期天数'));
|
|
101
|
+
}
|
|
102
|
+
if (Number.isNaN(+value) || +value < 30 || +value > 360) {
|
|
103
|
+
return Promise.reject(new Error('密码过期天数应为[30~360]之间的正整数'));
|
|
104
|
+
}
|
|
105
|
+
return Promise.resolve();
|
|
106
|
+
};
|
|
107
|
+
|
|
108
|
+
async function validatePassword(_rule: Rule, value: string) {
|
|
109
|
+
if (!value) {
|
|
110
|
+
return Promise.reject(new Error('请输入默认密码'));
|
|
111
|
+
}
|
|
112
|
+
if (!isDefaultPasswordValid.value) {
|
|
113
|
+
return Promise.reject(new Error('密码规则校验不通过'));
|
|
114
|
+
}
|
|
115
|
+
return Promise.resolve();
|
|
116
|
+
};
|
|
117
|
+
|
|
118
|
+
function getSystemSafeConfig() {
|
|
119
|
+
getSysconfigGetSysSecurityConfig().then((res) => {
|
|
120
|
+
if (res && res.data && res.data.content && res.success) {
|
|
121
|
+
Object.assign(formState, JSON.parse(res.data.content));
|
|
122
|
+
}
|
|
123
|
+
});
|
|
124
|
+
}
|
|
125
|
+
|
|
126
|
+
const [loading, setLoading] = useToggle(false);
|
|
127
|
+
async function onSubmit() {
|
|
128
|
+
if (loading.value) {
|
|
129
|
+
return;
|
|
130
|
+
}
|
|
131
|
+
setLoading(true);
|
|
132
|
+
try {
|
|
133
|
+
await formRef.value?.validate();
|
|
134
|
+
const {
|
|
135
|
+
blackWhiteListMode,
|
|
136
|
+
lockEnable,
|
|
137
|
+
allowFailCounts,
|
|
138
|
+
lockMinutes,
|
|
139
|
+
defaultPassword,
|
|
140
|
+
expireDays,
|
|
141
|
+
forceChangeInitPwd,
|
|
142
|
+
} = formState;
|
|
143
|
+
|
|
144
|
+
const params = {
|
|
145
|
+
blackWhiteListMode,
|
|
146
|
+
lockEnable,
|
|
147
|
+
defaultPassword,
|
|
148
|
+
expireDays,
|
|
149
|
+
forceChangeInitPwd,
|
|
150
|
+
};
|
|
151
|
+
|
|
152
|
+
if (lockEnable) {
|
|
153
|
+
Object.assign(params, {
|
|
154
|
+
allowFailCounts,
|
|
155
|
+
lockMinutes,
|
|
156
|
+
});
|
|
157
|
+
}
|
|
158
|
+
|
|
159
|
+
await postSysconfigEditSysSecurityConfig({ content: JSON.stringify(params) });
|
|
160
|
+
setLoading(false);
|
|
161
|
+
message.success('配置更改成功');
|
|
162
|
+
}
|
|
163
|
+
catch (error) {
|
|
164
|
+
setLoading(false);
|
|
165
|
+
}
|
|
166
|
+
}
|
|
167
|
+
</script>
|
|
168
|
+
|
|
169
|
+
<template>
|
|
170
|
+
<div
|
|
171
|
+
w-full
|
|
172
|
+
h-full
|
|
173
|
+
pt-10px
|
|
174
|
+
px-10px
|
|
175
|
+
overflow-auto
|
|
176
|
+
>
|
|
177
|
+
<div h-full min-w-1130px>
|
|
178
|
+
<div
|
|
179
|
+
class="pt-20px flex flex-col box-border bg-white dark:bg-[#141414] text-[#4e5969] dark:text-[#C9CDD4]"
|
|
180
|
+
>
|
|
181
|
+
<a-form
|
|
182
|
+
ref="formRef"
|
|
183
|
+
:model="formState"
|
|
184
|
+
:rules="rules"
|
|
185
|
+
:label-col="labelCol"
|
|
186
|
+
:wrapper-col="wrapperCol"
|
|
187
|
+
class="safe-rule-form"
|
|
188
|
+
>
|
|
189
|
+
<a-form-item label="黑白名单模式" name="blackWhiteListMode">
|
|
190
|
+
<a-select v-model:value="formState.blackWhiteListMode" placeholder="请选择" :options="modeOptions" />
|
|
191
|
+
</a-form-item>
|
|
192
|
+
<a-form-item label="是否开启密码错误后锁定账号" name="lockEnable">
|
|
193
|
+
<a-switch v-model:checked="formState.lockEnable" />
|
|
194
|
+
</a-form-item>
|
|
195
|
+
<!-- 应该用formState.lockEnable 但会导致formRef.value.validate不存在 -->
|
|
196
|
+
<template v-if="formState.lockEnable">
|
|
197
|
+
<!-- v-if="formState.lockEnable" key="allowFailCounts" 或 v-show -->
|
|
198
|
+
<a-form-item label="允许密码连续错误次数" name="allowFailCounts">
|
|
199
|
+
<a-input v-model:value="formState.allowFailCounts" mr-12px />次
|
|
200
|
+
</a-form-item>
|
|
201
|
+
<!-- v-if="formState.lockEnable" key="lockMinutes" 或 v-show -->
|
|
202
|
+
<a-form-item label="锁定多少分钟" name="lockMinutes">
|
|
203
|
+
<span><a-input v-model:value="formState.lockMinutes" mr-12px />分钟</span>
|
|
204
|
+
</a-form-item>
|
|
205
|
+
</template>
|
|
206
|
+
<a-form-item label="默认密码设置" name="defaultPassword">
|
|
207
|
+
<a-input v-model:value="formState.defaultPassword" />
|
|
208
|
+
</a-form-item>
|
|
209
|
+
<a-form-item label="密码过期天数" name="expireDays">
|
|
210
|
+
<a-input v-model:value="formState.expireDays" mr-12px />天
|
|
211
|
+
</a-form-item>
|
|
212
|
+
<a-form-item label="是否开启强制修改初始化密码" name="forceChangeInitPwd">
|
|
213
|
+
<a-switch v-model:checked="formState.forceChangeInitPwd" />
|
|
214
|
+
</a-form-item>
|
|
215
|
+
<div v-auth="'change_safe_setting'" class="p-16px text-right b-t-1 b-t-style-solid b-t-color-[#e5e6eb] dark:b-t-color-[#424242]">
|
|
216
|
+
<a-button type="primary" @click="onSubmit">
|
|
217
|
+
更改配置
|
|
218
|
+
</a-button>
|
|
219
|
+
</div>
|
|
220
|
+
</a-form>
|
|
221
|
+
</div>
|
|
222
|
+
|
|
223
|
+
<div class="mt-10px bg-white dark:bg-[#141414] text-[#4e5969] dark:text-[#C9CDD4]">
|
|
224
|
+
<PassStrengthValidator v-model="formState.defaultPassword" v-model:validate="isDefaultPasswordValid" vertical />
|
|
225
|
+
</div>
|
|
226
|
+
</div>
|
|
227
|
+
</div>
|
|
228
|
+
</template>
|
|
229
|
+
|
|
230
|
+
<style lang="scss">
|
|
231
|
+
.safe-rule-form {
|
|
232
|
+
.ant-input,
|
|
233
|
+
.ant-select {
|
|
234
|
+
width: 90%;
|
|
235
|
+
}
|
|
236
|
+
}
|
|
237
|
+
</style>
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
import darkEnableData from '@/assets/lottie/tabbar/dark/enable.json?url';
|
|
2
|
+
import darkEnableHotkeysData from '@/assets/lottie/tabbar/dark/enableHotkeys.json?url';
|
|
3
|
+
import darkEnableIconData from '@/assets/lottie/tabbar/dark/enableIcon.json?url';
|
|
4
|
+
import darkEnableMemoryData from '@/assets/lottie/tabbar/dark/enableMemory.json?url';
|
|
5
|
+
import darkStyleData from '@/assets/lottie/tabbar/dark/style.json?url';
|
|
6
|
+
import lightEnableData from '@/assets/lottie/tabbar/light/enable.json?url';
|
|
7
|
+
import lightEnableHotkeysData from '@/assets/lottie/tabbar/light/enableHotkeys.json?url';
|
|
8
|
+
import lightEnableIconData from '@/assets/lottie/tabbar/light/enableIcon.json?url';
|
|
9
|
+
import lightEnableMemoryData from '@/assets/lottie/tabbar/light/enableMemory.json?url';
|
|
10
|
+
import lightStyleData from '@/assets/lottie/tabbar/light/style.json?url';
|
|
11
|
+
|
|
12
|
+
export {
|
|
13
|
+
darkEnableData,
|
|
14
|
+
darkEnableHotkeysData,
|
|
15
|
+
darkEnableIconData,
|
|
16
|
+
darkEnableMemoryData,
|
|
17
|
+
darkStyleData,
|
|
18
|
+
lightEnableData,
|
|
19
|
+
lightEnableHotkeysData,
|
|
20
|
+
lightEnableIconData,
|
|
21
|
+
lightEnableMemoryData,
|
|
22
|
+
lightStyleData,
|
|
23
|
+
};
|
|
@@ -0,0 +1,186 @@
|
|
|
1
|
+
<script setup lang="ts">
|
|
2
|
+
import { postSysconfigAddOrEidtSysThemeStyleConfig } from '@/api/modules/configData';
|
|
3
|
+
import { useSettingsStore } from '@/stores';
|
|
4
|
+
import { message } from 'ant-design-vue';
|
|
5
|
+
import SetItem from '../components/setItem.vue';
|
|
6
|
+
import {
|
|
7
|
+
darkEnableData,
|
|
8
|
+
darkEnableHotkeysData,
|
|
9
|
+
darkEnableIconData,
|
|
10
|
+
darkEnableMemoryData,
|
|
11
|
+
darkStyleData,
|
|
12
|
+
lightEnableData,
|
|
13
|
+
lightEnableHotkeysData,
|
|
14
|
+
lightEnableIconData,
|
|
15
|
+
lightEnableMemoryData,
|
|
16
|
+
lightStyleData,
|
|
17
|
+
} from './animationData.ts';
|
|
18
|
+
|
|
19
|
+
defineOptions({
|
|
20
|
+
name: 'TabbarAnimationSetting',
|
|
21
|
+
});
|
|
22
|
+
|
|
23
|
+
const settingsStore = useSettingsStore();
|
|
24
|
+
|
|
25
|
+
const styleOptions = [
|
|
26
|
+
{ label: '时尚', value: 'fashion' },
|
|
27
|
+
{ label: '卡片', value: 'card' },
|
|
28
|
+
{ label: '方块', value: 'square' },
|
|
29
|
+
];
|
|
30
|
+
type RelVal = Exclude<Settings.tabbar['style'], undefined>;
|
|
31
|
+
type Val = RelVal | '';
|
|
32
|
+
|
|
33
|
+
const tabbarAnimationList = reactive<
|
|
34
|
+
{
|
|
35
|
+
name: string
|
|
36
|
+
type: string
|
|
37
|
+
descripe: string
|
|
38
|
+
open: boolean
|
|
39
|
+
activeStyle: Val
|
|
40
|
+
styleOptions?: typeof styleOptions
|
|
41
|
+
lightData: string
|
|
42
|
+
darkData: string
|
|
43
|
+
}[]
|
|
44
|
+
>([
|
|
45
|
+
{
|
|
46
|
+
name: '是否启用',
|
|
47
|
+
type: 'switch',
|
|
48
|
+
descripe: '',
|
|
49
|
+
open: settingsStore.globalSettings.tabbar.enable,
|
|
50
|
+
activeStyle: '',
|
|
51
|
+
lightData: lightEnableData,
|
|
52
|
+
darkData: darkEnableData,
|
|
53
|
+
},
|
|
54
|
+
{
|
|
55
|
+
name: '风格',
|
|
56
|
+
type: 'check',
|
|
57
|
+
descripe: '',
|
|
58
|
+
open: true,
|
|
59
|
+
activeStyle: settingsStore.globalSettings.tabbar.style,
|
|
60
|
+
styleOptions,
|
|
61
|
+
lightData: lightStyleData,
|
|
62
|
+
darkData: darkStyleData,
|
|
63
|
+
},
|
|
64
|
+
{
|
|
65
|
+
name: '是否显示图标',
|
|
66
|
+
type: 'switch',
|
|
67
|
+
descripe: '',
|
|
68
|
+
open: settingsStore.globalSettings.tabbar.enableIcon,
|
|
69
|
+
activeStyle: '',
|
|
70
|
+
lightData: lightEnableIconData,
|
|
71
|
+
darkData: darkEnableIconData,
|
|
72
|
+
},
|
|
73
|
+
{
|
|
74
|
+
name: '是否启用记忆功能',
|
|
75
|
+
type: 'switch',
|
|
76
|
+
descripe: '开启该功能后,非固定和非常驻的标签页将在本次会话窗口中始终存在,刷新浏览器或重新登录时不会丢失',
|
|
77
|
+
open: settingsStore.globalSettings.tabbar.enableMemory,
|
|
78
|
+
activeStyle: '',
|
|
79
|
+
lightData: lightEnableMemoryData,
|
|
80
|
+
darkData: darkEnableMemoryData,
|
|
81
|
+
},
|
|
82
|
+
|
|
83
|
+
{
|
|
84
|
+
name: '是否启用快捷键',
|
|
85
|
+
type: 'switch',
|
|
86
|
+
descripe: '',
|
|
87
|
+
open: settingsStore.globalSettings.tabbar.enableHotkeys,
|
|
88
|
+
activeStyle: '',
|
|
89
|
+
lightData: lightEnableHotkeysData,
|
|
90
|
+
darkData: darkEnableHotkeysData,
|
|
91
|
+
},
|
|
92
|
+
]);
|
|
93
|
+
|
|
94
|
+
let jsonStr = '';
|
|
95
|
+
function onChange(index: number, ck: boolean | Val) {
|
|
96
|
+
switch (index) {
|
|
97
|
+
case 0:
|
|
98
|
+
settingsStore.globalSettings.tabbar.enable = ck as boolean;
|
|
99
|
+
jsonStr = JSON.stringify({
|
|
100
|
+
tabbar: {
|
|
101
|
+
enable: ck,
|
|
102
|
+
},
|
|
103
|
+
});
|
|
104
|
+
break;
|
|
105
|
+
case 1:
|
|
106
|
+
settingsStore.globalSettings.tabbar.style = ck as RelVal;
|
|
107
|
+
jsonStr = JSON.stringify({
|
|
108
|
+
tabbar: {
|
|
109
|
+
style: ck,
|
|
110
|
+
},
|
|
111
|
+
});
|
|
112
|
+
break;
|
|
113
|
+
case 2:
|
|
114
|
+
settingsStore.globalSettings.tabbar.enableIcon = ck as boolean;
|
|
115
|
+
jsonStr = JSON.stringify({
|
|
116
|
+
tabbar: {
|
|
117
|
+
enableIcon: ck,
|
|
118
|
+
},
|
|
119
|
+
});
|
|
120
|
+
break;
|
|
121
|
+
case 3:
|
|
122
|
+
settingsStore.globalSettings.tabbar.enableMemory = ck as boolean;
|
|
123
|
+
jsonStr = JSON.stringify({
|
|
124
|
+
tabbar: {
|
|
125
|
+
enableMemory: ck,
|
|
126
|
+
},
|
|
127
|
+
});
|
|
128
|
+
break;
|
|
129
|
+
case 4:
|
|
130
|
+
settingsStore.globalSettings.tabbar.enableHotkeys = ck as boolean;
|
|
131
|
+
jsonStr = JSON.stringify({
|
|
132
|
+
tabbar: {
|
|
133
|
+
enableHotkeys: ck,
|
|
134
|
+
},
|
|
135
|
+
});
|
|
136
|
+
break;
|
|
137
|
+
}
|
|
138
|
+
setStyle(jsonStr);
|
|
139
|
+
}
|
|
140
|
+
|
|
141
|
+
function setStyle(jsonStr: string) {
|
|
142
|
+
postSysconfigAddOrEidtSysThemeStyleConfig({ content: jsonStr }).then((res: API.ResponseDataBoolean) => {
|
|
143
|
+
if (res.success) {
|
|
144
|
+
message.success('设置成功');
|
|
145
|
+
}
|
|
146
|
+
});
|
|
147
|
+
}
|
|
148
|
+
</script>
|
|
149
|
+
|
|
150
|
+
<template>
|
|
151
|
+
<div
|
|
152
|
+
w-full
|
|
153
|
+
h-full
|
|
154
|
+
p-10px
|
|
155
|
+
>
|
|
156
|
+
<div class="w-full h-full bg-white overflow-y-auto p-10px flex flex-col box-border dark:bg-[#141414]">
|
|
157
|
+
<div class="h-[38px] pl-[16px] flex flex-row items-center bar-header">
|
|
158
|
+
<PubinfoIcon name="icon_tabbar" class="text-base mr-[6px]" :size="22" />
|
|
159
|
+
<span class="text-[16px] text-[#1d2129] dark:text-[#C9CDD4]">标签栏</span>
|
|
160
|
+
</div>
|
|
161
|
+
<div class="mt-[22px] grid grid-cols-3 gap-[20px] px-30px w-full h-0 max-w-1500px" aspect="[3/2] ">
|
|
162
|
+
<SetItem
|
|
163
|
+
v-for="(item, index) in tabbarAnimationList"
|
|
164
|
+
:key="item.name"
|
|
165
|
+
class="mb-20px"
|
|
166
|
+
aspect="[9/6]"
|
|
167
|
+
:name="item.name"
|
|
168
|
+
:descripe="item.descripe"
|
|
169
|
+
:open="item.open"
|
|
170
|
+
:type="item.type"
|
|
171
|
+
:active-style="item.activeStyle"
|
|
172
|
+
:style-options="item.styleOptions"
|
|
173
|
+
:light-animation-data="item.lightData"
|
|
174
|
+
:dark-animation-data="item.darkData"
|
|
175
|
+
@change="(val: Val) => onChange(index, val)"
|
|
176
|
+
/>
|
|
177
|
+
</div>
|
|
178
|
+
</div>
|
|
179
|
+
</div>
|
|
180
|
+
</template>
|
|
181
|
+
|
|
182
|
+
<style lang="scss" scoped>
|
|
183
|
+
.bar-header {
|
|
184
|
+
background: var(--g-bg);
|
|
185
|
+
}
|
|
186
|
+
</style>
|