...
|
...
|
@@ -82,7 +82,7 @@ module.exports = class extends global.yoho.BaseModel { |
|
|
lresult = {
|
|
|
id: articleData.id,
|
|
|
classification: _.get(articleData, 'min_category_name', '') || _.get(articleData, 'category_name', ''),
|
|
|
url: helpers.urlFormat(`/guang/news/${articleData.id}_${articleData.cid}.html`),
|
|
|
url: helpers.urlFormat(`/guang/news/${articleData.id}_${articleData.cid}_${articleData.app}.html`),
|
|
|
img: helpers.image(articleData.image, width, height, 1),
|
|
|
title: articleData.title,
|
|
|
pTime: articleData.update_time && moment(articleData.update_time * 1000).format('YYYY年MM月DD HH:mm'),
|
...
|
...
|
@@ -189,7 +189,7 @@ module.exports = class extends global.yoho.BaseModel { |
|
|
// 潮流详情
|
|
|
getContentDetail(newsAPi, params) {
|
|
|
return redis.all([
|
|
|
['get', `global:yoho:news:detail:${params.id}-${params.cid}`]
|
|
|
['get', `global:yoho:news:detail:${params.id}-${params.cid}-${params.app}`]
|
|
|
]).then(redisData => {
|
|
|
redisData = JSON.parse(redisData[0] || '{}');
|
|
|
if (!redisData.data) {
|
...
|
...
|
@@ -212,7 +212,8 @@ module.exports = class extends global.yoho.BaseModel { |
|
|
detail(channel, param) {
|
|
|
let params = {
|
|
|
id: param.id,
|
|
|
cid: param.cid
|
|
|
cid: param.cid,
|
|
|
app: param.app,
|
|
|
};
|
|
|
let newsAPi = new NewsAPi(this.ctx);
|
|
|
let apiMethod = [
|
...
|
...
|
|