Skip to content

Commit

Permalink
Fix: Invalid brackets not shown in filters if only 1 line
Browse files Browse the repository at this point in the history
  • Loading branch information
r3-gabriel committed Oct 11, 2024
1 parent a82b453 commit f80a54c
Showing 1 changed file with 7 additions and 6 deletions.
13 changes: 7 additions & 6 deletions www/comps/filters.js
Original file line number Diff line number Diff line change
Expand Up @@ -742,7 +742,7 @@ let MyFilter = {
:readonly="position === 0"
/>
<my-filter-brackets class="brackets"
v-if="multipleFilters"
v-if="multipleFilters || isAnyBracketsSet"
v-model="brackets0Input"
:left="true"
/>
Expand Down Expand Up @@ -807,7 +807,7 @@ let MyFilter = {
</select>
<my-filter-brackets class="brackets"
v-if="multipleFilters"
v-if="multipleFilters || isAnyBracketsSet"
v-model="brackets1Input"
:left="false"
/>
Expand Down Expand Up @@ -928,10 +928,11 @@ let MyFilter = {
}
return null;
},
side0ColumDate:(s) => s.side0Column && ['date','datetime'].includes(s.attributeIdMap[s.side0Column.attributeId].contentUse),
side0ColumTime:(s) => s.side0Column && ['datetime','time'].includes(s.attributeIdMap[s.side0Column.attributeId].contentUse),
isNullOperator:(s) => ['IS NULL','IS NOT NULL'].includes(s.operator),
isStringInput: (s) => (
side0ColumDate: (s) => s.side0Column && ['date','datetime'].includes(s.attributeIdMap[s.side0Column.attributeId].contentUse),
side0ColumTime: (s) => s.side0Column && ['datetime','time'].includes(s.attributeIdMap[s.side0Column.attributeId].contentUse),
isAnyBracketsSet:(s) => s.brackets0Input !== 0 || s.brackets1Input !== 0,
isNullOperator: (s) => ['IS NULL','IS NOT NULL'].includes(s.operator),
isStringInput: (s) => (
typeof s.side0.attributeId !== 'undefined' &&
s.side0.attributeId !== null &&
s.isAttributeString(s.attributeIdMap[s.side0.attributeId].content)
Expand Down

0 comments on commit f80a54c

Please sign in to comment.