import ngModule from '../module'; import ModuleMain from 'salix/components/module-main'; export default class Route extends ModuleMain { constructor($element, $, vnConfig) { super($element, $); this.vnConfig = vnConfig; } $postLink() { let to = new Date(); to.setDate(to.getDate() + 1); to.setHours(0, 0, 0, 0); let from = new Date(); from.setHours(0, 0, 0, 0); this.filter = {from, to, warehouseFk: this.vnConfig.warehouseFk}; } } Route.$inject = ['$element', '$scope', 'vnConfig']; ngModule.vnComponent('vnRoute', { controller: Route, template: require('./index.html') });