fix:add keyword filter
This commit is contained in:
parent
8d9059ad32
commit
7be8cd2446
3 changed files with 15 additions and 6 deletions
|
|
@ -75,8 +75,13 @@ function updatePagination(newPagination: any) {
|
|||
}
|
||||
}
|
||||
|
||||
function getList() {
|
||||
props.fetchData?.();
|
||||
function getList(enter?: any) {
|
||||
if (enter) {
|
||||
pagination.value.page = 1;
|
||||
props.fetchData?.();
|
||||
} else {
|
||||
props.fetchData?.();
|
||||
}
|
||||
}
|
||||
|
||||
watch(
|
||||
|
|
@ -187,7 +192,9 @@ watch(
|
|||
outlined
|
||||
placeholder="ค้นหา"
|
||||
style="max-width: 200px"
|
||||
@keydown.enter.prevent="props.onSearch?.()"
|
||||
@keydown.enter.prevent="
|
||||
nornmalData ? props.onSearch?.() : getList(true)
|
||||
"
|
||||
>
|
||||
<template v-slot:append>
|
||||
<q-icon name="search" />
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue