0
0
Fork 0

fire searchbar search on icon click

This commit is contained in:
William Buezas 2024-03-06 08:21:26 -03:00
parent 912d54ea55
commit 800b626c99
1 changed files with 9 additions and 3 deletions

View File

@ -81,8 +81,9 @@ onMounted(() => {
}); });
async function search() { async function search() {
const staticParams = Object.entries(store.userParams) const staticParams = Object.entries(store.userParams).filter(
.filter(([key, value]) => value && (props.staticParams || []).includes(key)); ([key, value]) => value && (props.staticParams || []).includes(key)
);
await arrayData.applyFilter({ await arrayData.applyFilter({
params: { params: {
...Object.fromEntries(staticParams), ...Object.fromEntries(staticParams),
@ -117,7 +118,12 @@ async function search() {
autofocus autofocus
> >
<template #prepend> <template #prepend>
<QIcon name="search" v-if="!quasar.platform.is.mobile" /> <QIcon
v-if="!quasar.platform.is.mobile"
class="cursor-pointer"
name="search"
@click="search"
/>
</template> </template>
<template #append> <template #append>
<QIcon <QIcon