Authored by zhangxiaoru

editorial

... ... @@ -103,7 +103,6 @@ const list = (req, res) => {
const detail = (req, res, next) => {
let id = req.params.id;
console.log(id)
editorialModel.getDetailData(id).then((result) => {
res.display('detail', {
... ...
... ... @@ -20,7 +20,7 @@ module.exports = {
cookieDomain: 'yohobuy.com',
domains: {
api: 'http://devapi.yoho.cn:58078/', // devapi.yoho.cn:58078 testapi.yoho.cn:28078 devapi.yoho.cn:58078
//service: 'http://testservice.yoho.cn:28077/', // testservice.yoho.cn:28077 devservice.yoho.cn:58077
// service: 'http://testservice.yoho.cn:28077/', // testservice.yoho.cn:28077 devservice.yoho.cn:58077
service: 'http://service.yoho.cn/',
search: 'http://192.168.102.216:8080/yohosearch/'
},
... ...
... ... @@ -17,7 +17,7 @@ var $commentList = $commentArea.find('.comments-wrap'),
$commentBtn = $('#comment-btn'),
MAX_COMMENTS_WORDS = 100,
$wordCountTip = $('#word-count-tip'),
tag = $('#tags').find("li").length,
tag = $('#tags').find('li').length,
_alert = dialog.Alert;
require('../plugins/share');
... ... @@ -89,7 +89,7 @@ $('#collect-btn').click(function() {
if (data.code === 200) {
new _alert('收藏成功').show();
}else {
} else {
new _alert(data.message).show();
}
collecting = false;
... ... @@ -135,10 +135,10 @@ function comment() {
// clear comment-text
$('#comment-info').val('').keyup();
}else {
} else {
new _alert(data.message).show();
}
commenting = false;
}
});
... ...
... ... @@ -45,7 +45,7 @@ $('.editorial-index-page').on('click', '.like-icon', function() {
if (data.code === 200) {
$this.toggleClass('liked');
$this.next('b').html(data.data);
}else{
} else {
new _alert(data.message).show();
}
... ...
... ... @@ -31,9 +31,10 @@ $('.editorial-list-page').on('click', '.like-icon', function() {
if (data.code === 200) {
$this.toggleClass('liked');
$this.next('b').html(data.data);
}else {
} else {
new _alert(data.message).show();
}
// prising = false;
});
}).on('mouseenter mouseleave', '.like-icon', function() {
... ...