1 <div ng-cloak layout="row" class="quick-filter-container" flex>
3 ng-repeat="filter in vm.filters"
4 ng-if="filter.ngIf ? $eval('vm.query.' + filter.ngIf) : true"
6 class="padding-horizontal-16"
8 <span class="font-size-10" translate="{{ filter.label }}" />
10 ng-if="filter.type === 'select'"
11 class="font-size-12 no-margin"
12 ng-model="vm.query[filter.key]"
13 ng-change="vm.search()"
14 aria-label="Filter {{ filter.name }}"
17 ng-repeat="option in filter.options"
18 ng-value="filter.ngValue ? option[filter.ngValue] : option.id"
19 >{{ option.name }}</md-option
22 ng-repeat="option in filter.customOptions"
23 ng-value="option.value"
24 translate="{{ option.translate }}"
29 ng-if="filter.type === 'multiselect'"
31 class="font-size-12 no-margin"
32 ng-init="vm.onMultiselectInit(filter)"
33 ng-model="vm.query[filter.key]"
34 ng-disabled="filter.options.length === 0"
35 ng-change="vm.onMultiselectSelection(filter)"
36 md-selected-text="vm.placeholders[filter.key]"
37 aria-label="Filter {{ filter.name }}"
40 ng-repeat="option in filter.options"
41 ng-value="filter.ngValue ? option[filter.ngValue] : option.id"
42 ng-disabled="filter.clearAll === false && vm.query[filter.key].length === 1 && vm.query[filter.key][0] === (filter.ngValue ? option[filter.ngValue] : option.id)"
44 {{ option.name }}</md-option
47 ng-if="vm.query[filter.key].length < filter.options.length"
48 ng-click="vm.selectAll(filter)"
53 {{'DASHBOARDS.SELECT_ALL' | translate}}</md-button
56 ng-if="vm.query[filter.key].length === filter.options.length"
57 ng-click="vm.clearSelection(filter)"
62 {{'DASHBOARDS.CLEAR' | translate}}</md-button
67 ng-if="filter.type === 'date'"
69 layout-align="center center"
72 ng-init="vm.onDateRangeInit(filter)"
73 localization-map="vm.localizationMap"
74 ng-model="vm.pickerModels[filter.key]"
77 md-on-select="vm.onDateRangeSelection(filter)"
78 placeholder="{{ 'DASHBOARDS.ALL' | translate }}"
82 ng-if="vm.pickerModels[filter.key].dateStart"
83 ng-click="vm.clearDate(filter)"
84 class="md-icon-button no-margin no-padding width-20 height-20"
87 md-font-icon="icon-close"
88 class="quick-filter-date-clear-button s16"