Commit 9209bcc1 authored by 李尚科's avatar 李尚科
parents 476b560d f3c62cfc
Pipeline #8866 passed with stage
in 16 seconds
......@@ -87,24 +87,15 @@ class HotQuestionPutService extends Service {
let filter = {
page: condition.page || 1,
limit: condition.limit || 10,
attributes: ['id', 'question', 'status'],
where: {
user_id: ctx.userId,
},
order: [['created_at', 'desc']]
}
let res = await ctx.realestateModel.HotQuestionPut.list(filter);
let list = [];
if (res.count > 0) {
for (let i in res.rows) {
list[i] = {
id: res.row[i].id,
question: res.row[i].question,
status: res.row[i].status,
}
}
}
let ret = {
results: list,
results: res.rows,
count: list.count
}
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