release: update 3.9.3
This commit is contained in:
parent
c6e25d6933
commit
132fbbade3
@ -1,8 +1,6 @@
|
|||||||
// 模拟后端动态生成路由
|
// 模拟后端动态生成路由
|
||||||
import { MockMethod } from "vite-plugin-mock";
|
import { MockMethod } from "vite-plugin-mock";
|
||||||
|
|
||||||
import Lollipop from "@iconify-icons/ep/lollipop";
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* roles:页面级别权限,这里模拟二种 "admin"、"common"
|
* roles:页面级别权限,这里模拟二种 "admin"、"common"
|
||||||
* admin:管理员角色
|
* admin:管理员角色
|
||||||
@ -13,7 +11,7 @@ const permissionRouter = {
|
|||||||
path: "/permission",
|
path: "/permission",
|
||||||
meta: {
|
meta: {
|
||||||
title: "权限管理",
|
title: "权限管理",
|
||||||
icon: Lollipop,
|
icon: "lollipop",
|
||||||
rank: 10
|
rank: 10
|
||||||
},
|
},
|
||||||
children: [
|
children: [
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"name": "pure-admin-thin",
|
"name": "pure-admin-thin",
|
||||||
"version": "3.9.2",
|
"version": "3.9.3",
|
||||||
"private": true,
|
"private": true,
|
||||||
"scripts": {
|
"scripts": {
|
||||||
"dev": "NODE_OPTIONS=--max-old-space-size=4096 vite",
|
"dev": "NODE_OPTIONS=--max-old-space-size=4096 vite",
|
||||||
@ -31,8 +31,8 @@
|
|||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@ctrl/tinycolor": "^3.4.1",
|
"@ctrl/tinycolor": "^3.4.1",
|
||||||
"@pureadmin/descriptions": "^1.1.0",
|
"@pureadmin/descriptions": "^1.1.0",
|
||||||
"@pureadmin/table": "^1.8.2",
|
"@pureadmin/table": "^1.8.3",
|
||||||
"@pureadmin/utils": "^1.7.2",
|
"@pureadmin/utils": "^1.7.4",
|
||||||
"@vueuse/core": "^9.6.0",
|
"@vueuse/core": "^9.6.0",
|
||||||
"@vueuse/motion": "2.0.0-beta.12",
|
"@vueuse/motion": "2.0.0-beta.12",
|
||||||
"animate.css": "^4.1.1",
|
"animate.css": "^4.1.1",
|
||||||
|
16
pnpm-lock.yaml
generated
16
pnpm-lock.yaml
generated
@ -8,9 +8,9 @@ specifiers:
|
|||||||
'@iconify-icons/ri': ^1.2.3
|
'@iconify-icons/ri': ^1.2.3
|
||||||
'@iconify/vue': ^4.0.0
|
'@iconify/vue': ^4.0.0
|
||||||
'@pureadmin/descriptions': ^1.1.0
|
'@pureadmin/descriptions': ^1.1.0
|
||||||
'@pureadmin/table': ^1.8.2
|
'@pureadmin/table': ^1.8.3
|
||||||
'@pureadmin/theme': ^2.4.0
|
'@pureadmin/theme': ^2.4.0
|
||||||
'@pureadmin/utils': ^1.7.2
|
'@pureadmin/utils': ^1.7.4
|
||||||
'@types/element-resize-detector': 1.1.3
|
'@types/element-resize-detector': 1.1.3
|
||||||
'@types/js-cookie': ^3.0.1
|
'@types/js-cookie': ^3.0.1
|
||||||
'@types/lodash': ^4.14.180
|
'@types/lodash': ^4.14.180
|
||||||
@ -93,8 +93,8 @@ specifiers:
|
|||||||
dependencies:
|
dependencies:
|
||||||
'@ctrl/tinycolor': 3.4.1
|
'@ctrl/tinycolor': 3.4.1
|
||||||
'@pureadmin/descriptions': 1.1.1_element-plus@2.2.26
|
'@pureadmin/descriptions': 1.1.1_element-plus@2.2.26
|
||||||
'@pureadmin/table': 1.8.2_element-plus@2.2.26
|
'@pureadmin/table': 1.8.3_element-plus@2.2.26
|
||||||
'@pureadmin/utils': 1.7.2_aotapuqn7htzdjltsyimavekky
|
'@pureadmin/utils': 1.7.4_aotapuqn7htzdjltsyimavekky
|
||||||
'@vueuse/core': 9.6.0_vue@3.2.45
|
'@vueuse/core': 9.6.0_vue@3.2.45
|
||||||
'@vueuse/motion': 2.0.0-beta.12_vue@3.2.45
|
'@vueuse/motion': 2.0.0-beta.12_vue@3.2.45
|
||||||
animate.css: 4.1.1
|
animate.css: 4.1.1
|
||||||
@ -823,8 +823,8 @@ packages:
|
|||||||
vue: 3.2.45
|
vue: 3.2.45
|
||||||
dev: false
|
dev: false
|
||||||
|
|
||||||
/@pureadmin/table/1.8.2_element-plus@2.2.26:
|
/@pureadmin/table/1.8.3_element-plus@2.2.26:
|
||||||
resolution: {integrity: sha512-FGh1aOfgQtX16pCnP+bxg49TetcZDhdykIue0m5d8NIj6zkvJP53JU+DkUpvqvKmUiMsvIwme6e17BLZMmMiOw==}
|
resolution: {integrity: sha512-M+I+CDu74s/ffNybbDg0rHhiMHTdkgVIaksfmmrEwjuLB2nEaz7R0tob2qC5rKE96U2Z246meDHBidyQNx2z9w==}
|
||||||
peerDependencies:
|
peerDependencies:
|
||||||
element-plus: ^2.0.0
|
element-plus: ^2.0.0
|
||||||
dependencies:
|
dependencies:
|
||||||
@ -840,8 +840,8 @@ packages:
|
|||||||
string-hash: 1.1.3
|
string-hash: 1.1.3
|
||||||
dev: true
|
dev: true
|
||||||
|
|
||||||
/@pureadmin/utils/1.7.2_aotapuqn7htzdjltsyimavekky:
|
/@pureadmin/utils/1.7.4_aotapuqn7htzdjltsyimavekky:
|
||||||
resolution: {integrity: sha512-L8tmogs9HCX6nuga1g79DcZr3KXNoWnIFcyP2z4zpmUmdBBAmMpXXz3Z+emI6HELmZu8DFx+v1MfKxccgsODRQ==}
|
resolution: {integrity: sha512-uJNHcb2sO7R2avALf+v4TGyuZtJix0Wpw/kMb6eO4C003ZQImuGGi9WlxHaOlESrMyFHZ1AjWm5AqLwJLnpVlw==}
|
||||||
peerDependencies:
|
peerDependencies:
|
||||||
dayjs: '*'
|
dayjs: '*'
|
||||||
echarts: '*'
|
echarts: '*'
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
{
|
{
|
||||||
"Version": "3.9.2",
|
"Version": "3.9.3",
|
||||||
"Title": "PureAdmin",
|
"Title": "PureAdmin",
|
||||||
"FixedHeader": true,
|
"FixedHeader": true,
|
||||||
"HiddenSideBar": false,
|
"HiddenSideBar": false,
|
||||||
|
14
src/components/ReIcon/src/offlineIcon.ts
Normal file
14
src/components/ReIcon/src/offlineIcon.ts
Normal file
@ -0,0 +1,14 @@
|
|||||||
|
import { addIcon } from "@iconify/vue/dist/offline";
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 这里存放本地图标,在 src/layout/index.vue 文件中加载,避免在首启动加载
|
||||||
|
*/
|
||||||
|
|
||||||
|
// 本地菜单图标,后端在路由的icon中返回对应的图标字符串并且前端在此处使用addIcon添加即可渲染菜单图标
|
||||||
|
import HomeFilled from "@iconify-icons/ep/home-filled";
|
||||||
|
import InformationLine from "@iconify-icons/ri/information-line";
|
||||||
|
import Lollipop from "@iconify-icons/ep/lollipop";
|
||||||
|
|
||||||
|
addIcon("homeFilled", HomeFilled);
|
||||||
|
addIcon("informationLine", InformationLine);
|
||||||
|
addIcon("lollipop", Lollipop);
|
@ -1,4 +1,13 @@
|
|||||||
<script setup lang="ts">
|
<script setup lang="ts">
|
||||||
|
import {
|
||||||
|
ref,
|
||||||
|
unref,
|
||||||
|
watch,
|
||||||
|
reactive,
|
||||||
|
computed,
|
||||||
|
nextTick,
|
||||||
|
onBeforeMount
|
||||||
|
} from "vue";
|
||||||
import {
|
import {
|
||||||
useDark,
|
useDark,
|
||||||
debounce,
|
debounce,
|
||||||
@ -17,7 +26,6 @@ import { useNav } from "@/layout/hooks/useNav";
|
|||||||
import { useAppStoreHook } from "@/store/modules/app";
|
import { useAppStoreHook } from "@/store/modules/app";
|
||||||
import { toggleTheme } from "@pureadmin/theme/dist/browser-utils";
|
import { toggleTheme } from "@pureadmin/theme/dist/browser-utils";
|
||||||
import { useMultiTagsStoreHook } from "@/store/modules/multiTags";
|
import { useMultiTagsStoreHook } from "@/store/modules/multiTags";
|
||||||
import { ref, unref, watch, reactive, computed, nextTick } from "vue";
|
|
||||||
import { useDataThemeChange } from "@/layout/hooks/useDataThemeChange";
|
import { useDataThemeChange } from "@/layout/hooks/useDataThemeChange";
|
||||||
|
|
||||||
import dayIcon from "@/assets/svg/day.svg?component";
|
import dayIcon from "@/assets/svg/day.svg?component";
|
||||||
@ -189,16 +197,6 @@ function setLayoutModel(layout: string) {
|
|||||||
useAppStoreHook().setLayout(layout);
|
useAppStoreHook().setLayout(layout);
|
||||||
}
|
}
|
||||||
|
|
||||||
/* 初始化项目配置 */
|
|
||||||
nextTick(() => {
|
|
||||||
settings.greyVal &&
|
|
||||||
document.querySelector("html")?.setAttribute("class", "html-grey");
|
|
||||||
settings.weakVal &&
|
|
||||||
document.querySelector("html")?.setAttribute("class", "html-weakness");
|
|
||||||
settings.tabsVal && tagsChange();
|
|
||||||
dataThemeChange();
|
|
||||||
});
|
|
||||||
|
|
||||||
watch($storage, ({ layout }) => {
|
watch($storage, ({ layout }) => {
|
||||||
switch (layout["layout"]) {
|
switch (layout["layout"]) {
|
||||||
case "vertical":
|
case "vertical":
|
||||||
@ -218,6 +216,18 @@ watch($storage, ({ layout }) => {
|
|||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
|
onBeforeMount(() => {
|
||||||
|
dataThemeChange();
|
||||||
|
/* 初始化项目配置 */
|
||||||
|
nextTick(() => {
|
||||||
|
settings.greyVal &&
|
||||||
|
document.querySelector("html")?.setAttribute("class", "html-grey");
|
||||||
|
settings.weakVal &&
|
||||||
|
document.querySelector("html")?.setAttribute("class", "html-weakness");
|
||||||
|
settings.tabsVal && tagsChange();
|
||||||
|
});
|
||||||
|
});
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
<template>
|
<template>
|
||||||
|
@ -35,7 +35,10 @@ watch(
|
|||||||
</script>
|
</script>
|
||||||
|
|
||||||
<template>
|
<template>
|
||||||
<div class="horizontal-header">
|
<div
|
||||||
|
v-loading="usePermissionStoreHook().wholeMenus.length === 0"
|
||||||
|
class="horizontal-header"
|
||||||
|
>
|
||||||
<div class="horizontal-header-left" @click="backHome">
|
<div class="horizontal-header-left" @click="backHome">
|
||||||
<FontIcon icon="team-iconlogo" svg style="width: 35px; height: 35px" />
|
<FontIcon icon="team-iconlogo" svg style="width: 35px; height: 35px" />
|
||||||
<h4>{{ title }}</h4>
|
<h4>{{ title }}</h4>
|
||||||
@ -93,6 +96,9 @@ watch(
|
|||||||
</template>
|
</template>
|
||||||
|
|
||||||
<style lang="scss" scoped>
|
<style lang="scss" scoped>
|
||||||
|
:deep(.el-loading-mask) {
|
||||||
|
opacity: 0.45;
|
||||||
|
}
|
||||||
.logout {
|
.logout {
|
||||||
max-width: 120px;
|
max-width: 120px;
|
||||||
|
|
||||||
|
@ -51,7 +51,11 @@ watch(
|
|||||||
</script>
|
</script>
|
||||||
|
|
||||||
<template>
|
<template>
|
||||||
<div v-if="device !== 'mobile'" class="horizontal-header">
|
<div
|
||||||
|
v-if="device !== 'mobile'"
|
||||||
|
class="horizontal-header"
|
||||||
|
v-loading="usePermissionStoreHook().wholeMenus.length === 0"
|
||||||
|
>
|
||||||
<el-menu
|
<el-menu
|
||||||
router
|
router
|
||||||
ref="menuRef"
|
ref="menuRef"
|
||||||
@ -124,6 +128,9 @@ watch(
|
|||||||
</template>
|
</template>
|
||||||
|
|
||||||
<style lang="scss" scoped>
|
<style lang="scss" scoped>
|
||||||
|
:deep(.el-loading-mask) {
|
||||||
|
opacity: 0.45;
|
||||||
|
}
|
||||||
.logout {
|
.logout {
|
||||||
max-width: 120px;
|
max-width: 120px;
|
||||||
|
|
||||||
|
@ -202,7 +202,7 @@ function resolvePath(routePath) {
|
|||||||
placement="top"
|
placement="top"
|
||||||
:effect="tooltipEffect"
|
:effect="tooltipEffect"
|
||||||
:offset="-10"
|
:offset="-10"
|
||||||
:disabled="!isCollapse && !onlyOneChild.showTooltip"
|
:disabled="!onlyOneChild.showTooltip"
|
||||||
>
|
>
|
||||||
<template #content>
|
<template #content>
|
||||||
{{ onlyOneChild.meta.title }}
|
{{ onlyOneChild.meta.title }}
|
||||||
|
@ -59,7 +59,10 @@ watch(
|
|||||||
</script>
|
</script>
|
||||||
|
|
||||||
<template>
|
<template>
|
||||||
<div :class="['sidebar-container', showLogo ? 'has-logo' : '']">
|
<div
|
||||||
|
v-loading="menuData.length === 0"
|
||||||
|
:class="['sidebar-container', showLogo ? 'has-logo' : '']"
|
||||||
|
>
|
||||||
<Logo v-if="showLogo" :collapse="isCollapse" />
|
<Logo v-if="showLogo" :collapse="isCollapse" />
|
||||||
<el-scrollbar
|
<el-scrollbar
|
||||||
wrap-class="scrollbar-wrapper"
|
wrap-class="scrollbar-wrapper"
|
||||||
@ -91,3 +94,9 @@ watch(
|
|||||||
/>
|
/>
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
|
<style scoped>
|
||||||
|
:deep(.el-loading-mask) {
|
||||||
|
opacity: 0.45;
|
||||||
|
}
|
||||||
|
</style>
|
||||||
|
@ -1,5 +1,7 @@
|
|||||||
<script setup lang="ts">
|
<script setup lang="ts">
|
||||||
import "animate.css";
|
import "animate.css";
|
||||||
|
// 引入 src/components/ReIcon/src/offlineIcon.ts 文件中所有使用addIcon添加过的本地图标
|
||||||
|
import "@/components/ReIcon/src/offlineIcon";
|
||||||
// vxe-table的所有icon不支持component模式,间接依赖了font-awesome
|
// vxe-table的所有icon不支持component模式,间接依赖了font-awesome
|
||||||
// import "font-awesome/css/font-awesome.min.css";
|
// import "font-awesome/css/font-awesome.min.css";
|
||||||
import { setType } from "./types";
|
import { setType } from "./types";
|
||||||
|
@ -1,5 +1,4 @@
|
|||||||
import type { IconifyIcon } from "@iconify/vue";
|
import type { IconifyIcon } from "@iconify/vue";
|
||||||
import HomeFilled from "@iconify-icons/ep/home-filled";
|
|
||||||
|
|
||||||
export const routerArrays: Array<RouteConfigs> = [
|
export const routerArrays: Array<RouteConfigs> = [
|
||||||
{
|
{
|
||||||
@ -7,7 +6,7 @@ export const routerArrays: Array<RouteConfigs> = [
|
|||||||
parentPath: "/",
|
parentPath: "/",
|
||||||
meta: {
|
meta: {
|
||||||
title: "首页",
|
title: "首页",
|
||||||
icon: HomeFilled
|
icon: "homeFilled"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
];
|
];
|
||||||
|
@ -1,10 +1,8 @@
|
|||||||
import InformationLine from "@iconify-icons/ri/information-line";
|
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
path: "/error",
|
path: "/error",
|
||||||
redirect: "/error/403",
|
redirect: "/error/403",
|
||||||
meta: {
|
meta: {
|
||||||
icon: InformationLine,
|
icon: "informationLine",
|
||||||
title: "异常页面",
|
title: "异常页面",
|
||||||
rank: 9
|
rank: 9
|
||||||
},
|
},
|
||||||
|
@ -1,5 +1,4 @@
|
|||||||
const Layout = () => import("@/layout/index.vue");
|
const Layout = () => import("@/layout/index.vue");
|
||||||
import HomeFilled from "@iconify-icons/ep/home-filled";
|
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
path: "/",
|
path: "/",
|
||||||
@ -7,7 +6,7 @@ export default {
|
|||||||
component: Layout,
|
component: Layout,
|
||||||
redirect: "/welcome",
|
redirect: "/welcome",
|
||||||
meta: {
|
meta: {
|
||||||
icon: HomeFilled,
|
icon: "homeFilled",
|
||||||
title: "首页",
|
title: "首页",
|
||||||
rank: 0
|
rank: 0
|
||||||
},
|
},
|
||||||
|
@ -1,5 +1,4 @@
|
|||||||
const Layout = () => import("@/layout/index.vue");
|
const Layout = () => import("@/layout/index.vue");
|
||||||
import HomeFilled from "@iconify-icons/ep/home-filled";
|
|
||||||
|
|
||||||
export default [
|
export default [
|
||||||
{
|
{
|
||||||
@ -16,7 +15,7 @@ export default [
|
|||||||
path: "/redirect",
|
path: "/redirect",
|
||||||
component: Layout,
|
component: Layout,
|
||||||
meta: {
|
meta: {
|
||||||
icon: HomeFilled,
|
icon: "homeFilled",
|
||||||
title: "首页",
|
title: "首页",
|
||||||
showLink: false,
|
showLink: false,
|
||||||
rank: 104
|
rank: 104
|
||||||
|
@ -198,7 +198,7 @@ function initRouter() {
|
|||||||
} else {
|
} else {
|
||||||
return new Promise(resolve => {
|
return new Promise(resolve => {
|
||||||
getAsyncRoutes().then(({ data }) => {
|
getAsyncRoutes().then(({ data }) => {
|
||||||
handleAsyncRoutes(data);
|
handleAsyncRoutes(cloneDeep(data));
|
||||||
storageSession.setItem(key, data);
|
storageSession.setItem(key, data);
|
||||||
resolve(router);
|
resolve(router);
|
||||||
});
|
});
|
||||||
@ -207,7 +207,7 @@ function initRouter() {
|
|||||||
} else {
|
} else {
|
||||||
return new Promise(resolve => {
|
return new Promise(resolve => {
|
||||||
getAsyncRoutes().then(({ data }) => {
|
getAsyncRoutes().then(({ data }) => {
|
||||||
handleAsyncRoutes(data);
|
handleAsyncRoutes(cloneDeep(data));
|
||||||
resolve(router);
|
resolve(router);
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
|
Loading…
x
Reference in New Issue
Block a user