Commit 9254d124 authored by Hsinli's avatar Hsinli

add time

parent 2c544599
Pipeline #8943 passed with stage
in 9 seconds
...@@ -69,7 +69,7 @@ class HotQuestionPutService extends Service { ...@@ -69,7 +69,7 @@ class HotQuestionPutService extends Service {
const { ctx } = this; const { ctx } = this;
//问题内容 //问题内容
let filter = { let filter = {
attributes: ['question'], attributes: ['question', 'created_at'],
where: { where: {
id: Number(condition.id), id: Number(condition.id),
status: "pass" status: "pass"
...@@ -84,7 +84,8 @@ class HotQuestionPutService extends Service { ...@@ -84,7 +84,8 @@ class HotQuestionPutService extends Service {
} }
let answerLsit = await ctx.service.house.v2.hotQuestionAnswer.answerList(answerFliter); let answerLsit = await ctx.service.house.v2.hotQuestionAnswer.answerList(answerFliter);
let ret = { let ret = {
question: question.question, question: question.question || '',
time: question.created_at ? moment().format("YYYY-MM-DD") : '',
answerList: answerLsit answerList: answerLsit
} }
return ret; return ret;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment