clear year sent 0
This commit is contained in:
parent
0441c29426
commit
acc3f1e2c7
2 changed files with 22 additions and 13 deletions
|
|
@ -521,7 +521,6 @@ onMounted(async () => {
|
|||
</div>
|
||||
<div class="col-4">
|
||||
<q-input
|
||||
:class="getClass(edit)"
|
||||
:outlined="edit"
|
||||
dense
|
||||
readonly
|
||||
|
|
@ -533,7 +532,6 @@ onMounted(async () => {
|
|||
</div>
|
||||
<div class="col-12">
|
||||
<q-input
|
||||
:class="getClass(edit)"
|
||||
:outlined="edit"
|
||||
dense
|
||||
lazy-rules
|
||||
|
|
|
|||
|
|
@ -162,7 +162,7 @@ watch(
|
|||
() => currentPage.value,
|
||||
() => {
|
||||
rowsPerPage.value = pagination.value.rowsPerPage;
|
||||
getData()
|
||||
getData();
|
||||
}
|
||||
);
|
||||
|
||||
|
|
@ -171,7 +171,7 @@ watch(
|
|||
() => {
|
||||
rowsPerPage.value = pagination.value.rowsPerPage;
|
||||
currentPage.value = 1;
|
||||
getData()
|
||||
getData();
|
||||
}
|
||||
);
|
||||
|
||||
|
|
@ -201,7 +201,7 @@ watch(
|
|||
|
||||
/** ไปยังหน้าเพิ่มข้อมูล */
|
||||
function redirectToPageadd() {
|
||||
dataStore.rowsAdd = []
|
||||
dataStore.rowsAdd = [];
|
||||
router.push(`/discipline-appealcomplain/add`);
|
||||
}
|
||||
|
||||
|
|
@ -209,7 +209,7 @@ function editPage(id: string) {
|
|||
router.push(`/discipline-appealcomplain/${id}`);
|
||||
}
|
||||
function filterFn() {
|
||||
getData()
|
||||
getData();
|
||||
console.log("enter", filterKeyword.value);
|
||||
}
|
||||
|
||||
|
|
@ -245,7 +245,7 @@ function getData() {
|
|||
)
|
||||
.then((res) => {
|
||||
maxPage.value = Math.ceil(res.data.result.total / rowsPerPage.value);
|
||||
fetchAppealComplain(res.data.result.data)
|
||||
fetchAppealComplain(res.data.result.data);
|
||||
})
|
||||
.catch((e) => {
|
||||
messageError($q, e);
|
||||
|
|
@ -255,17 +255,20 @@ function getData() {
|
|||
});
|
||||
}
|
||||
|
||||
function dataUpdate(){
|
||||
getData()
|
||||
function dataUpdate() {
|
||||
getData();
|
||||
}
|
||||
|
||||
function yearAll() {
|
||||
formData.year = 0;
|
||||
getData();
|
||||
}
|
||||
/** เรียกใช้งาน ฟังชั่น ตอนเริ่มโหลดหน้า */
|
||||
onMounted(async () => {
|
||||
getData()
|
||||
getData();
|
||||
// await getList();
|
||||
dataStore.visibleColumns = visibleColumns.value;
|
||||
dataStore.columns = columns.value;
|
||||
|
||||
});
|
||||
</script>
|
||||
|
||||
|
|
@ -310,10 +313,18 @@ onMounted(async () => {
|
|||
dense
|
||||
lazy-rules
|
||||
outlined
|
||||
:model-value="Number(formData.year) + 543"
|
||||
:model-value="
|
||||
formData.year === 0 ? null : Number(formData.year) + 543
|
||||
"
|
||||
:label="`${'ปีงบประมาณ'}`"
|
||||
|
||||
>
|
||||
<template v-if="formData.year" v-slot:append>
|
||||
<q-icon
|
||||
name="cancel"
|
||||
@click.stop.prevent="yearAll"
|
||||
class="cursor-pointer"
|
||||
/>
|
||||
</template>
|
||||
<template v-slot:prepend>
|
||||
<q-icon
|
||||
name="event"
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue