add flag to redirect user profile

dev_aliyun
p31729568 5 years ago
parent a264ce6ea2
commit a7606d41dd

@ -629,7 +629,7 @@ module ApplicationHelper
end end
=end =end
if !User.current.profile_completed? if !User.current.profile_completed?
redirect_to my_account_path redirect_to my_account_path(need_profile_completed: true)
Rails.logger.info("check_authentication end") Rails.logger.info("check_authentication end")
elsif User.current.certification != 1 # 系统没有授权 elsif User.current.certification != 1 # 系统没有授权
day_cer = UserDayCertification.where(:user_id => User.current.id).last day_cer = UserDayCertification.where(:user_id => User.current.id).last

@ -74,7 +74,7 @@
} }
if (<%= !@user.profile_completed? %>) { if (<%= !@user.profile_completed? %>) {
userProfileModal('/my/account', '您需要去完善您的个人资料,才能使用此功能'); userProfileModal('/my/account?need_profile_completed=true', '您需要去完善您的个人资料,才能使用此功能');
return return
} }

@ -161,7 +161,7 @@
var htmlvalue = '<div class="task-popup" style="width:480px;"><div class="task-popup-title clearfix">提示</div>'+ var htmlvalue = '<div class="task-popup" style="width:480px;"><div class="task-popup-title clearfix">提示</div>'+
'<div class="task-popup-content"><p class="task-popup-text-center font-16">您需要去完善您的个人资料,才能使用此功能</p></div>' + '<div class="task-popup-content"><p class="task-popup-text-center font-16">您需要去完善您的个人资料,才能使用此功能</p></div>' +
'<div class="task-popup-submit clearfix"><a href="javascript:void(0);" onclick="hideModal();" class="task-btn fl">取消</a>'+ '<div class="task-popup-submit clearfix"><a href="javascript:void(0);" onclick="hideModal();" class="task-btn fl">取消</a>'+
'<a href="/my/account" class="task-btn task-btn-orange fr" target="_blank" onclick="hideModal();">立即完善</a></div></div>'; '<a href="/my/account?need_profile_completed=true" class="task-btn task-btn-orange fr" target="_blank" onclick="hideModal();">立即完善</a></div></div>';
pop_box_new(htmlvalue, 480, 205); pop_box_new(htmlvalue, 480, 205);
} }

Loading…
Cancel
Save