refactor: 项目细节优化
This commit is contained in:
@@ -6,12 +6,12 @@ export default {
|
||||
},
|
||||
// 登录页面国际化
|
||||
login: {
|
||||
title: 'Youlai Mall Management System',
|
||||
title: 'vue3-element-admin',
|
||||
username: 'Username',
|
||||
password: 'Password',
|
||||
login: 'Login',
|
||||
code: 'Verification Code',
|
||||
copyright: 'Copyright © 2021 - 2022 youlai.tech All Rights Reserved. ',
|
||||
copyright: '',
|
||||
icp: ''
|
||||
},
|
||||
// 导航栏国际化
|
||||
|
||||
@@ -6,13 +6,13 @@ export default {
|
||||
},
|
||||
// 登录页面国际化
|
||||
login:{
|
||||
title: '有来商城管理系统 Vue3',
|
||||
title: 'vue3-element-admin',
|
||||
username:'用户名',
|
||||
password:'密码',
|
||||
login:'登 录',
|
||||
code:'请输入验证码',
|
||||
copyright:'Copyright © 2021 - 2022 youlai.tech All Rights Reserved. 有来技术 版权所有',
|
||||
icp:'ICP备案号:皖ICP备20006496号-2'
|
||||
copyright:'',
|
||||
icp:''
|
||||
},
|
||||
navbar:{
|
||||
dashboard: '首页',
|
||||
|
||||
@@ -23,7 +23,7 @@ const props = defineProps({
|
||||
}
|
||||
})
|
||||
|
||||
const title=ref("youlai-mall")
|
||||
const title=ref("vue3-element-admin")
|
||||
const logo=ref("http://cdn.youlai.tech/logo.png")
|
||||
|
||||
</script>
|
||||
|
||||
6
src/types/index.d.ts
vendored
6
src/types/index.d.ts
vendored
@@ -15,11 +15,7 @@ export * from './api/sms/advert'
|
||||
export * from './api/oms/order'
|
||||
export * from './api/ums/member'
|
||||
|
||||
export * from './store/user'
|
||||
export * from './store/app'
|
||||
export * from './store/permission'
|
||||
export * from './store/setting'
|
||||
export * from './store/tagsView'
|
||||
export * from './store'
|
||||
|
||||
export * from './common'
|
||||
|
||||
|
||||
57
src/types/store.d.ts
vendored
Normal file
57
src/types/store.d.ts
vendored
Normal file
@@ -0,0 +1,57 @@
|
||||
|
||||
import {RouteRecordRaw,RouteLocationNormalized} from "vue-router";
|
||||
/**
|
||||
* 用户状态类型声明
|
||||
*/
|
||||
export interface AppState {
|
||||
device: string,
|
||||
sidebar: {
|
||||
opened: boolean,
|
||||
withoutAnimation: boolean
|
||||
},
|
||||
language:string,
|
||||
size:string
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* 权限类型声明
|
||||
*/
|
||||
export interface PermissionState{
|
||||
routes:RouteRecordRaw[]
|
||||
addRoutes: RouteRecordRaw[]
|
||||
}
|
||||
|
||||
/**
|
||||
* 设置状态类型声明
|
||||
*/
|
||||
export interface SettingState {
|
||||
theme: string,
|
||||
tagsView: boolean,
|
||||
fixedHeader: boolean,
|
||||
showSettings: boolean,
|
||||
sidebarLogo: boolean
|
||||
}
|
||||
|
||||
/**
|
||||
* 标签状态类型声明
|
||||
*/
|
||||
export interface TagView extends Partial<RouteLocationNormalized> {
|
||||
title?: string
|
||||
}
|
||||
|
||||
export interface TagsViewState{
|
||||
visitedViews: TagView[],
|
||||
cachedViews: (string)[]
|
||||
}
|
||||
|
||||
/**
|
||||
* 用户状态类型声明
|
||||
*/
|
||||
export interface UserState {
|
||||
token: string,
|
||||
nickname: string,
|
||||
avatar: string,
|
||||
roles: string[],
|
||||
perms: string[]
|
||||
}
|
||||
12
src/types/store/app.d.ts
vendored
12
src/types/store/app.d.ts
vendored
@@ -1,12 +0,0 @@
|
||||
/**
|
||||
* 用户状态类型声明
|
||||
*/
|
||||
export interface AppState {
|
||||
device: string,
|
||||
sidebar: {
|
||||
opened: boolean,
|
||||
withoutAnimation: boolean
|
||||
},
|
||||
language:string,
|
||||
size:string
|
||||
}
|
||||
9
src/types/store/permission.d.ts
vendored
9
src/types/store/permission.d.ts
vendored
@@ -1,9 +0,0 @@
|
||||
import {RouteRecordRaw} from "vue-router";
|
||||
|
||||
/**
|
||||
* 权限类型声明
|
||||
*/
|
||||
export interface PermissionState{
|
||||
routes:RouteRecordRaw[]
|
||||
addRoutes: RouteRecordRaw[]
|
||||
}
|
||||
10
src/types/store/setting.d.ts
vendored
10
src/types/store/setting.d.ts
vendored
@@ -1,10 +0,0 @@
|
||||
/**
|
||||
* 设置状态类型声明
|
||||
*/
|
||||
export interface SettingState {
|
||||
theme: string,
|
||||
tagsView: boolean,
|
||||
fixedHeader: boolean,
|
||||
showSettings: boolean,
|
||||
sidebarLogo: boolean
|
||||
}
|
||||
12
src/types/store/tagsView.d.ts
vendored
12
src/types/store/tagsView.d.ts
vendored
@@ -1,12 +0,0 @@
|
||||
import {RouteLocationNormalized} from "vue-router";
|
||||
/**
|
||||
* 用户状态类型声明
|
||||
*/
|
||||
export interface TagView extends Partial<RouteLocationNormalized> {
|
||||
title?: string
|
||||
}
|
||||
|
||||
export interface TagsViewState{
|
||||
visitedViews: TagView[],
|
||||
cachedViews: (string)[]
|
||||
}
|
||||
10
src/types/store/user.d.ts
vendored
10
src/types/store/user.d.ts
vendored
@@ -1,10 +0,0 @@
|
||||
/**
|
||||
* 用户状态类型声明
|
||||
*/
|
||||
export interface UserState {
|
||||
token: string,
|
||||
nickname: string,
|
||||
avatar: string,
|
||||
roles: string[],
|
||||
perms: string[]
|
||||
}
|
||||
@@ -80,20 +80,20 @@ const state = reactive({
|
||||
{
|
||||
imgUrl: 'http://cdn.youlai.tech/rui.jpg',
|
||||
nickname: '郝先瑞',
|
||||
positions: ['后端', '前端', '打杂'],
|
||||
positions: ['Vue3','Java', '文档'],
|
||||
homepage: 'https://www.cnblogs.com/haoxianrui/'
|
||||
},
|
||||
{
|
||||
imgUrl: 'http://cdn.youlai.tech/lin.jpg',
|
||||
nickname: '张加林',
|
||||
positions: ['DevOps'],
|
||||
homepage: 'https://gitee.com/ximy'
|
||||
},
|
||||
{
|
||||
imgUrl: 'http://cdn.youlai.tech/chuan.jpg',
|
||||
nickname: '张川',
|
||||
positions: ['后端', '前端'],
|
||||
positions: ['Vue3','Java' ],
|
||||
homepage: 'https://blog.csdn.net/qq_41595149'
|
||||
},
|
||||
{
|
||||
imgUrl: 'http://cdn.youlai.tech/lin.jpg',
|
||||
nickname: '张加林',
|
||||
positions: ['DevOps'],
|
||||
homepage: 'https://gitee.com/ximy'
|
||||
}
|
||||
],
|
||||
colors: ['', 'success', 'warning', 'danger'],
|
||||
|
||||
Reference in New Issue
Block a user