salix/modules/travel/front/search-panel/index.js

44 lines
908 B
JavaScript
Raw Normal View History

2018-11-13 06:44:03 +00:00
import ngModule from '../module';
2018-12-27 11:54:16 +00:00
import SearchPanel from 'core/components/searchbar/search-panel';
2018-11-13 06:44:03 +00:00
2021-01-29 10:45:35 +00:00
class Controller extends SearchPanel {
constructor($, $element) {
super($, $element);
this.filter = this.$.filter;
}
get shippedFrom() {
return this._shippedFrom;
}
set shippedFrom(value) {
this._shippedFrom = value;
this.filter.scopeDays = null;
}
get shippedTo() {
return this._shippedTo;
}
set shippedTo(value) {
this._shippedTo = value;
this.filter.scopeDays = null;
}
get scopeDays() {
return this._scopeDays;
}
set scopeDays(value) {
this._scopeDays = value;
this.filter.shippedFrom = null;
this.filter.shippedTo = null;
}
}
ngModule.vnComponent('vnTravelSearchPanel', {
2018-11-13 06:44:03 +00:00
template: require('./index.html'),
2021-01-29 10:45:35 +00:00
controller: Controller
2018-11-13 06:44:03 +00:00
});