mirror of
https://github.com/zclzone/vue-naive-admin.git
synced 2026-01-22 15:40:21 +08:00
Compare commits
15 Commits
4785842629
...
2.x
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
22693b02ee | ||
|
|
cba38db3c9 | ||
|
|
2e03a4b1a6 | ||
|
|
a5a20a30c9 | ||
|
|
9a7170f10c | ||
|
|
fb4d18cc0a | ||
|
|
d078bba63e | ||
|
|
5663f58b6e | ||
|
|
32700aee17 | ||
|
|
e593ba3ca5 | ||
|
|
d9de814074 | ||
|
|
5457c4e70b | ||
|
|
6757e47fb1 | ||
|
|
3fbcfdf0e1 | ||
|
|
d6764158f3 |
@@ -6,7 +6,7 @@ VITE_PUBLIC_PATH = '/'
|
|||||||
|
|
||||||
# Axios 基础路径
|
# Axios 基础路径
|
||||||
# VITE_AXIOS_BASE_URL = '/api' # 用于代理
|
# VITE_AXIOS_BASE_URL = '/api' # 用于代理
|
||||||
VITE_AXIOS_BASE_URL = 'https://mock.apipark.cn/m1/3776410-0-default' # apifox云端mock
|
VITE_AXIOS_BASE_URL = 'https://m1.apifoxmock.com/m1/3776410-3408296-default' # apifox云端mock
|
||||||
|
|
||||||
# 代理配置-target
|
# 代理配置-target
|
||||||
VITE_PROXY_TARGET = 'http://localhost:8085'
|
VITE_PROXY_TARGET = 'http://localhost:8085'
|
||||||
|
|||||||
@@ -4,7 +4,5 @@ VITE_USE_HASH = 'false'
|
|||||||
# 资源公共路径,需要以 /开头和结尾
|
# 资源公共路径,需要以 /开头和结尾
|
||||||
VITE_PUBLIC_PATH = '/'
|
VITE_PUBLIC_PATH = '/'
|
||||||
|
|
||||||
VITE_AXIOS_BASE_URL = '/api' # 用于代理
|
# VITE_AXIOS_BASE_URL = '/api' # 用于代理
|
||||||
|
VITE_AXIOS_BASE_URL = 'https://m1.apifoxmock.com/m1/3776410-3408296-default' # apifox云端mock
|
||||||
# 代理配置-target
|
|
||||||
VITE_PROXY_TARGET = 'http://localhost:8085'
|
|
||||||
|
|||||||
@@ -5,12 +5,17 @@
|
|||||||
</p>
|
</p>
|
||||||
<p align="center">
|
<p align="center">
|
||||||
<a href="./LICENSE"><img alt="MIT License" src="https://badgen.net/github/license/zclzone/vue-naive-admin"/></a>
|
<a href="./LICENSE"><img alt="MIT License" src="https://badgen.net/github/license/zclzone/vue-naive-admin"/></a>
|
||||||
|
<a href="https://gitcode.com/zclzone/vue-naive-admin"><img alt="GitCode" src="https://gitcode.com/zclzone/vue-naive-admin/star/badge.svg
|
||||||
|
"/></a>
|
||||||
</p>
|
</p>
|
||||||
|
|
||||||
---
|
---
|
||||||
|
|
||||||
<a href="https://hellogithub.com/repository/54f19ba1f9ae4238b3cbd111f3c428b0" target="_blank"><img src="https://abroad.hellogithub.com/v1/widgets/recommend.svg?rid=54f19ba1f9ae4238b3cbd111f3c428b0&claim_uid=jXGayRdJZScqMNr" alt="Featured|HelloGitHub" style="width: 250px; height: 54px;" width="250" height="54" /></a>
|
<a href="https://hellogithub.com/repository/54f19ba1f9ae4238b3cbd111f3c428b0" target="_blank"><img src="https://abroad.hellogithub.com/v1/widgets/recommend.svg?rid=54f19ba1f9ae4238b3cbd111f3c428b0&claim_uid=jXGayRdJZScqMNr" alt="Featured|HelloGitHub" style="width: 250px; height: 54px;" width="250" height="54" /></a>
|
||||||
|
|
||||||
|
> [!Tip]
|
||||||
|
> 我们提供Web(PC+H5+小程序)的技术支持服务及定制开发,不限前后端,详细需求可联系作者,微信: isme-admin,邮箱: zclzone@outlook.com
|
||||||
|
|
||||||
## 简介
|
## 简介
|
||||||
|
|
||||||
Vue Naive Admin 是一款极简风格的后台管理模板,包含前后端解决方案,前端使用 Vite + Vue3 + Pinia + Unocss,后端使用 Nestjs + TypeOrm + MySql,简单易用,赏心悦目,历经十几次重构和细节打磨,诚意满满!!
|
Vue Naive Admin 是一款极简风格的后台管理模板,包含前后端解决方案,前端使用 Vite + Vue3 + Pinia + Unocss,后端使用 Nestjs + TypeOrm + MySql,简单易用,赏心悦目,历经十几次重构和细节打磨,诚意满满!!
|
||||||
@@ -55,6 +60,7 @@ Vue Naive Admin 提供一套后端代码,技术栈使用 Nestjs + TypeOrm + My
|
|||||||
|
|
||||||
- 源码-github: [isme-nest-serve | github](https://github.com/zclzone/isme-nest-serve)
|
- 源码-github: [isme-nest-serve | github](https://github.com/zclzone/isme-nest-serve)
|
||||||
- 源码-gitee: [isme-nest-serve | gitee](https://gitee.com/isme-admin/isme-nest-serve)
|
- 源码-gitee: [isme-nest-serve | gitee](https://gitee.com/isme-admin/isme-nest-serve)
|
||||||
|
- 源码-gitcode: [isme-nest-serve | gitcode](https://gitcode.com/zclzone/isme-nest-serve)
|
||||||
|
|
||||||
## 文档
|
## 文档
|
||||||
|
|
||||||
|
|||||||
60
package.json
60
package.json
@@ -13,42 +13,42 @@
|
|||||||
},
|
},
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@arco-design/color": "^0.4.0",
|
"@arco-design/color": "^0.4.0",
|
||||||
"@vueuse/core": "^13.7.0",
|
"@vueuse/core": "^14.1.0",
|
||||||
"axios": "^1.11.0",
|
"axios": "^1.13.2",
|
||||||
"dayjs": "^1.11.13",
|
"dayjs": "^1.11.19",
|
||||||
"echarts": "^6.0.0",
|
"echarts": "^6.0.0",
|
||||||
"lodash-es": "^4.17.21",
|
"lodash-es": "^4.17.22",
|
||||||
"naive-ui": "^2.42.0",
|
"naive-ui": "^2.43.2",
|
||||||
"pinia": "^3.0.3",
|
"pinia": "^3.0.4",
|
||||||
"pinia-plugin-persistedstate": "^4.5.0",
|
"pinia-plugin-persistedstate": "^4.7.1",
|
||||||
"vue": "^3.5.20",
|
"vue": "^3.5.27",
|
||||||
"vue-echarts": "^7.0.3",
|
"vue-echarts": "^8.0.1",
|
||||||
"vue-router": "^4.5.1",
|
"vue-router": "^4.6.4",
|
||||||
"xlsx": "^0.18.5"
|
"xlsx": "^0.18.5"
|
||||||
},
|
},
|
||||||
"devDependencies": {
|
"devDependencies": {
|
||||||
"@antfu/eslint-config": "^5.2.1",
|
"@antfu/eslint-config": "^7.0.1",
|
||||||
"@iconify/json": "^2.2.378",
|
"@iconify/json": "^2.2.430",
|
||||||
"@unocss/eslint-config": "^66.4.2",
|
"@unocss/eslint-config": "^66.6.0",
|
||||||
"@unocss/eslint-plugin": "^66.4.2",
|
"@unocss/eslint-plugin": "^66.6.0",
|
||||||
"@unocss/preset-rem-to-px": "^66.4.2",
|
"@unocss/preset-rem-to-px": "^66.6.0",
|
||||||
"@vitejs/plugin-vue": "^6.0.1",
|
"@vitejs/plugin-vue": "^6.0.3",
|
||||||
"@vitejs/plugin-vue-jsx": "^5.1.0",
|
"@vitejs/plugin-vue-jsx": "^5.1.3",
|
||||||
"eslint": "^9.34.0",
|
"eslint": "^9.39.2",
|
||||||
"eslint-plugin-format": "^1.0.1",
|
"eslint-plugin-format": "^1.3.1",
|
||||||
"esno": "^4.8.0",
|
"esno": "^4.8.0",
|
||||||
"fs-extra": "^11.3.1",
|
"fs-extra": "^11.3.3",
|
||||||
"glob": "^11.0.3",
|
"glob": "^13.0.0",
|
||||||
"lint-staged": "^16.1.5",
|
"lint-staged": "^16.2.7",
|
||||||
"rollup-plugin-visualizer": "^6.0.3",
|
"rollup-plugin-visualizer": "^6.0.5",
|
||||||
"simple-git-hooks": "^2.13.1",
|
"simple-git-hooks": "^2.13.1",
|
||||||
"taze": "^19.3.0",
|
"taze": "^19.9.2",
|
||||||
"unocss": "^66.4.2",
|
"unocss": "^66.6.0",
|
||||||
"unplugin-auto-import": "^20.0.0",
|
"unplugin-auto-import": "^21.0.0",
|
||||||
"unplugin-vue-components": "^29.0.0",
|
"unplugin-vue-components": "^31.0.0",
|
||||||
"vite": "^7.1.3",
|
"vite": "^7.3.1",
|
||||||
"vite-plugin-router-warn": "^1.0.0",
|
"vite-plugin-router-warn": "^2.0.0",
|
||||||
"vite-plugin-vue-devtools": "^8.0.1",
|
"vite-plugin-vue-devtools": "^8.0.5",
|
||||||
"vue3-intro-step": "^1.0.5"
|
"vue3-intro-step": "^1.0.5"
|
||||||
},
|
},
|
||||||
"simple-git-hooks": {
|
"simple-git-hooks": {
|
||||||
|
|||||||
3844
pnpm-lock.yaml
generated
3844
pnpm-lock.yaml
generated
File diff suppressed because it is too large
Load Diff
@@ -39,6 +39,7 @@ async function toggleDark({ clientX, clientY }) {
|
|||||||
duration: 500,
|
duration: 500,
|
||||||
easing: 'ease-in',
|
easing: 'ease-in',
|
||||||
pseudoElement: `::view-transition-${isDark.value ? 'old' : 'new'}(root)`,
|
pseudoElement: `::view-transition-${isDark.value ? 'old' : 'new'}(root)`,
|
||||||
|
fill: 'both',
|
||||||
},
|
},
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -34,8 +34,8 @@ html,
|
|||||||
-webkit-text-size-adjust: 100%; /* 2 */
|
-webkit-text-size-adjust: 100%; /* 2 */
|
||||||
-moz-tab-size: 4; /* 3 */
|
-moz-tab-size: 4; /* 3 */
|
||||||
tab-size: 4; /* 3 */
|
tab-size: 4; /* 3 */
|
||||||
font-family: ui-sans-serif, system-ui, sans-serif, 'Apple Color Emoji', 'Segoe UI Emoji', 'Segoe UI Symbol',
|
font-family:
|
||||||
'Noto Color Emoji'; /* 4 */
|
ui-sans-serif, system-ui, sans-serif, 'Apple Color Emoji', 'Segoe UI Emoji', 'Segoe UI Symbol', 'Noto Color Emoji'; /* 4 */
|
||||||
font-feature-settings: normal; /* 5 */
|
font-feature-settings: normal; /* 5 */
|
||||||
font-variation-settings: normal; /* 6 */
|
font-variation-settings: normal; /* 6 */
|
||||||
-webkit-tap-highlight-color: transparent; /* 7 */
|
-webkit-tap-highlight-color: transparent; /* 7 */
|
||||||
@@ -114,7 +114,8 @@ code,
|
|||||||
kbd,
|
kbd,
|
||||||
samp,
|
samp,
|
||||||
pre {
|
pre {
|
||||||
font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, 'Liberation Mono', 'Courier New', monospace; /* 1 */
|
font-family:
|
||||||
|
ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, 'Liberation Mono', 'Courier New', monospace; /* 1 */
|
||||||
font-feature-settings: normal; /* 2 */
|
font-feature-settings: normal; /* 2 */
|
||||||
font-variation-settings: normal; /* 3 */
|
font-variation-settings: normal; /* 3 */
|
||||||
font-size: 1em; /* 4 */
|
font-size: 1em; /* 4 */
|
||||||
|
|||||||
@@ -10,45 +10,34 @@
|
|||||||
import { useAuthStore } from '@/store'
|
import { useAuthStore } from '@/store'
|
||||||
|
|
||||||
let isConfirming = false
|
let isConfirming = false
|
||||||
|
|
||||||
|
function handleAuthExpired(content, needTip) {
|
||||||
|
if (isConfirming || !needTip)
|
||||||
|
return
|
||||||
|
isConfirming = true
|
||||||
|
$dialog.confirm({
|
||||||
|
title: '提示',
|
||||||
|
type: 'info',
|
||||||
|
content,
|
||||||
|
confirm() {
|
||||||
|
useAuthStore().logout()
|
||||||
|
window.$message?.success('已退出登录')
|
||||||
|
isConfirming = false
|
||||||
|
},
|
||||||
|
cancel() {
|
||||||
|
isConfirming = false
|
||||||
|
},
|
||||||
|
})
|
||||||
|
return false
|
||||||
|
}
|
||||||
|
|
||||||
export function resolveResError(code, message, needTip = true) {
|
export function resolveResError(code, message, needTip = true) {
|
||||||
switch (code) {
|
switch (code) {
|
||||||
case 401:
|
case 401:
|
||||||
if (isConfirming || !needTip)
|
return handleAuthExpired('登录已过期,是否重新登录?', needTip)
|
||||||
return
|
|
||||||
isConfirming = true
|
|
||||||
$dialog.confirm({
|
|
||||||
title: '提示',
|
|
||||||
type: 'info',
|
|
||||||
content: '登录已过期,是否重新登录?',
|
|
||||||
confirm() {
|
|
||||||
useAuthStore().logout()
|
|
||||||
window.$message?.success('已退出登录')
|
|
||||||
isConfirming = false
|
|
||||||
},
|
|
||||||
cancel() {
|
|
||||||
isConfirming = false
|
|
||||||
},
|
|
||||||
})
|
|
||||||
return false
|
|
||||||
case 11007:
|
case 11007:
|
||||||
case 11008:
|
case 11008:
|
||||||
if (isConfirming || !needTip)
|
return handleAuthExpired(`${message},是否重新登录?`, needTip)
|
||||||
return
|
|
||||||
isConfirming = true
|
|
||||||
$dialog.confirm({
|
|
||||||
title: '提示',
|
|
||||||
type: 'info',
|
|
||||||
content: `${message},是否重新登录?`,
|
|
||||||
confirm() {
|
|
||||||
useAuthStore().logout()
|
|
||||||
window.$message?.success('已退出登录')
|
|
||||||
isConfirming = false
|
|
||||||
},
|
|
||||||
cancel() {
|
|
||||||
isConfirming = false
|
|
||||||
},
|
|
||||||
})
|
|
||||||
return false
|
|
||||||
case 403:
|
case 403:
|
||||||
message = '请求被拒绝'
|
message = '请求被拒绝'
|
||||||
break
|
break
|
||||||
|
|||||||
@@ -62,11 +62,7 @@ defineOptions({ name: 'ImgUpload' })
|
|||||||
|
|
||||||
const { copy, copied } = useClipboard()
|
const { copy, copied } = useClipboard()
|
||||||
|
|
||||||
const imgList = reactive([
|
const imgList = reactive([])
|
||||||
{ url: 'https://img.isme.top/isme/67208863145ef.jpg' },
|
|
||||||
{ url: 'https://img.isme.top/isme/67208ab2a9de0.jpg' },
|
|
||||||
{ url: 'https://img.isme.top/isme/67208ab4c6596.jpg' },
|
|
||||||
])
|
|
||||||
|
|
||||||
watch(copied, (val) => {
|
watch(copied, (val) => {
|
||||||
if (val)
|
if (val)
|
||||||
|
|||||||
@@ -250,7 +250,7 @@ const skillOption = {
|
|||||||
},
|
},
|
||||||
series: [
|
series: [
|
||||||
{
|
{
|
||||||
top: '12%',
|
bottom: '12%',
|
||||||
type: 'pie',
|
type: 'pie',
|
||||||
radius: ['35%', '90%'],
|
radius: ['35%', '90%'],
|
||||||
avoidLabelOverlap: true,
|
avoidLabelOverlap: true,
|
||||||
|
|||||||
@@ -69,6 +69,9 @@ export default defineConfig(({ mode }) => {
|
|||||||
},
|
},
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
|
optimizeDeps: {
|
||||||
|
include: ['vue3-intro-step'],
|
||||||
|
},
|
||||||
build: {
|
build: {
|
||||||
chunkSizeWarningLimit: 1024, // chunk 大小警告的限制(单位kb)
|
chunkSizeWarningLimit: 1024, // chunk 大小警告的限制(单位kb)
|
||||||
},
|
},
|
||||||
|
|||||||
Reference in New Issue
Block a user