|
@@ -4,12 +4,9 @@ import Vue from 'vue'
|
|
/**
|
|
/**
|
|
* 新旧应用路径拦截,分发
|
|
* 新旧应用路径拦截,分发
|
|
*/
|
|
*/
|
|
-function addChangeOpenRouteType (router, {
|
|
|
|
- appName = '',
|
|
|
|
- qiankunRoutes = []
|
|
|
|
-}) {
|
|
|
|
|
|
+function addChangeOpenRouteType (router, { appName = '', qiankunRoutes = [] }) {
|
|
router.beforeEach(async (to, from, next) => {
|
|
router.beforeEach(async (to, from, next) => {
|
|
- const inQK = qiankunRoutes.some(r => new RegExp(r).test(to?.path))
|
|
|
|
|
|
+ const inQK = qiankunRoutes.some((r) => new RegExp(r).test(to?.path))
|
|
const canNext = to.path !== from.path && from.path !== '/'
|
|
const canNext = to.path !== from.path && from.path !== '/'
|
|
|
|
|
|
const params = {
|
|
const params = {
|
|
@@ -106,11 +103,7 @@ export const subApps = {
|
|
describe: '该应用包含大会员画像、推送、周报月报、个人桌面等功能',
|
|
describe: '该应用包含大会员画像、推送、周报月报、个人桌面等功能',
|
|
qiankun: {
|
|
qiankun: {
|
|
name: 'bigMemberSubApp',
|
|
name: 'bigMemberSubApp',
|
|
-<<<<<<< HEAD
|
|
|
|
- entry: 'http://192.168.40.158:8081/page_big_pc/index.html',
|
|
|
|
-=======
|
|
|
|
entry: '/page_big_pc/index.html',
|
|
entry: '/page_big_pc/index.html',
|
|
->>>>>>> main
|
|
|
|
rule: '/big',
|
|
rule: '/big',
|
|
props: {
|
|
props: {
|
|
inject: ({ Vue, router }) => {
|
|
inject: ({ Vue, router }) => {
|
|
@@ -186,6 +179,6 @@ function registerApps (apps = []) {
|
|
}
|
|
}
|
|
|
|
|
|
export function microAppsStart () {
|
|
export function microAppsStart () {
|
|
- const apps = Object.values(subApps).map(v => v.qiankun)
|
|
|
|
|
|
+ const apps = Object.values(subApps).map((v) => v.qiankun)
|
|
registerApps(apps)
|
|
registerApps(apps)
|
|
}
|
|
}
|