2019-04-05 13:20:12 +00:00
|
|
|
import ngModule from '../module';
|
|
|
|
import SearchPanel from 'core/components/searchbar/search-panel';
|
|
|
|
|
2020-08-31 06:32:30 +00:00
|
|
|
class Controller extends SearchPanel {
|
|
|
|
constructor($element, $) {
|
|
|
|
super($element, $);
|
|
|
|
|
|
|
|
this.states = [
|
|
|
|
{code: 'pending', name: this.$t('Pending')},
|
|
|
|
{code: 'accepted', name: this.$t('Accepted')},
|
|
|
|
{code: 'denied', name: this.$t('Denied')}
|
|
|
|
];
|
|
|
|
}
|
2021-02-23 15:09:29 +00:00
|
|
|
|
|
|
|
get from() {
|
|
|
|
return this._from;
|
|
|
|
}
|
|
|
|
|
|
|
|
set from(value) {
|
|
|
|
this._from = value;
|
|
|
|
this.filter.scopeDays = null;
|
|
|
|
}
|
|
|
|
|
|
|
|
get to() {
|
|
|
|
return this._to;
|
|
|
|
}
|
|
|
|
|
|
|
|
set to(value) {
|
|
|
|
this._to = value;
|
|
|
|
this.filter.scopeDays = null;
|
|
|
|
}
|
|
|
|
|
|
|
|
get scopeDays() {
|
|
|
|
return this._scopeDays;
|
|
|
|
}
|
|
|
|
|
|
|
|
set scopeDays(value) {
|
|
|
|
this._scopeDays = value;
|
|
|
|
|
|
|
|
this.filter.from = null;
|
|
|
|
this.filter.to = null;
|
|
|
|
}
|
2020-08-31 06:32:30 +00:00
|
|
|
}
|
|
|
|
|
2020-07-24 12:22:30 +00:00
|
|
|
ngModule.vnComponent('vnRequestSearchPanel', {
|
2019-04-05 13:20:12 +00:00
|
|
|
template: require('./index.html'),
|
2020-08-31 06:32:30 +00:00
|
|
|
controller: Controller
|
2019-04-05 13:20:12 +00:00
|
|
|
});
|