Authored by 王水玲

node 星潮教室 二期

... ... @@ -34,7 +34,7 @@ const renderData = {
module: 'guang',
title: '新潮教室',
pageHeader: headerData
}
};
const curHeadTab = (num) => {
let i = 0;
... ... @@ -95,7 +95,7 @@ exports.collocation = (req, res) => {
res.render('star/collocation', _.assign(renderData, {
headTab: headTab
}));
}
};
/**
* 星搭配文章请求
... ... @@ -114,5 +114,5 @@ exports.collocationList = (req, res) => {
collocationList: result
}));
});
}
};
... ...
... ... @@ -40,14 +40,14 @@ const getResources = (page) => {
*/
exports.getIndexData = () => {
return getResources('index');
}
};
/**
* 星专题
*/
exports.getSpecialData = () => {
return getResources('special');
}
};
/**
* 星搭配
... ... @@ -59,12 +59,12 @@ exports.getCollocationListData = (params, uid) => {
uid: uid
}, params))).then((result) => {
if (result && result.code === 200) {
return res;
return result;
} else {
logger.error('获取星搭配文章列表返回 code 不是 200');
return [];
}
});
}
};
// guang/api/v5/article/getStarClassroomArticleList
\ No newline at end of file
// guang/api/v5/article/getStarClassroomArticleList
... ...
... ... @@ -8,16 +8,16 @@ var $ = require('yoho-jquery'),
tip = require('../plugin/tip'),
loading = require('../plugin/loading'),
lazyLoad = require('yoho-jquery-lazyload'),
ellipsis = require('yoho-mlellipsis'),
stopLoading = false;
ellipsis = require('yoho-mlellipsis');
var page = 1;
var stopLoading = false,
page = 1;
ellipsis.init();
$('body').addClass('star-class-body');
function massageAJAX(page) {
function massageAJAX(pageData) {
var $this, $title, $cont;
loading.showLoadingMask();
... ... @@ -25,7 +25,7 @@ function massageAJAX(page) {
type: 'GET',
url: '/guang/star/collocation/list',
data: {
page: page
page: pageData
},
dataType: 'html',
success: function(data) {
... ...
... ... @@ -84,7 +84,7 @@
}
.collected {
color: #D62927;
color: #d62927;
}
.forward {
... ... @@ -104,6 +104,6 @@
.star-class-body {
background: #333;
width: 100%;
font: 12px/1.5 Arial,'黑体';
font: 12px/1.5 Arial, '黑体';
float: left;
}
\ No newline at end of file
}
... ...
... ... @@ -32,5 +32,3 @@
}
}
}
... ...