Refactoring code 09_leave
This commit is contained in:
parent
d20fdb0190
commit
94eb31fc26
27 changed files with 289 additions and 577 deletions
|
|
@ -1,21 +1,17 @@
|
|||
<script setup lang="ts">
|
||||
import { ref, watch, reactive } from "vue";
|
||||
import { useQuasar } from "quasar";
|
||||
|
||||
import http from "@/plugins/http";
|
||||
import config from "@/app.config";
|
||||
|
||||
/** importType */
|
||||
import type { dataPost } from "@/modules/09_leave/interface/request/changeRound";
|
||||
|
||||
/** importComponents */
|
||||
import Dialogform from "@/modules/09_leave/components/4_ChangeRound/DialogForm.vue";
|
||||
|
||||
/** importStore */
|
||||
import { useCounterMixin } from "@/stores/mixin";
|
||||
import { useChangeRoundDataStore } from "@/modules/09_leave/stores/ChangeRoundStore";
|
||||
|
||||
import { checkPermission } from "@/utils/permissions";
|
||||
|
||||
import type { dataPost } from "@/modules/09_leave/interface/request/changeRound";
|
||||
|
||||
import Dialogform from "@/modules/09_leave/components/4_ChangeRound/DialogForm.vue";
|
||||
|
||||
/** useStore */
|
||||
const mixin = useCounterMixin();
|
||||
const {
|
||||
|
|
@ -121,13 +117,6 @@ function updatePagination(newPagination: any) {
|
|||
formData.pageSize = newPagination.rowsPerPage;
|
||||
}
|
||||
|
||||
watch(
|
||||
() => formData.pageSize,
|
||||
() => {
|
||||
searchData();
|
||||
}
|
||||
);
|
||||
|
||||
/** Function ค้นหาข้อมูล */
|
||||
function searchData() {
|
||||
if (formData.cardId || formData.firstName || formData.lastName) {
|
||||
|
|
@ -136,6 +125,13 @@ function searchData() {
|
|||
dialogMessageNotify($q, "กรุณากรอกข้อมูลอย่างน้อย 1 ช่อง");
|
||||
}
|
||||
}
|
||||
|
||||
watch(
|
||||
() => formData.pageSize,
|
||||
() => {
|
||||
searchData();
|
||||
}
|
||||
);
|
||||
</script>
|
||||
<template>
|
||||
<div class="toptitle text-dark col-12 row items-center">
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue