Compare commits

..

3 Commits

Author SHA1 Message Date
coward
ddef41dfca 添加 web/.env 2024-08-22 16:02:01 +08:00
6c6b40593e 🎨优化 2024-08-22 16:01:00 +08:00
45d83da5c7 🎨优化一哈 2024-08-22 15:37:21 +08:00
8 changed files with 4874 additions and 30 deletions

56
.gitignore vendored
View File

@@ -233,33 +233,33 @@ fabric.properties
# vendor/
# Go workspace file
go.work
./go.work
.idea
web/.idea
./.idea
./web/.idea
web/node_modules
web/.DS_Store
web/dist
web/dist-ssr
web/*.local
web/.eslintcache
web/report.html
web/vite.config.*.timestamp*
./web/node_modules
./web/.DS_Store
./web/dist
./web/dist-ssr
./web/*.local
./web/.eslintcache
./web/report.html
./web/vite.config.*.timestamp*
web/yarn.lock
web/npm-debug.log*
web/.pnpm-error.log*
web/.pnpm-debug.log
web/tests/**/coverage/
web/.vscode/
./web/yarn.lock
./web/npm-debug.log*
./web/.pnpm-error.log*
./web/.pnpm-debug.log
./web/tests/**/coverage/
./web/.vscode/
# Editor directories and files
web/*.suo
web/*.ntvs*
web/*.njsproj
web/*.sln
web/tsconfig.tsbuildinfo
./web/*.suo
./web/*.ntvs*
./web/*.njsproj
./web/*.sln
./web/tsconfig.tsbuildinfo
dist/assets
dist/resource
@@ -267,10 +267,10 @@ dist/favicon.png
dist/favicon.svg
dist/index.html
template/tmp/*
logs/*
app.yaml
*.db
.env
*.env
./template/tmp/*
./logs/*
./app.yaml
./*.db
./.env
./*.env

3
web/.env Normal file
View File

@@ -0,0 +1,3 @@
VITE_TITLE = 'Wireguard-UI'
VITE_PORT = 3100

View File

@@ -37,7 +37,6 @@ export async function addDynamicRoutes() {
// 有token的情况
const userStore = useUserStore()
try {
const permissionStore = usePermissionStore()
!userStore.id && (await userStore.getUserInfo())
@@ -49,8 +48,8 @@ export async function addDynamicRoutes() {
router.addRoute(NOT_FOUND_ROUTE)
} catch (error) {
console.error(error)
$message.error('初始化用户信息失败: ' + error)
userStore.logout()
$message.error('初始化用户信息失败: ' + error)
}
}

View File

@@ -6,6 +6,7 @@ export default {
component: Layout,
redirect: '/client',
meta: {
title: '客户端',
order: 2,
},
children: [

View File

@@ -6,6 +6,7 @@ export default {
component: Layout,
redirect: '/setting',
meta: {
title: '设置',
order: 3,
},
children: [

View File

@@ -6,6 +6,7 @@ export default {
component: Layout,
redirect: '/user',
meta: {
title: '管理员',
order: 1,
},
children: [

View File

@@ -6,6 +6,7 @@ export default {
component: Layout,
redirect: '/workbench',
meta: {
title: '工作台',
order: 0,
},
children: [

4838
web/stats.html Normal file

File diff suppressed because one or more lines are too long