discourse/app/assets/javascripts/admin/controllers/admin-reports-show.js.es6

21 lines
492 B
Plaintext
Raw Normal View History

import Controller from "@ember/controller";
2018-06-15 11:03:24 -04:00
import computed from "ember-addons/ember-computed-decorators";
export default Controller.extend({
queryParams: ["start_date", "end_date", "filters"],
start_date: null,
end_date: null,
filters: null,
2018-06-15 11:03:24 -04:00
@computed("model.type")
reportOptions(type) {
let options = { table: { perPage: 50, limit: 50, formatNumbers: false } };
if (type === "top_referred_topics") {
options.table.limit = 10;
}
return options;
}
});