Authored by 李犇

个人中心点击跳转增加登陆判断,并在登陆成功后,直接跳转到目标页面——review by 陈林

... ... @@ -154,9 +154,9 @@ class MineContainer extends Component {
NativeModules.YH_CommonHelper.logEvent('YB_MY_STU_IDENTIFY', params);
break;
case 'mineLogin':
//登陆,直接return了,不需要再去调用跳转规则
ReactNative.NativeModules.YH_CommonHelper.login();
//登陆
break;
return;
case 'mineFavProduct':
url = `http://m.yohobuy.com?openby:yohobuy={"action":"go.fav","params":{}}`;
NativeModules.YH_CommonHelper.logEvent('YB_MY_FAVPRD', {});
... ... @@ -261,7 +261,25 @@ class MineContainer extends Component {
default:
break;
}
ReactNative.NativeModules.YH_CommonHelper.jumpWithUrl(url);
// 去设置界面不需要判断登陆
if (viewId === 'mineSetting') {
ReactNative.NativeModules.YH_CommonHelper.jumpWithUrl(url);
}
else {
ReactNative.NativeModules.YH_CommonHelper.uid()
.then(data => {
ReactNative.NativeModules.YH_CommonHelper.jumpWithUrl(url);
})
.catch(error => {
ReactNative.NativeModules.YH_CommonHelper.login()
.then(uid => {
ReactNative.NativeModules.YH_CommonHelper.jumpWithUrl(url);
})
.catch(error => {
});
});
}
}
_onPressProductListProduct(product, rowId = 0) {
... ...