Skip to content

Commit

Permalink
fix filtering events
Browse files Browse the repository at this point in the history
  • Loading branch information
rhaamo committed Oct 26, 2022
1 parent 449b67e commit 094c860
Show file tree
Hide file tree
Showing 2 changed files with 20 additions and 8 deletions.
14 changes: 10 additions & 4 deletions front/src/views/parts/List.vue
Original file line number Diff line number Diff line change
Expand Up @@ -216,12 +216,14 @@
</template>
</div>
</template>
<template #filter="{ filterModel }">
<template #filter="{ filterModel, filterCallback }">
<InputText
type="text"
v-model="filterModel.value"
class="p-column-filter"
placeholder="Search by name"
@keydown.enter="filterCallback()"
v-tooltip.top.focus="'Hit enter key to filter'"
/>
</template>
</Column>
Expand All @@ -236,13 +238,14 @@
? slotProps.data.storage.name
: "-"
}}</template>
<template #filter="{ filterModel }">
<template #filter="{ filterModel, filterCallback }">
<TreeSelect
v-model="filterModel.value"
class="p-column-filter"
placeholder="Search by storage"
:options="choicesStorageLocationWithNo"
selectionMode="single"
@change="filterCallback()"
/>
</template>
</Column>
Expand Down Expand Up @@ -300,11 +303,13 @@
</template>
</Inplace>
</template>
<template #filter="{ filterModel }">
<template #filter="{ filterModel, filterCallback }">
<InputNumber
v-model="filterModel.value"
class="p-column-filter"
placeholder="qty"
@keydown.enter="filterCallback()"
v-tooltip.top.focus="'Hit enter key to filter'"
/>
</template>
</Column>
Expand Down Expand Up @@ -374,7 +379,7 @@
}}
</span>
</template>
<template #filter="{ filterModel }">
<template #filter="{ filterModel, filterCallback }">
<Dropdown
v-model="filterModel.value"
class="p-column-filter"
Expand All @@ -385,6 +390,7 @@
optionGroupLabel="category"
optionGroupChildren="footprints"
:filter="true"
@change="filterCallback()"
/>
</template>
</Column>
Expand Down
14 changes: 10 additions & 4 deletions front/src/views/parts/ListPublic.vue
Original file line number Diff line number Diff line change
Expand Up @@ -102,12 +102,14 @@
</template>
</div>
</template>
<template #filter="{ filterModel }">
<template #filter="{ filterModel, filterCallback }">
<InputText
type="text"
v-model="filterModel.value"
class="p-column-filter"
placeholder="Search by name"
@keydown.enter="filterCallback()"
v-tooltip.top.focus="'Hit enter key to filter'"
/>
</template>
</Column>
Expand All @@ -122,13 +124,14 @@
? slotProps.data.storage.name
: "-"
}}</template>
<template #filter="{ filterModel }">
<template #filter="{ filterModel, filterCallback }">
<TreeSelect
v-model="filterModel.value"
class="p-column-filter"
placeholder="Search by storage"
:options="choicesStorageLocationWithNo"
selectionMode="single"
@change="filterCallback()"
/>
</template>
</Column>
Expand Down Expand Up @@ -156,11 +159,13 @@
></span>
</template>
</template>
<template #filter="{ filterModel }">
<template #filter="{ filterModel, filterCallback }">
<InputNumber
v-model="filterModel.value"
class="p-column-filter"
placeholder="qty"
@keydown.enter="filterCallback()"
v-tooltip.top.focus="'Hit enter key to filter'"
/>
</template>
</Column>
Expand Down Expand Up @@ -203,7 +208,7 @@
}}
</span>
</template>
<template #filter="{ filterModel }">
<template #filter="{ filterModel, filterCallback }">
<Dropdown
v-model="filterModel.value"
class="p-column-filter"
Expand All @@ -214,6 +219,7 @@
optionGroupLabel="category"
optionGroupChildren="footprints"
:filter="true"
@change="filterCallback()"
/>
</template>
</Column>
Expand Down

0 comments on commit 094c860

Please sign in to comment.