Merge branch 'auy-dev' into develop

This commit is contained in:
Warunee Tamkoo 2023-11-07 15:05:44 +07:00
commit 915810f13f
5 changed files with 127 additions and 2 deletions

View file

@ -0,0 +1,24 @@
<script setup lang="ts">
const props = defineProps({
data: {
type: Array,
default: null,
},
});
</script>
<template>
<div>
ลาปวย ลาคลอดบตร และลากจสวนต
<ul>
<li>เขยนท</li>
<li>ลาตงแตนท</li>
<li>ลาถงวนท</li>
<li>ลาครงสดทายในประเภทน เมอวนท (Auto)</li>
<li>จำนวนวนทลา (Auto)</li>
</ul>
<p>*หมายเหต (กรณลาปวยและลาก สามารถเลอกใหลาครงวนเช หรอครงวนบายได)
อยดตอไดระหวางลา (อาจดงมาจากทอยจจนโดยอตโนม
แตใหใชงานแกไขได)</p>
</div>
</template>

View file

@ -0,0 +1,27 @@
<script setup lang="ts">
const props = defineProps({
data: {
type: Array,
default: null,
},
});
</script>
<template>
<div>
ลาไปชวยเหลอภรยาทคลอดบตร
<ul>
<li>เขยนท</li>
<li>อภรรยา</li>
<li>นทคลอด</li>
<li>ลาตงแตนท</li>
<li>ลาถงวนท</li>
<li>จำนวนวนทลา (frontend คำนวนให Auto)</li>
<li>อยดตอไดระหวางลา (textarea)</li>
<li>หมายเลขโทรศพท</li>
</ul>
<p>
*หมายเหต อยดตอไดระหวางลา (อาจดงมาจากทอยจจนโดยอตโนม แตใหใชงานแกไขได)
</p>
</div>
</template>

View file

@ -4,6 +4,7 @@
const leave = () => import("@/modules/05_leave/views/Main.vue")
const addAbsence = () => import("@/modules/05_leave/componenst/addAbsence.vue")
const samplePage = () => import("@/modules/05_leave/views/SampleForm.vue")
/* const Checkout = () => import("@/modules/04_checkin/views/Checkout.vue");
*/
@ -26,4 +27,13 @@ export default [
Key: [7],
},
},
{
path: "/leave/sample",
name: "sample-page",
component: samplePage,
meta: {
Auth: true,
Key: [7],
},
},
]

View file

@ -0,0 +1,64 @@
<script setup lang="ts">
import { reactive, ref, watch } from "vue";
import SickForm from "@/modules/05_leave/componenst/Forms/01_SickForm.vue";
import HelpWifeBirthForm from "@/modules/05_leave/componenst/Forms/04_HelpWifeBirthForm.vue";
const type = ref<number>(0);
const typeOption = reactive([
{ id: 0, name: "" },
{ id: 1, name: "ลาป่วย" },
{ id: 2, name: "ลากิจ" },
{ id: 3, name: "ลาคลอด" },
{ id: 4, name: "ลาไปช่วยเหลือภริยาที่คลอดบุตร" },
]);
watch(
() => type.value,
() => {
// save store
console.log("ประเภทการลา===>", type.value);
}
);
</script>
<template>
<div class="col-12 row justify-center">
<div class="col-xs-12 col-sm-12 col-md-11">
<div class="toptitle text-white col-12 row items-center">
<q-btn
icon="mdi-arrow-left"
unelevated
round
dense
flat
color="primary"
class="q-mr-sm"
/>
<div>นใบลา</div>
</div>
<q-card bordered>
<div class="col-12 row q-col-gutter-md q-pa-md">
<div class="col-xs-12 col-sm-12">
<form class="col-12">
<q-select
filled
v-model="type"
:options="typeOption"
label="ประเภทการลา"
option-value="id"
option-label="name"
map-options
emit-value
/>
<SickForm v-if="type == 1 || type == 2 || type == 3" />
<HelpWifeBirthForm v-if="type == 4" />
</form>
</div>
</div>
</q-card>
</div>
</div>
</template>

View file

@ -96,8 +96,8 @@ const doLogout = () => {
dense inline-label class="text-grey-5 tabsHome">
<q-tab class="border-100" name="dashboard" label="หน้าแรก" icon="mdi-view-dashboard-outline"
@click="router.push(`/`)" />
<q-tab class="border-100" name="Checkin" label="ลงเวลางาน" icon="mdi-map-marker-check-outline"
@click="router.push(`/check-in`)" />
<!-- <q-tab class="border-100" name="Checkin" label="ลงเวลางาน" icon="mdi-map-marker-check-outline"
@click="router.push(`/check-in`)" /> -->
<q-tab class="border-100" name="leave" label="การลา" icon="mdi-calendar-blank-outline"
@click="router.push(`/leave`)" />
</q-tabs>