Authored by lijing

邀请记录楼层

... ... @@ -25,9 +25,8 @@ exports.index = (req, res, next) => {
};
let params = {
uid: req.user.uid,
shareUid: req.query.uid,
shareId: 982 // TODO
uid: req.user.uid, // 10851797 8050800 req.user.uid
shareUid: req.query.uid
}
indexModel.index(params).then(result => {
... ...
... ... @@ -16,15 +16,15 @@ const _studentInfo = (params) => {
return api.get('', {
method: 'app.passport.profile',
uid: params.shareUid
},{code: 200});
}, {code: 200});
};
// 判断哪个学校认证的
const _getCollege = (params) => {
return api.get('', {
method: 'app.student.getCollegeByUid',
uid: 8050800
},{code: 200});
uid: params.uid
}, {code: 200});
};
// 获取学生状态
... ... @@ -33,6 +33,7 @@ const _studentState = (params) => {
let resu = {
studentState: {}
};
// 未登录状态
if (!params.uid) {
resu.studentState = {
... ... @@ -53,7 +54,7 @@ const _studentState = (params) => {
return resu;
});
} else {
//已登录,为原链接,验证是否已认证
// 已登录,为原链接,验证是否已认证
return service.all([
_getCollege(params)
]).then(result => {
... ... @@ -91,11 +92,10 @@ const _schoolTotal = () => {
// 获取分享记录
const _shareLog = (params) => {
if (1544) { //TODO
if (params.uid) {
return api.get('', {
method: 'app.student.getShareLog',
shareUid: 1544, //TODO
shareId: 982 //TODO
shareUid: params.uid
});
} else {
let resu = ''
... ...
... ... @@ -251,8 +251,8 @@ $(document).on('click', '.invite-now', function() {
location.href = '//m.yohobuy.com/signin.html?refer=' + location.href;
} else {
if ($('#s-school-tb').val()) {
$(".share-bg").show();
setTimeout(function () {$('.share-bg').hide();}, 3000);
$('.share-bg').show();
setTimeout(function() { $('.share-bg').hide(); }, 3000);
} else {
dialog.showDialog({
dialogText: '要先验证学生身份才可以邀请哦',
... ... @@ -265,15 +265,16 @@ $(document).on('click', '.invite-now', function() {
location.href = './student/register?shareId=' + window.queryString.uid + '&refer=' + location.href;
});
}
$('.dialog-right-btn').css('color', '#3084bb');
}
});
$(
function () {
$(".reg-now").on("click", function () {
function() {
$('.reg-now').on('click', function() {
location.href = './student/register?shareId=' + window.queryString.uid + '&refer=' + location.href;
});
$(".login-btn").on("click", function () {
$('.login-btn').on('click', function() {
location.href = '//m.yohobuy.com/signin.html?refer=' + location.href;
});
... ... @@ -283,19 +284,28 @@ $(
case '200':
tip.show('邀请成功');
setCookie('promotion', '', { path: '/' });
$('.foot-fixed').hide();
break;
case '500':
tip.show('邀请失败');
setCookie('promotion', '', { path: '/' });
break;
default: ;
}
$(".checkMySchool").on("click", function () {
var sTop = $("#university").offset().top;
$('.checkMySchool').on('click', function() {
var sTop = $('#university').offset().top;
$(window).scrollTop(sTop);
});
$(".share-bg").on("click", function () {
$('.share-bg').on('click', function() {
$(this).hide();
})
});
var regSchool = $('#s-school-tb').val();
if (regSchool) {
schoolNum(regSchool);
}
}
);
... ...
... ... @@ -120,9 +120,12 @@
.student {
padding: 0 30px;
max-height: 500px;
overflow-y: scroll;
.student-item {
height: 88px;
width: 690px;
border-bottom: solid 1px #cfcfcf;
&:last-child {
... ... @@ -224,7 +227,7 @@
margin-right: 50px;
overflow: hidden;
display: block;
text-overflow:ellipsis;
text-overflow: ellipsis;
white-space: nowrap;
}
... ...