salix/modules/shelving/front/main/index.js

30 lines
686 B
JavaScript
Raw Normal View History

2022-05-24 10:50:22 +00:00
import ngModule from '../module';
import ModuleMain from 'salix/components/module-main';
export default class Shelving extends ModuleMain {
constructor($element, $) {
super($element, $);
this.filter = {
include: [
{relation: 'parking'}
],
};
}
exprBuilder(param, value) {
switch (param) {
case 'search':
return {code: {like: `%${value}%`}};
2022-05-24 10:50:22 +00:00
case 'parkingFk':
case 'userFk':
case 'isRecyclable':
return {[param]: value};
}
}
}
ngModule.vnComponent('vnShelving', {
controller: Shelving,
template: require('./index.html')
});