salix/modules/zone/front/card/index.js

22 lines
522 B
JavaScript
Raw Normal View History

2018-12-04 12:18:27 +00:00
import ngModule from '../module';
2019-11-10 10:08:44 +00:00
import ModuleCard from 'salix/components/module-card';
2018-09-19 13:05:07 +00:00
2019-11-10 10:08:44 +00:00
class Controller extends ModuleCard {
reload() {
2018-09-21 10:35:54 +00:00
let filter = {
2019-09-25 18:06:42 +00:00
include: {
relation: 'agencyMode',
scope: {fields: ['name']}
}
2018-09-21 10:35:54 +00:00
};
2018-09-19 13:05:07 +00:00
2019-11-10 10:08:44 +00:00
this.$http.get(`Zones/${this.$params.id}`, {filter})
.then(res => this.zone = res.data);
2018-09-21 10:35:54 +00:00
}
2018-09-19 13:05:07 +00:00
}
2019-11-10 10:08:44 +00:00
ngModule.vnComponent('vnZoneCard', {
2018-09-19 13:05:07 +00:00
template: require('./index.html'),
controller: Controller
});