|
|
@ -7,14 +7,12 @@ |
|
|
|
<div class="d-flex" style="gap: 6px; padding: 0 6px"> |
|
|
|
<div class="d-flex" style="gap: 6px; padding: 0 6px"> |
|
|
|
<v-icon |
|
|
|
<v-icon |
|
|
|
v-if="!filter.readOnly" |
|
|
|
v-if="!filter.readOnly" |
|
|
|
:key="i + '_3'" |
|
|
|
|
|
|
|
small |
|
|
|
small |
|
|
|
class="nc-filter-item-remove-btn" |
|
|
|
class="nc-filter-item-remove-btn" |
|
|
|
@click.stop="deleteFilter(filter, i)" |
|
|
|
@click.stop="deleteFilter(filter, i)" |
|
|
|
> |
|
|
|
> |
|
|
|
mdi-close-box |
|
|
|
mdi-close-box |
|
|
|
</v-icon> |
|
|
|
</v-icon> |
|
|
|
<span v-else :key="i + '_1'" /> |
|
|
|
|
|
|
|
<v-select |
|
|
|
<v-select |
|
|
|
v-model="filter.logical_op" |
|
|
|
v-model="filter.logical_op" |
|
|
|
class="flex-shrink-1 flex-grow-0 elevation-0 caption" |
|
|
|
class="flex-shrink-1 flex-grow-0 elevation-0 caption" |
|
|
@ -50,7 +48,7 @@ |
|
|
|
<template v-else> |
|
|
|
<template v-else> |
|
|
|
<v-icon |
|
|
|
<v-icon |
|
|
|
v-if="!filter.readOnly" |
|
|
|
v-if="!filter.readOnly" |
|
|
|
:key="i + '_3'" |
|
|
|
:key="i + '_1'" |
|
|
|
small |
|
|
|
small |
|
|
|
class="nc-filter-item-remove-btn" |
|
|
|
class="nc-filter-item-remove-btn" |
|
|
|
@click.stop="deleteFilter(filter, i)" |
|
|
|
@click.stop="deleteFilter(filter, i)" |
|
|
@ -62,7 +60,7 @@ |
|
|
|
|
|
|
|
|
|
|
|
<v-select |
|
|
|
<v-select |
|
|
|
v-else |
|
|
|
v-else |
|
|
|
:key="i + '_4'" |
|
|
|
:key="i + '_2'" |
|
|
|
v-model="filter.logical_op" |
|
|
|
v-model="filter.logical_op" |
|
|
|
class="flex-shrink-1 flex-grow-0 elevation-0 caption" |
|
|
|
class="flex-shrink-1 flex-grow-0 elevation-0 caption" |
|
|
|
:items="['and', 'or']" |
|
|
|
:items="['and', 'or']" |
|
|
@ -80,7 +78,7 @@ |
|
|
|
</v-select> |
|
|
|
</v-select> |
|
|
|
|
|
|
|
|
|
|
|
<field-list-auto-complete-dropdown |
|
|
|
<field-list-auto-complete-dropdown |
|
|
|
:key="i + '_6'" |
|
|
|
:key="i + '_3'" |
|
|
|
v-model="filter.fk_column_id" |
|
|
|
v-model="filter.fk_column_id" |
|
|
|
class="caption nc-filter-field-select" |
|
|
|
class="caption nc-filter-field-select" |
|
|
|
:columns="columns" |
|
|
|
:columns="columns" |
|
|
@ -90,7 +88,7 @@ |
|
|
|
/> |
|
|
|
/> |
|
|
|
|
|
|
|
|
|
|
|
<v-select |
|
|
|
<v-select |
|
|
|
:key="'k' + i" |
|
|
|
:key="i + '_4'" |
|
|
|
v-model="filter.comparison_op" |
|
|
|
v-model="filter.comparison_op" |
|
|
|
class="flex-shrink-1 flex-grow-0 caption nc-filter-operation-select" |
|
|
|
class="flex-shrink-1 flex-grow-0 caption nc-filter-operation-select" |
|
|
|
:items="filterComparisonOp(filter)" |
|
|
|
:items="filterComparisonOp(filter)" |
|
|
@ -110,11 +108,11 @@ |
|
|
|
<span class="caption font-weight-regular">{{ item.text }}</span> |
|
|
|
<span class="caption font-weight-regular">{{ item.text }}</span> |
|
|
|
</template> |
|
|
|
</template> |
|
|
|
</v-select> |
|
|
|
</v-select> |
|
|
|
<span v-else :key="'span1' + i"></span> |
|
|
|
<span v-else :key="i + '_4'"></span> |
|
|
|
<span v-if="['null', 'notnull', 'empty', 'notempty'].includes(filter.comparison_op)" :key="'span2' + i" /> |
|
|
|
<span v-if="['null', 'notnull', 'empty', 'notempty'].includes(filter.comparison_op)" :key="i + '_5'" /> |
|
|
|
<v-checkbox |
|
|
|
<v-checkbox |
|
|
|
v-else-if="types[filter.field] === 'boolean'" |
|
|
|
v-else-if="types[filter.field] === 'boolean'" |
|
|
|
:key="i + '_7'" |
|
|
|
:key="i + '_5'" |
|
|
|
v-model="filter.value" |
|
|
|
v-model="filter.value" |
|
|
|
dense |
|
|
|
dense |
|
|
|
:disabled="filter.readOnly" |
|
|
|
:disabled="filter.readOnly" |
|
|
@ -122,7 +120,7 @@ |
|
|
|
/> |
|
|
|
/> |
|
|
|
<v-text-field |
|
|
|
<v-text-field |
|
|
|
v-else-if="filter && filter.fk_column_id" |
|
|
|
v-else-if="filter && filter.fk_column_id" |
|
|
|
:key="i + '_7'" |
|
|
|
:key="i + '_5'" |
|
|
|
v-model="filter.value" |
|
|
|
v-model="filter.value" |
|
|
|
solo |
|
|
|
solo |
|
|
|
flat |
|
|
|
flat |
|
|
@ -133,7 +131,7 @@ |
|
|
|
@click.stop |
|
|
|
@click.stop |
|
|
|
@input="saveOrUpdate(filter, i)" |
|
|
|
@input="saveOrUpdate(filter, i)" |
|
|
|
/> |
|
|
|
/> |
|
|
|
<span v-else :key="'span1' + i"></span> |
|
|
|
<span v-else :key="i + '_5'"></span> |
|
|
|
</template> |
|
|
|
</template> |
|
|
|
</template> |
|
|
|
</template> |
|
|
|
</template> |
|
|
|
</template> |
|
|
|