Commit 3307c669 authored by Xuguangxing's avatar Xuguangxing

feat: 处理导航页面无法返回个人中心的问题

parent 240641a7
...@@ -312,7 +312,6 @@ export default class Activity extends Mixins(TransformStyleMixin, BottomNavStyle ...@@ -312,7 +312,6 @@ export default class Activity extends Mixins(TransformStyleMixin, BottomNavStyle
newUrl: home.app, newUrl: home.app,
}, },
}); });
nativeBridge = null;
} else if (isWxMp) { } else if (isWxMp) {
mpBridge = new MpBridge(); mpBridge = new MpBridge();
const jumpConfig = { const jumpConfig = {
...@@ -321,7 +320,6 @@ export default class Activity extends Mixins(TransformStyleMixin, BottomNavStyle ...@@ -321,7 +320,6 @@ export default class Activity extends Mixins(TransformStyleMixin, BottomNavStyle
type: 'switchTab' type: 'switchTab'
}; };
mpBridge.openNewUrl(jumpConfig); mpBridge.openNewUrl(jumpConfig);
mpBridge = null;
} else { } else {
let url = home.h5; let url = home.h5;
if (vccChannel) { url = this.addOrEditUrlParams(url, 'vccChannel', vccChannel); } if (vccChannel) { url = this.addOrEditUrlParams(url, 'vccChannel', vccChannel); }
...@@ -338,7 +336,6 @@ export default class Activity extends Mixins(TransformStyleMixin, BottomNavStyle ...@@ -338,7 +336,6 @@ export default class Activity extends Mixins(TransformStyleMixin, BottomNavStyle
newUrl: shopcart.app, newUrl: shopcart.app,
}, },
}); });
nativeBridge = null;
} else if (isWxMp) { } else if (isWxMp) {
mpBridge = new MpBridge(); mpBridge = new MpBridge();
const jumpConfig = { const jumpConfig = {
...@@ -347,7 +344,6 @@ export default class Activity extends Mixins(TransformStyleMixin, BottomNavStyle ...@@ -347,7 +344,6 @@ export default class Activity extends Mixins(TransformStyleMixin, BottomNavStyle
type: 'switchTab' type: 'switchTab'
}; };
mpBridge.openNewUrl(jumpConfig); mpBridge.openNewUrl(jumpConfig);
mpBridge = null;
} else { } else {
let url = shopcart.h5; let url = shopcart.h5;
if (vccChannel) { url = this.addOrEditUrlParams(url, 'vccChannel', vccChannel); } if (vccChannel) { url = this.addOrEditUrlParams(url, 'vccChannel', vccChannel); }
...@@ -364,7 +360,6 @@ export default class Activity extends Mixins(TransformStyleMixin, BottomNavStyle ...@@ -364,7 +360,6 @@ export default class Activity extends Mixins(TransformStyleMixin, BottomNavStyle
newUrl: user.app, newUrl: user.app,
}, },
}); });
nativeBridge = null;
} else if (isWxMp) { } else if (isWxMp) {
mpBridge = new MpBridge(); mpBridge = new MpBridge();
const jumpConfig = { const jumpConfig = {
...@@ -373,7 +368,6 @@ export default class Activity extends Mixins(TransformStyleMixin, BottomNavStyle ...@@ -373,7 +368,6 @@ export default class Activity extends Mixins(TransformStyleMixin, BottomNavStyle
type: 'switchTab' type: 'switchTab'
}; };
mpBridge.openNewUrl(jumpConfig); mpBridge.openNewUrl(jumpConfig);
mpBridge = null;
} else { } else {
let url = user.h5; let url = user.h5;
if (vccChannel) { url = this.addOrEditUrlParams(url, 'vccChannel', vccChannel); } if (vccChannel) { url = this.addOrEditUrlParams(url, 'vccChannel', vccChannel); }
...@@ -384,22 +378,24 @@ export default class Activity extends Mixins(TransformStyleMixin, BottomNavStyle ...@@ -384,22 +378,24 @@ export default class Activity extends Mixins(TransformStyleMixin, BottomNavStyle
return; return;
} else { } else {
if (isApp) { if (isApp) {
nativeBridge = new Bridge(); // nativeBridge = new Bridge();
nativeBridge.openNewUrl({ // nativeBridge.openNewUrl({
data: { // data: {
// 需要打开的新链接 // // 需要打开的新链接
newUrl: `xyqb://openHttp?jumpUrl=${pageUrl}` // newUrl: `xyqb://openHttp?jumpUrl=${pageUrl}`
}, // },
}); // });
nativeBridge = null; window.location.href = pageUrl;
// nativeBridge = null;
} else if (isWxMp) { } else if (isWxMp) {
mpBridge = new MpBridge(); // mpBridge = new MpBridge();
const jumpConfig = { // const jumpConfig = {
// 需要打开的新链接 // // 需要打开的新链接
newUrl: pageUrl // newUrl: pageUrl
}; // };
mpBridge.openNewUrl(jumpConfig); // mpBridge.openNewUrl(jumpConfig);
mpBridge = null; // mpBridge = null;
window.location.href = pageUrl;
} else { } else {
let url = pageUrl; let url = pageUrl;
if (vccChannel) { url = this.addOrEditUrlParams(url, 'vccChannel', vccChannel); } if (vccChannel) { url = this.addOrEditUrlParams(url, 'vccChannel', vccChannel); }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment