Commit e64637d0 by zujiaozhang

'修改分享帖后用户跳转问题'

parent 379889c2
...@@ -67,16 +67,16 @@ define(['zepto', 'medtap','../javaScript/beforeSubmitForLung.js'], function($, m ...@@ -67,16 +67,16 @@ define(['zepto', 'medtap','../javaScript/beforeSubmitForLung.js'], function($, m
// 点击加入社区 // 点击加入社区
$('.join_now').on('click',function(){ $('.join_now').on('click',function(){
if(chat.userId){ if(chat.userId){
window.location.href='https://review-formal.iplusmed.com/wechatForLungCancer/dev/wechat_lung_login/login.html?wechatId=' + card.wechatId window.location.href='https://review-formal.iplusmed.com/wechatForLungCancer/dev/medtap_bbs_lung/index.html?wechatId=' + card.wechatId
}else{ }else{
window.location.href='https://review-formal.iplusmed.com/wechatForLungCancer/dev/wechat_lung_login/login.html?wechatId=' + card.wechatId window.location.href='https://review-formal.iplusmed.com/wechatForLungCancer/dev/wechat_lung_login/login.html?wechatId=' + card.wechatId +'&toBBS=1'
} }
}) })
$('.top_tip_blue').on('click',function(){ $('.top_tip_blue').on('click',function(){
if(chat.userId){ if(chat.userId){
window.location.href='https://review-formal.iplusmed.com/wechatForLungCancer/dev/wechat_lung_login/login.html?wechatId=' + card.wechatId window.location.href='https://review-formal.iplusmed.com/wechatForLungCancer/dev/medtap_bbs_lung/index.html?wechatId=' + card.wechatId
}else{ }else{
window.location.href='https://review-formal.iplusmed.com/wechatForLungCancer/dev/wechat_lung_login/login.html?wechatId=' + card.wechatId window.location.href='https://review-formal.iplusmed.com/wechatForLungCancer/dev/wechat_lung_login/login.html?wechatId=' + card.wechatId +'&toBBS=1'
} }
}) })
}, },
...@@ -133,7 +133,7 @@ define(['zepto', 'medtap','../javaScript/beforeSubmitForLung.js'], function($, m ...@@ -133,7 +133,7 @@ define(['zepto', 'medtap','../javaScript/beforeSubmitForLung.js'], function($, m
}) })
$('.dialog-btn-confirm').on('click',function(){ $('.dialog-btn-confirm').on('click',function(){
$('#showDialog').hide() $('#showDialog').hide()
window.location.href='https://review-formal.iplusmed.com/wechatForLungCancer/dev/wechat_lung_login/login.html?wechatId=' + card.wechatId window.location.href='https://review-formal.iplusmed.com/wechatForLungCancer/dev/wechat_lung_login/login.html?wechatId=' + card.wechatId +'&toBBS=1'
}) })
//为TA加油 //为TA加油
$('.fabulous').on('click', function() { $('.fabulous').on('click', function() {
......
...@@ -44,7 +44,7 @@ define([ 'zepto', 'medtap','mui'], function($, medtap,mui) { ...@@ -44,7 +44,7 @@ define([ 'zepto', 'medtap','mui'], function($, medtap,mui) {
chat.getWechatTicket(); chat.getWechatTicket();
chat.getAttention(); chat.getAttention();
document.querySelector('body').addEventListener('touchmove', function (e) { document.querySelector('body').addEventListener('touchmove', function (e) {
if (!document.querySelector('.chat_list').contains(e.target)) { if (!document.querySelector('#content').contains(e.target)) {
e.preventDefault(); e.preventDefault();
} }
}, {passive: false}); }, {passive: false});
......
...@@ -12,6 +12,7 @@ define(['zepto', 'medtap'], function($, medtapCore) { ...@@ -12,6 +12,7 @@ define(['zepto', 'medtap'], function($, medtapCore) {
businessDetail: medtapCore.getRequest('businessDetail'), businessDetail: medtapCore.getRequest('businessDetail'),
channelId: medtapCore.getRequest('channelId'), channelId: medtapCore.getRequest('channelId'),
toLink: medtapCore.getRequest('toLink'), toLink: medtapCore.getRequest('toLink'),
toBBS: medtapCore.getRequest('toBBS'),
healthType:'', healthType:'',
init: function() { init: function() {
...@@ -83,9 +84,13 @@ define(['zepto', 'medtap'], function($, medtapCore) { ...@@ -83,9 +84,13 @@ define(['zepto', 'medtap'], function($, medtapCore) {
var token = data.content.token; var token = data.content.token;
localStorage.setItem('wxLungToken', token); localStorage.setItem('wxLungToken', token);
if (!login.toLink) { if (!login.toLink) {
if(login.toBBS){
window.location.href='https://review-formal.iplusmed.com/wechatForLungCancer/dev/medtap_bbs_lung/index.html?wechatId=' + login.wechatId
}else{
setTimeout(function() { setTimeout(function() {
self.location = document.referrer; self.location = document.referrer;
}, 1000) }, 1000)
}
} else { } else {
login.getUserInfo(); login.getUserInfo();
} }
......
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