30 lines
848 B
JavaScript
30 lines
848 B
JavaScript
import ngModule from '../module';
|
|
import ModuleCard from 'salix/components/module-card';
|
|
|
|
class Controller extends ModuleCard {
|
|
reload() {
|
|
const filter = {
|
|
include: [
|
|
{relation: 'worker',
|
|
scope: {
|
|
fields: ['id'],
|
|
include: {
|
|
relation: 'user',
|
|
scope: {
|
|
fields: ['nickname']
|
|
}
|
|
}
|
|
}},
|
|
{relation: 'parking'}
|
|
]
|
|
};
|
|
this.$http.get(`Shelvings/${this.$params.id}`, {filter})
|
|
.then(res => this.shelving = res.data);
|
|
}
|
|
}
|
|
|
|
ngModule.vnComponent('vnShelvingCard', {
|
|
template: require('./index.html'),
|
|
controller: Controller
|
|
});
|