Commit 256bc967 by txy

'首页强制关注弹出框'

parent ce57485a
......@@ -115,13 +115,18 @@ var str = '<section id="html-container-attention" style="display: none;">'+
$('body').prepend(str);
// 事件绑定
$("#html-container-attention .modal-close").off("click").on("click", function(){
$("#html-container-attention").hide();
$("#html-container-attention").fadeOut();
});
// 未关注过默认显示弹出框
if (!user.attention){
$("#html-container-attention").show();
$("#html-container-attention").fadeIn();
}
}
// 显示强关弹出框
function showAttentionDialog() {
$("#html-container-attention").fadeIn();
}
appendAttentionDialog();
\ No newline at end of file
......@@ -133,7 +133,36 @@ function btnBindClick() {
// 报名按钮
$("#act31527459124456").off("click").on("click",function(){
var _t = getToken();
transPage('2',activityCode,_t);
// 未关注
if(!user.attention){
// 强关弹出框
showAttentionDialog();
}else {
// 已报名
if(user.reviewStatus !== '') {
switch (user.reviewStatus) {
// 0-待审核
case 0:
alert('您的报名信息正在审核中...');
break;
// 1-审核通过
case 1:
alert('您当前已通过报名,请到个人主页去拉票!');
break;
// 2-审核未通过
case 2:
alert('审核未通过!');
transPage('2',activityCode,_t);
break;
default:
break;
}
} else {
// 未报名
transPage('2',activityCode,_t);
}
}
});
// 继续投票
......@@ -348,6 +377,14 @@ function tabChange(){
// 投票按钮
function voteClickFn(){
// 未关注
if(!user.attention){
// 强关弹出框
showAttentionDialog();
return;
}
var id = $(this).attr('id');
var _this = $(this)
var params = {
......
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