mirror of
https://github.com/m-xlsea/ruoyi-plus-soybean.git
synced 2025-09-24 07:49:47 +08:00
refactor(projects): 登录模块由query变更为动态路由params
This commit is contained in:
@ -1,6 +1,6 @@
|
||||
import type { Component } from 'vue';
|
||||
import type { Router, RouteRecordRaw, RouteMeta } from 'vue-router';
|
||||
import type { ImportedRouteModules } from '@/interface';
|
||||
import type { ImportedRouteModules, LoginModuleType } from '@/interface';
|
||||
|
||||
interface SingleRouteConfig {
|
||||
/** 路由 */
|
||||
@ -107,3 +107,9 @@ export function getLoginRedirectUrl(router: Router) {
|
||||
const redirectUrl = path === '/' ? undefined : path;
|
||||
return redirectUrl;
|
||||
}
|
||||
|
||||
/** 获取登录模块的正则字符串 */
|
||||
export function getLoginModuleRegExp() {
|
||||
const modules: LoginModuleType[] = ['pwd-login', 'code-login', 'register', 'reset-pwd', 'bind-wechat'];
|
||||
return modules.join('|');
|
||||
}
|
||||
|
Reference in New Issue
Block a user