mirror of
https://gh.wpcy.net/https://github.com/discourse/discourse.git
synced 2026-05-16 01:40:15 +08:00
This was refactored from an actual Mixin some time back. This PR moves the function to the lib folder and keeps the same logic/interface otherwise. We'll remove the mixin file once all non-core repos change to use the new file.
15 lines
445 B
JavaScript
15 lines
445 B
JavaScript
import { scrollTop } from "discourse/lib/scroll-top";
|
|
import DiscourseRoute from "discourse/routes/discourse";
|
|
import { i18n } from "discourse-i18n";
|
|
|
|
export default class AdminDashboardRoute extends DiscourseRoute {
|
|
titleToken() {
|
|
return i18n("admin.config.dashboard.title");
|
|
}
|
|
|
|
activate() {
|
|
this.controllerFor("admin-dashboard").fetchProblems();
|
|
this.controllerFor("admin-dashboard").fetchDashboard();
|
|
scrollTop();
|
|
}
|
|
}
|