szurubooru/client/js/controllers/post_upload_controller.js
rr- 54e3099c56 client/general: refactor control flow
- Controller lifetime is bound to route lifetime
- View lifetime is bound to controller lifetime
- Control lifetime is bound to view lifetime
- Enhanced event dispatching
- Enhanced responsiveness in some places
- Views communicate user input to controllers via new event system
2016-06-18 10:35:20 +02:00

17 lines
412 B
JavaScript

'use strict';
const topNavigation = require('../models/top_navigation.js');
const EmptyView = require('../views/empty_view.js');
class PostUploadController {
constructor() {
topNavigation.activate('upload');
this._emptyView = new EmptyView();
}
}
module.exports = router => {
router.enter('/upload', (ctx, next) => {
ctx.controller = new PostUploadController();
});
};