...
|
...
|
@@ -250,6 +250,7 @@ exports.index = (req, res, next) => { |
|
|
if (options.isApp) {
|
|
|
options.loginUrl = options.loginUrl + '?openby:yohobuy={"action":"go.h5","params":{"islogin":"N","url":"' + req.__USER__.http + '//m.yohobuy.com/activity/student/register"}}';
|
|
|
}
|
|
|
|
|
|
// if (options.isApp) {
|
|
|
// if (options.isLogin) {
|
|
|
// if (options.isStudent) {
|
...
|
...
|
@@ -295,10 +296,10 @@ exports.register = (req, res, next) => { |
|
|
Promise.all([verifiedStudentTotal(), getEducationLevelList()]).then((arr) => {
|
|
|
if (req.__USER__.isStudent) {
|
|
|
refer = '/activity/student';// 所有认证过的,都跳转学生首页
|
|
|
if(req.__USER__.isApp){
|
|
|
if (req.__USER__.isApp) {
|
|
|
refer = refer + '?openby:yohobuy={"action":"go.h5","params":{"islogin":"N","url":"' + req.__USER__.http + '//m.yohobuy.com/activity/student/register"}}';
|
|
|
}else{
|
|
|
refer = refer + '?uid='+ req.__USER__.uid;
|
|
|
} else {
|
|
|
refer = refer + '?uid=' + req.__USER__.uid;
|
|
|
}
|
|
|
res.redirect(helpers.urlFormat(refer));
|
|
|
} else {
|
...
|
...
|
@@ -419,9 +420,10 @@ exports.isLogin = (req, res, next) => { |
|
|
next();
|
|
|
return;
|
|
|
}
|
|
|
//没有登录
|
|
|
if(yoho.isApp){
|
|
|
if(!yoho.isLogin){
|
|
|
|
|
|
// 没有登录
|
|
|
if (yoho.isApp) {
|
|
|
if (!yoho.isLogin) {
|
|
|
url = url + '?openby:yohobuy={"action":"go.weblogin","params":{"jumpurl":{"url":"' + yoho.http + '//m.yohobuy.com/activity/student/register","antarget":"1"}}}';
|
|
|
res.redirect(url);
|
|
|
}
|
...
|
...
|
|