diff --git a/src/config/route.ts b/src/config/route.ts index 3475024..e1e6312 100644 --- a/src/config/route.ts +++ b/src/config/route.ts @@ -7,7 +7,7 @@ interface RouteSettings { */ async: boolean /** 当动态路由功能关闭时: - * 1. 应该将所有路由都写到常驻路由里面(表明所有登陆的用户能访问的页面都是一样的) + * 1. 应该将所有路由都写到常驻路由里面(表明所有登录的用户能访问的页面都是一样的) * 2. 系统自动给当前登录用户赋值一个没有任何作用的默认角色 */ defaultRoles: Array<string> diff --git a/src/store/modules/user.ts b/src/store/modules/user.ts index 90cfe12..634cfd9 100644 --- a/src/store/modules/user.ts +++ b/src/store/modules/user.ts @@ -35,7 +35,7 @@ export const useUserStore = defineStore("user", () => { const newToken = "token-" + role token.value = newToken setToken(newToken) - // 用刷新页面代替重新登陆 + // 用刷新页面代替重新登录 window.location.reload() } /** 登出 */ diff --git a/src/views/permission/components/SwitchRoles.vue b/src/views/permission/components/SwitchRoles.vue index 7f25d00..dc48832 100644 --- a/src/views/permission/components/SwitchRoles.vue +++ b/src/views/permission/components/SwitchRoles.vue @@ -13,7 +13,7 @@ watch(switchRoles, (value) => { <div> <div>你的权限:{{ userStore.roles }}</div> <div class="switch-roles"> - <span>切换权限(模拟权限变化后重新登陆):</span> + <span>切换权限(模拟权限变化后重新登录):</span> <el-radio-group v-model="switchRoles"> <el-radio-button label="editor" /> <el-radio-button label="admin" />