Refactoring code module 11_discipline

This commit is contained in:
STW_TTTY\stwtt 2024-09-19 16:37:16 +07:00
parent 202fbf27b6
commit 9653ae78cb
58 changed files with 1021 additions and 1305 deletions

View file

@ -1,19 +1,20 @@
<script setup lang="ts">
import { ref, watch, type PropType } from "vue";
import { useQuasar } from "quasar";
import moment from "moment";
import { useCounterMixin } from "@/stores/mixin";
import type { CalendarOptions } from "@fullcalendar/core";
import type { DataDateMonthObject } from "@/modules/09_leave/interface/response/leave";
import type { ExtendHistoryObject } from "@/modules/11_discipline/interface/response/Main";
import FullCalendar from "@fullcalendar/vue3";
import dayGridPlugin from "@fullcalendar/daygrid";
import timeGridPlugin from "@fullcalendar/timegrid";
import interactionPlugin from "@fullcalendar/interaction";
import allLocales from "@fullcalendar/core/locales-all";
import listPlugin from "@fullcalendar/list";
import moment from "moment";
import type { CalendarOptions } from "@fullcalendar/core";
import type { DataDateMonthObject } from "@/modules/09_leave/interface/response/leave";
import type { ExtendHistoryObject } from "@/modules/11_discipline/interface/response/Main";
import { useCounterMixin } from "@/stores/mixin";
const mixin = useCounterMixin(); //
const { monthYear2Thai, showLoader, hideLoader, messageError, dateToISO } =
@ -36,7 +37,7 @@ const props = defineProps({
default: false,
},
close: {
type: Boolean,
type: Function,
default: true,
},
});
@ -163,7 +164,7 @@ watch(
unelevated
round
dense
@click="props.close"
@click="props.close?.()"
style="color: #ff8080; background-color: #ffdede"
/>
</q-toolbar>