feat(forums): load forums list data

This commit is contained in:
OldHawk
2017-07-05 17:01:59 +08:00
parent ed6b7622d1
commit bceeb4ba5a
8 changed files with 348 additions and 171 deletions

View File

@@ -20,7 +20,8 @@ var path = require('path'),
exports.list = function (req, res) {
Forum.find()
.sort('order -createdat')
.populate('lastTopic')
.populate('lastNewTopic')
.populate('lastReplyTopic')
.populate('moderators', 'username displayName profileImageURL uploaded downloaded')
.exec(function (err, forums) {
if (err) {