Make discussion list includes extensible

This commit is contained in:
Toby Zerner 2015-05-14 23:10:11 +09:30
parent fe81f71d73
commit 2820b76c9b

View File

@ -25,7 +25,7 @@ export default class DiscussionList extends Component {
}
params() {
var params = {};
var params = {include: ['startUser', 'lastUser']};
for (var i in this.props.params) {
params[i] = this.props.params[i];
}
@ -65,6 +65,7 @@ export default class DiscussionList extends Component {
loadResults(offset) {
var params = this.params();
params.page = {offset};
params.include = params.include.join(',');
return app.store.find('discussions', params);
}