Merge branch 'develop' into work

This commit is contained in:
Kittapath 2023-07-25 14:30:49 +07:00
commit af8aa5b334
9 changed files with 536 additions and 622 deletions

View file

@ -3,12 +3,12 @@ const retirement = `${env.API_URI}/retirement`
export default {
profile: (type: string, year: number) => `${retirement}/profile/${type}/${year}`,
profile: (type: string, year: string) => `${retirement}/profile/${type}/${year}`,
profileRetire: (retireId: string) => `${retirement}/profile/${retireId}`,
getprofileRetire: (retireId: string) => `${retirement}/${retireId}`,
createnote: () => `${retirement}/reason/`,
listRetire: (retireId: string) => `${retirement}/${retireId}`,
createnote: () => `${retirement}/reason`,
reasonId: (retireId:string) => `${retirement}/reason/${retireId}`,
retirement:(type:string,year:number) => `${retirement}/${type}/${year}`
retirement:(type:string,year:string) => `${retirement}/${type}/${year}`

View file

@ -207,7 +207,7 @@ const menuList = readonly<any[]>([
{
key: 6.4,
label: "รายการคำขอโอน" /* */,
path: "tranfer",
path: "transfer",
role: "placement",
},
{
@ -216,6 +216,12 @@ const menuList = readonly<any[]>([
path: "receive",
role: "placement",
},
{
key: 6.5,
label: "คำสั่งช่วยราชการ/ส่งตัวกลับ" /* */,
path: "order-repatriation",
role: "placement",
},
],
},

View file

@ -21,24 +21,24 @@
<div class="col-12 text-top0 row items-center ">
<q-icon name="mdi-label" color="grey-4" class="q-pr-sm" />
นเรมทดลองปฎหนาทราชการ งแตนท
<span class="text-black q-px-sm">{{date2Thai(dateToday)}}</span>
งวนท
<span class="text-black q-px-sm">{{date2Thai(dateEnd)}}</span>
<span class="text-black q-px-sm">{{ date2Thai(dateToday) }}</span>
งวนท
<span class="text-black q-px-sm">{{ date2Thai(dateEnd) }}</span>
</div>
<div class="col-12 text-top0 row items-center">
<q-icon name="mdi-label" color="grey-4" class="q-pr-sm" />
การทดลองปฏหนาทราชการมผล งน
<span class="text-black q-px-sm">{{ "ครั้งที่" + period }}</span>
ระหวางวนท
<span class="text-black q-px-sm">{{ date2Thai(dateToday)}}</span>
<span class="text-black q-px-sm">{{ date2Thai(dateToday) }}</span>
งวนท
<span class="text-black q-px-sm">{{date2Thai(dateEnd)}}</span>
<span class="text-black q-px-sm">{{ date2Thai(dateEnd) }}</span>
</div>
<div class="col-12 q-pt-md">
<q-separator size="3px" color="grey-2" />
</div>
</div>
<div class="col-12 row">
<div class="col-12 text-top0 items-center">
<q-avatar class="bg-grey-2 q-mr-sm" size="28px">1</q-avatar>
@ -52,40 +52,33 @@
1.ผลผลตของงานทคาดหว
</div>
<q-card flat bordered class="col-xs-12 col-sm-11 col-md-10 offset-md-1 q-pa-sm bg-grey-1">
<q-list dense v-for="(list,i) in list1_1" :key="i">
<q-list dense v-for="(list, i) in list1_1" :key="i">
<q-item dense tag="label" v-ripple>
<q-item-section>
<q-item-label>{{ list.label }}</q-item-label>
</q-item-section>
<q-item-section side >
<q-rating
v-model="model"
:val="list.id"
max="5"
size="sm"
color="grey"
:color-selected="ratingColors"
label="ระดับการประเมินพฤติกรรม"
>
<q-item-section side>
<q-rating v-model="model" :val="list.id" max="5" size="sm" color="grey"
:color-selected="ratingColors" label="ระดับการประเมินพฤติกรรม">
<template v-slot:tip-1>
<q-tooltip>ปรบปร</q-tooltip>
<q-tooltip>ำกวาความคาดหวงมาก</q-tooltip>
</template>
<template v-slot:tip-2>
<q-tooltip>พอใช</q-tooltip>
<q-tooltip>ำกวาความคาดหวงคอนขางมาก</q-tooltip>
</template>
<template v-slot:tip-3>
<q-tooltip>ปานกลา</q-tooltip>
<q-tooltip>เปนไปตามความคาดหว</q-tooltip>
</template>
<template v-slot:tip-4>
<q-tooltip></q-tooltip>
<q-tooltip>งวาความคาดหวงคอนขางมาก</q-tooltip>
</template>
<template v-slot:tip-5>
<q-tooltip>มาก</q-tooltip>
<q-tooltip>งกวาความคาดหวมาก</q-tooltip>
</template>
</q-rating>
</q-item-section>
</q-item>
<q-separator class="q-my-xs" v-if="i + 1 < list1_1.length" />
<q-separator class="q-my-xs" v-if="i + 1 < list1_1.length" />
</q-list>
</q-card>
</div>
@ -98,40 +91,36 @@
1.ผลผลตของงานทเกดข
</div>
<q-card flat bordered class="col-xs-12 col-sm-11 col-md-10 offset-md-1 q-pa-sm bg-grey-1">
<q-list dense v-for="(list,i) in list1_2" :key="i">
<q-list dense v-for="(list, i) in list1_2" :key="i">
<q-item dense tag="label" v-ripple>
<q-item-section>
<q-item-label>{{ list.label }}</q-item-label>
<!-- <q-item-label>{{ list.label }}</q-item-label> -->
<q-input outlined dense v-model="text2_1"
class="col-xs-12 col-sm-11 col-md-10 offset-md-1" lazy-rules type="textarea"
label="ผลผลิตของงานที่เกิดขึ้นจริง" hide-bottom-space :row="1"/>
</q-item-section>
<q-item-section side >
<q-rating
v-model="model1"
:val="list.id"
max="5"
size="sm"
color="grey"
:color-selected="ratingColors"
label="ระดับการประเมินพฤติกรรม"
>
<q-item-section side>
<q-rating v-model="model1" :val="list.id" max="5" size="sm" color="grey"
:color-selected="ratingColors" label="ระดับการประเมินพฤติกรรม">
<template v-slot:tip-1>
<q-tooltip>ปรบปร</q-tooltip>
<q-tooltip>ำกวาความคาดหวงมาก</q-tooltip>
</template>
<template v-slot:tip-2>
<q-tooltip>พอใช</q-tooltip>
<q-tooltip>ำกวาความคาดหวงคอนขางมาก</q-tooltip>
</template>
<template v-slot:tip-3>
<q-tooltip>ปานกลา</q-tooltip>
<q-tooltip>เปนไปตามความคาดหว</q-tooltip>
</template>
<template v-slot:tip-4>
<q-tooltip></q-tooltip>
<q-tooltip>งวาความคาดหวงคอนขางมาก</q-tooltip>
</template>
<template v-slot:tip-5>
<q-tooltip>มาก</q-tooltip>
<q-tooltip>งกวาความคาดหวมาก</q-tooltip>
</template>
</q-rating>
</q-item-section>
</q-item>
<q-separator class="q-my-xs" v-if="i + 1 < list1_2.length" />
<q-separator class="q-my-xs" v-if="i + 1 < list1_2.length" />
</q-list>
</q-card>
</div>
@ -146,29 +135,23 @@
<q-item-section>
<q-item-label>ความรความสามารถ</q-item-label>
</q-item-section>
<q-item-section side >
<q-rating
v-model="model1_2"
max="5"
size="sm"
color="grey"
:color-selected="ratingColors"
label="ระดับการประเมินพฤติกรรม"
>
<q-item-section side>
<q-rating v-model="model1_2" max="5" size="sm" color="grey"
:color-selected="ratingColors" label="ระดับการประเมินพฤติกรรม">
<template v-slot:tip-1>
<q-tooltip>ปรบปร</q-tooltip>
<q-tooltip>ำกวาความคาดหวงมาก</q-tooltip>
</template>
<template v-slot:tip-2>
<q-tooltip>พอใช</q-tooltip>
<q-tooltip>ำกวาความคาดหวงคอนขางมาก</q-tooltip>
</template>
<template v-slot:tip-3>
<q-tooltip>ปานกลา</q-tooltip>
<q-tooltip>เปนไปตามความคาดหว</q-tooltip>
</template>
<template v-slot:tip-4>
<q-tooltip></q-tooltip>
<q-tooltip>งวาความคาดหวงคอนขางมาก</q-tooltip>
</template>
<template v-slot:tip-5>
<q-tooltip>มาก</q-tooltip>
<q-tooltip>งกวาความคาดหวมาก</q-tooltip>
</template>
</q-rating>
</q-item-section>
@ -187,29 +170,23 @@
<q-item-section>
<q-item-label>กษะ</q-item-label>
</q-item-section>
<q-item-section side >
<q-rating
v-model="model1_3"
max="5"
size="sm"
color="grey"
:color-selected="ratingColors"
label="ระดับการประเมินพฤติกรรม"
>
<q-item-section side>
<q-rating v-model="model1_3" max="5" size="sm" color="grey"
:color-selected="ratingColors" label="ระดับการประเมินพฤติกรรม">
<template v-slot:tip-1>
<q-tooltip>ปรบปร</q-tooltip>
<q-tooltip>ำกวาความคาดหวงมาก</q-tooltip>
</template>
<template v-slot:tip-2>
<q-tooltip>พอใช</q-tooltip>
<q-tooltip>ำกวาความคาดหวงคอนขางมาก</q-tooltip>
</template>
<template v-slot:tip-3>
<q-tooltip>ปานกลา</q-tooltip>
<q-tooltip>เปนไปตามความคาดหว</q-tooltip>
</template>
<template v-slot:tip-4>
<q-tooltip></q-tooltip>
<q-tooltip>งวาความคาดหวงคอนขางมาก</q-tooltip>
</template>
<template v-slot:tip-5>
<q-tooltip>มาก</q-tooltip>
<q-tooltip>งกวาความคาดหวมาก</q-tooltip>
</template>
</q-rating>
</q-item-section>
@ -228,29 +205,23 @@
<q-item-section>
<q-item-label>สมรรถนะ</q-item-label>
</q-item-section>
<q-item-section side >
<q-rating
v-model="model1_4"
max="5"
size="sm"
color="grey"
:color-selected="ratingColors"
label="ระดับการประเมินพฤติกรรม"
>
<q-item-section side>
<q-rating v-model="model1_4" max="5" size="sm" color="grey"
:color-selected="ratingColors" label="ระดับการประเมินพฤติกรรม">
<template v-slot:tip-1>
<q-tooltip>ปรบปร</q-tooltip>
<q-tooltip>ำกวาความคาดหวงมาก</q-tooltip>
</template>
<template v-slot:tip-2>
<q-tooltip>พอใช</q-tooltip>
<q-tooltip>ำกวาความคาดหวงคอนขางมาก</q-tooltip>
</template>
<template v-slot:tip-3>
<q-tooltip>ปานกลา</q-tooltip>
<q-tooltip>เปนไปตามความคาดหว</q-tooltip>
</template>
<template v-slot:tip-4>
<q-tooltip></q-tooltip>
<q-tooltip>งวาความคาดหวงคอนขางมาก</q-tooltip>
</template>
<template v-slot:tip-5>
<q-tooltip>มาก</q-tooltip>
<q-tooltip>งกวาความคาดหวมาก</q-tooltip>
</template>
</q-rating>
</q-item-section>
@ -269,29 +240,23 @@
<q-item-section>
<q-item-label>ความสามารถในการเรยนรงาน</q-item-label>
</q-item-section>
<q-item-section side >
<q-rating
v-model="model1_5"
max="5"
size="sm"
color="grey"
:color-selected="ratingColors"
label="ระดับการประเมินพฤติกรรม"
>
<q-item-section side>
<q-rating v-model="model1_5" max="5" size="sm" color="grey"
:color-selected="ratingColors" label="ระดับการประเมินพฤติกรรม">
<template v-slot:tip-1>
<q-tooltip>ปรบปร</q-tooltip>
<q-tooltip>ำกวาความคาดหวงมาก</q-tooltip>
</template>
<template v-slot:tip-2>
<q-tooltip>พอใช</q-tooltip>
<q-tooltip>ำกวาความคาดหวงคอนขางมาก</q-tooltip>
</template>
<template v-slot:tip-3>
<q-tooltip>ปานกลา</q-tooltip>
<q-tooltip>เปนไปตามความคาดหว</q-tooltip>
</template>
<template v-slot:tip-4>
<q-tooltip></q-tooltip>
<q-tooltip>งวาความคาดหวงคอนขางมาก</q-tooltip>
</template>
<template v-slot:tip-5>
<q-tooltip>มาก</q-tooltip>
<q-tooltip>งกวาความคาดหวมาก</q-tooltip>
</template>
</q-rating>
</q-item-section>
@ -310,29 +275,23 @@
<q-item-section>
<q-item-label>ความสามารถในการปรบใชความรบงานในหนาท</q-item-label>
</q-item-section>
<q-item-section side >
<q-rating
v-model="model1_6"
max="5"
size="sm"
color="grey"
:color-selected="ratingColors"
label="ระดับการประเมินพฤติกรรม"
>
<q-item-section side>
<q-rating v-model="model1_6" max="5" size="sm" color="grey"
:color-selected="ratingColors" label="ระดับการประเมินพฤติกรรม">
<template v-slot:tip-1>
<q-tooltip>ปรบปร</q-tooltip>
<q-tooltip>ำกวาความคาดหวงมาก</q-tooltip>
</template>
<template v-slot:tip-2>
<q-tooltip>พอใช</q-tooltip>
<q-tooltip>ำกวาความคาดหวงคอนขางมาก</q-tooltip>
</template>
<template v-slot:tip-3>
<q-tooltip>ปานกลา</q-tooltip>
<q-tooltip>เปนไปตามความคาดหว</q-tooltip>
</template>
<template v-slot:tip-4>
<q-tooltip></q-tooltip>
<q-tooltip>งวาความคาดหวงคอนขางมาก</q-tooltip>
</template>
<template v-slot:tip-5>
<q-tooltip>มาก</q-tooltip>
<q-tooltip>งกวาความคาดหวมาก</q-tooltip>
</template>
</q-rating>
</q-item-section>
@ -343,50 +302,37 @@
<div class="col-12 row">
<div class="col-12 text-top0 row items-center q-pl-lg">
<q-icon name="mdi-label" color="grey-4" class="q-pr-sm" />
1.7 นๆ
1.7 นๆ
<q-checkbox class="q-ml-sm" dense v-model="etc" />
</div>
<q-card v-if="etc" flat bordered class="col-xs-12 col-sm-11 col-md-10 offset-md-1 q-pa-sm bg-grey-1">
<q-card v-if="etc" flat bordered
class="col-xs-12 col-sm-11 col-md-10 offset-md-1 q-pa-sm bg-grey-1">
<q-list dense>
<q-item dense tag="label" v-ripple>
<q-item-section>
<q-item-label>
<q-input
v-model="etc_text"
label="กรอกอื่นๆ"
dense
lazy-rules
autogrow
hide-bottom-space
outlined
class="bg-white"
:rules="[(val) => (val && val.length > 0) || 'กรุณากรอกข้อความ']"
/>
<q-input v-model="etc_text" label="กรอกอื่นๆ" dense lazy-rules autogrow
hide-bottom-space outlined class="bg-white"
:rules="[(val) => (val && val.length > 0) || 'กรุณากรอกข้อความ']" />
</q-item-label>
</q-item-section>
<q-item-section side >
<q-rating
v-model="modelEtc"
max="5"
size="sm"
color="grey"
:color-selected="ratingColors"
label="ระดับการประเมินพฤติกรรม"
>
<q-item-section side>
<q-rating v-model="modelEtc" max="5" size="sm" color="grey"
:color-selected="ratingColors" label="ระดับการประเมินพฤติกรรม">
<template v-slot:tip-1>
<q-tooltip>ปรบปร</q-tooltip>
<q-tooltip>ำกวาความคาดหวงมาก</q-tooltip>
</template>
<template v-slot:tip-2>
<q-tooltip>พอใช</q-tooltip>
<q-tooltip>ำกวาความคาดหวงคอนขางมาก</q-tooltip>
</template>
<template v-slot:tip-3>
<q-tooltip>ปานกลา</q-tooltip>
<q-tooltip>เปนไปตามความคาดหว</q-tooltip>
</template>
<template v-slot:tip-4>
<q-tooltip></q-tooltip>
<q-tooltip>งวาความคาดหวงคอนขางมาก</q-tooltip>
</template>
<template v-slot:tip-5>
<q-tooltip>มาก</q-tooltip>
<q-tooltip>งกวาความคาดหวมาก</q-tooltip>
</template>
</q-rating>
</q-item-section>
@ -399,36 +345,18 @@
<q-icon name="mdi-label" color="grey-4" class="q-pr-sm" />
ดเด (ไมเก 5 บรรท)
</div>
<q-input
outlined
dense
v-model="text2_1"
class="col-xs-12 col-sm-11 col-md-10 offset-md-1"
lazy-rules
type="textarea"
label="กรอกจุดเด่น"
hide-bottom-space
:row="5"
:rules="[(val) => (val && val.length > 0) || 'กรุณากรอกข้อความ']"
/>
<q-input outlined dense v-model="text2_1" class="col-xs-12 col-sm-11 col-md-10 offset-md-1"
lazy-rules type="textarea" label="กรอกจุดเด่น" hide-bottom-space :row="5"
:rules="[(val) => (val && val.length > 0) || 'กรุณากรอกข้อความ']" />
</div>
<div class="col-12 row">
<div class="col-12 text-top0 row items-center q-pl-lg">
<q-icon name="mdi-label" color="grey-4" class="q-pr-sm" />
งทควรปรบปร (ไมเก 5 บรรท)
</div>
<q-input
outlined
dense
v-model="text2_2"
class="col-xs-12 col-sm-11 col-md-10 offset-md-1"
lazy-rules
type="textarea"
hide-bottom-space
label="กรอกสิ่งที่ควรปรับปรุง"
:row="5"
:rules="[(val) => (val && val.length > 0) || 'กรุณากรอกข้อความ']"
/>
<q-input outlined dense v-model="text2_2" class="col-xs-12 col-sm-11 col-md-10 offset-md-1"
lazy-rules type="textarea" hide-bottom-space label="กรอกสิ่งที่ควรปรับปรุง" :row="5"
:rules="[(val) => (val && val.length > 0) || 'กรุณากรอกข้อความ']" />
</div>
<div class="col-12">
@ -446,40 +374,33 @@
2.1 ความประพฤต
</div>
<q-card flat bordered class="col-xs-12 col-sm-11 col-md-10 offset-md-1 q-pa-sm bg-grey-1">
<q-list dense v-for="(list,i) in list2_1" :key="i">
<q-list dense v-for="(list, i) in list2_1" :key="i">
<q-item dense tag="label" v-ripple>
<q-item-section>
<q-item-label>{{ list.label }}</q-item-label>
</q-item-section>
<q-item-section side >
<q-rating
v-model="model"
:val="list.id"
max="5"
size="sm"
color="grey"
:color-selected="ratingColors"
label="ระดับการประเมินพฤติกรรม"
>
<q-item-section side>
<q-rating v-model="model" :val="list.id" max="5" size="sm" color="grey"
:color-selected="ratingColors" label="ระดับการประเมินพฤติกรรม">
<template v-slot:tip-1>
<q-tooltip>ปรบปร</q-tooltip>
<q-tooltip>ำกวาความคาดหวงมาก</q-tooltip>
</template>
<template v-slot:tip-2>
<q-tooltip>พอใช</q-tooltip>
<q-tooltip>ำกวาความคาดหวงคอนขางมาก</q-tooltip>
</template>
<template v-slot:tip-3>
<q-tooltip>ปานกลา</q-tooltip>
<q-tooltip>เปนไปตามความคาดหว</q-tooltip>
</template>
<template v-slot:tip-4>
<q-tooltip></q-tooltip>
<q-tooltip>งวาความคาดหวงคอนขางมาก</q-tooltip>
</template>
<template v-slot:tip-5>
<q-tooltip>มาก</q-tooltip>
<q-tooltip>งกวาความคาดหวมาก</q-tooltip>
</template>
</q-rating>
</q-item-section>
</q-item>
<q-separator class="q-my-xs" v-if="i + 1 < list2_1.length" />
<q-separator class="q-my-xs" v-if="i + 1 < list2_1.length" />
</q-list>
</q-card>
</div>
@ -489,40 +410,33 @@
2.2 ความมณธรรมจรยธรรม
</div>
<q-card flat bordered class="col-xs-12 col-sm-11 col-md-10 offset-md-1 q-pa-sm bg-grey-1">
<q-list dense v-for="(list,i) in list2_2" :key="i">
<q-list dense v-for="(list, i) in list2_2" :key="i">
<q-item dense tag="label" v-ripple>
<q-item-section>
<q-item-label>{{ list.label }}</q-item-label>
</q-item-section>
<q-item-section side >
<q-rating
v-model="model"
:val="list.id"
max="5"
size="sm"
color="grey"
:color-selected="ratingColors"
label="ระดับการประเมินพฤติกรรม"
>
<q-item-section side>
<q-rating v-model="model" :val="list.id" max="5" size="sm" color="grey"
:color-selected="ratingColors" label="ระดับการประเมินพฤติกรรม">
<template v-slot:tip-1>
<q-tooltip>ปรบปร</q-tooltip>
<q-tooltip>ำกวาความคาดหวงมาก</q-tooltip>
</template>
<template v-slot:tip-2>
<q-tooltip>พอใช</q-tooltip>
<q-tooltip>ำกวาความคาดหวงคอนขางมาก</q-tooltip>
</template>
<template v-slot:tip-3>
<q-tooltip>ปานกลา</q-tooltip>
<q-tooltip>เปนไปตามความคาดหว</q-tooltip>
</template>
<template v-slot:tip-4>
<q-tooltip></q-tooltip>
<q-tooltip>งวาความคาดหวงคอนขางมาก</q-tooltip>
</template>
<template v-slot:tip-5>
<q-tooltip>มาก</q-tooltip>
<q-tooltip>งกวาความคาดหวมาก</q-tooltip>
</template>
</q-rating>
</q-item-section>
</q-item>
<q-separator class="q-my-xs" v-if="i + 1 < list2_2.length" />
<q-separator class="q-my-xs" v-if="i + 1 < list2_2.length" />
</q-list>
</q-card>
</div>
@ -532,90 +446,70 @@
2.3 การรกษาว
</div>
<q-card flat bordered class="col-xs-12 col-sm-11 col-md-10 offset-md-1 q-pa-sm bg-grey-1">
<q-list dense v-for="(list,i) in list2_3" :key="i">
<q-list dense v-for="(list, i) in list2_3" :key="i">
<q-item dense tag="label" v-ripple>
<q-item-section>
<q-item-label>{{ list.label }}</q-item-label>
</q-item-section>
<q-item-section side >
<q-rating
v-model="model"
:val="list.id"
max="5"
size="sm"
color="grey"
:color-selected="ratingColors"
label="ระดับการประเมินพฤติกรรม"
>
<q-item-section side>
<q-rating v-model="model" :val="list.id" max="5" size="sm" color="grey"
:color-selected="ratingColors" label="ระดับการประเมินพฤติกรรม">
<template v-slot:tip-1>
<q-tooltip>ปรบปร</q-tooltip>
<q-tooltip>ำกวาความคาดหวงมาก</q-tooltip>
</template>
<template v-slot:tip-2>
<q-tooltip>พอใช</q-tooltip>
<q-tooltip>ำกวาความคาดหวงคอนขางมาก</q-tooltip>
</template>
<template v-slot:tip-3>
<q-tooltip>ปานกลา</q-tooltip>
<q-tooltip>เปนไปตามความคาดหว</q-tooltip>
</template>
<template v-slot:tip-4>
<q-tooltip></q-tooltip>
<q-tooltip>งวาความคาดหวงคอนขางมาก</q-tooltip>
</template>
<template v-slot:tip-5>
<q-tooltip>มาก</q-tooltip>
<q-tooltip>งกวาความคาดหวมาก</q-tooltip>
</template>
</q-rating>
</q-item-section>
</q-item>
<q-separator class="q-my-xs" v-if="i + 1 < list2_3.length" />
<q-separator class="q-my-xs" v-if="i + 1 < list2_3.length" />
</q-list>
</q-card>
</div>
<div class="col-12 row">
<div class="col-12 text-top0 row items-center q-pl-lg">
<q-icon name="mdi-label" color="grey-4" class="q-pr-sm" />
2.4 นๆ
2.4 นๆ
<q-checkbox class="q-ml-sm" dense v-model="etc_4" />
</div>
<q-card v-if="etc_4" flat bordered class="col-xs-12 col-sm-11 col-md-10 offset-md-1 q-pa-sm bg-grey-1">
<q-card v-if="etc_4" flat bordered
class="col-xs-12 col-sm-11 col-md-10 offset-md-1 q-pa-sm bg-grey-1">
<q-list dense>
<q-item dense tag="label" v-ripple>
<q-item-section>
<q-item-label>
<q-input
v-model="etc_text2"
label="กรอกอื่นๆ"
dense
lazy-rules
autogrow
hide-bottom-space
outlined
class="bg-white"
:rules="[(val) => (val && val.length > 0) || 'กรุณากรอกข้อความ']"
/>
<q-input v-model="etc_text2" label="กรอกอื่นๆ" dense lazy-rules autogrow
hide-bottom-space outlined class="bg-white"
:rules="[(val) => (val && val.length > 0) || 'กรุณากรอกข้อความ']" />
</q-item-label>
</q-item-section>
<q-item-section side >
<q-rating
v-model="modelEtc"
max="5"
size="sm"
color="grey"
:color-selected="ratingColors"
label="ระดับการประเมินพฤติกรรม"
>
<q-item-section side>
<q-rating v-model="modelEtc" max="5" size="sm" color="grey"
:color-selected="ratingColors" label="ระดับการประเมินพฤติกรรม">
<template v-slot:tip-1>
<q-tooltip>ปรบปร</q-tooltip>
<q-tooltip>ำกวาความคาดหวงมาก</q-tooltip>
</template>
<template v-slot:tip-2>
<q-tooltip>พอใช</q-tooltip>
<q-tooltip>ำกวาความคาดหวงคอนขางมาก</q-tooltip>
</template>
<template v-slot:tip-3>
<q-tooltip>ปานกลา</q-tooltip>
<q-tooltip>เปนไปตามความคาดหว</q-tooltip>
</template>
<template v-slot:tip-4>
<q-tooltip></q-tooltip>
<q-tooltip>งวาความคาดหวงคอนขางมาก</q-tooltip>
</template>
<template v-slot:tip-5>
<q-tooltip>มาก</q-tooltip>
<q-tooltip>งกวาความคาดหวมาก</q-tooltip>
</template>
</q-rating>
</q-item-section>
@ -628,36 +522,18 @@
<q-icon name="mdi-label" color="grey-4" class="q-pr-sm" />
ดเด (ไมเก 5 บรรท)
</div>
<q-input
outlined
dense
v-model="text3_1"
class="col-xs-12 col-sm-11 col-md-10 offset-md-1"
lazy-rules
type="textarea"
label="กรอกจุดเด่น"
hide-bottom-space
:row="5"
:rules="[(val) => (val && val.length > 0) || 'กรุณากรอกข้อความ']"
/>
<q-input outlined dense v-model="text3_1" class="col-xs-12 col-sm-11 col-md-10 offset-md-1"
lazy-rules type="textarea" label="กรอกจุดเด่น" hide-bottom-space :row="5"
:rules="[(val) => (val && val.length > 0) || 'กรุณากรอกข้อความ']" />
</div>
<div class="col-12 row">
<div class="col-12 text-top0 row items-center q-pl-lg">
<q-icon name="mdi-label" color="grey-4" class="q-pr-sm" />
งทควรปรบปร (ไมเก 5 บรรท)
</div>
<q-input
outlined
dense
v-model="text3_2"
class="col-xs-12 col-sm-11 col-md-10 offset-md-1"
lazy-rules
type="textarea"
hide-bottom-space
label="กรอกสิ่งที่ควรปรับปรุง"
:row="5"
:rules="[(val) => (val && val.length > 0) || 'กรุณากรอกข้อความ']"
/>
<q-input outlined dense v-model="text3_2" class="col-xs-12 col-sm-11 col-md-10 offset-md-1"
lazy-rules type="textarea" hide-bottom-space label="กรอกสิ่งที่ควรปรับปรุง" :row="5"
:rules="[(val) => (val && val.length > 0) || 'กรุณากรอกข้อความ']" />
</div>
<div class="col-12">
@ -676,94 +552,54 @@
<q-item-section>
<q-item-label>1. การปฐมนเทศ</q-item-label>
</q-item-section>
<q-item-section side >
<q-item-section side>
<div class="row">
<q-radio
checked-icon="task_alt"
unchecked-icon="panorama_fish_eye"
v-model="radio_1"
val="1"
label="ดำเนินการเเล้ว"
/>
<q-radio
checked-icon="task_alt"
unchecked-icon="panorama_fish_eye"
v-model="radio_1"
val="0"
label=" ยังไม่ได้ดำเนินการ"
/>
<q-radio checked-icon="task_alt" unchecked-icon="panorama_fish_eye"
v-model="radio_1" val="1" label="ดำเนินการเเล้ว" />
<q-radio checked-icon="task_alt" unchecked-icon="panorama_fish_eye"
v-model="radio_1" val="0" label=" ยังไม่ได้ดำเนินการ" />
</div>
</q-item-section>
</q-item>
<q-separator class="q-my-xs"/>
<q-separator class="q-my-xs" />
<q-item dense tag="label" v-ripple>
<q-item-section>
<q-item-label>2. การเรยนรวยตนเอง</q-item-label>
</q-item-section>
<q-item-section side >
<q-item-section side>
<div class="row">
<q-radio
checked-icon="task_alt"
unchecked-icon="panorama_fish_eye"
v-model="radio_2"
val="1"
label="ดำเนินการเเล้ว"
/>
<q-radio
checked-icon="task_alt"
unchecked-icon="panorama_fish_eye"
v-model="radio_2"
val="0"
label=" ยังไม่ได้ดำเนินการ"
/>
<q-radio checked-icon="task_alt" unchecked-icon="panorama_fish_eye"
v-model="radio_2" val="1" label="ดำเนินการเเล้ว" />
<q-radio checked-icon="task_alt" unchecked-icon="panorama_fish_eye"
v-model="radio_2" val="0" label=" ยังไม่ได้ดำเนินการ" />
</div>
</q-item-section>
</q-item>
<q-separator class="q-my-xs"/>
<q-separator class="q-my-xs" />
<q-item dense tag="label" v-ripple>
<q-item-section>
<q-item-label>3. การอบรมสมนารวมก</q-item-label>
</q-item-section>
<q-item-section side >
<q-item-section side>
<div class="row">
<q-radio
checked-icon="task_alt"
unchecked-icon="panorama_fish_eye"
v-model="radio_3"
val="1"
label="ดำเนินการเเล้ว"
/>
<q-radio
checked-icon="task_alt"
unchecked-icon="panorama_fish_eye"
v-model="radio_3"
val="0"
label=" ยังไม่ได้ดำเนินการ"
/>
<q-radio checked-icon="task_alt" unchecked-icon="panorama_fish_eye"
v-model="radio_3" val="1" label="ดำเนินการเเล้ว" />
<q-radio checked-icon="task_alt" unchecked-icon="panorama_fish_eye"
v-model="radio_3" val="0" label=" ยังไม่ได้ดำเนินการ" />
</div>
</q-item-section>
</q-item>
<q-separator class="q-my-xs"/>
<q-separator class="q-my-xs" />
<q-item dense tag="label" v-ripple>
<q-item-section>
<q-item-label>4. การอบรมอ ตามทหนวยงานกำหนด (าม)</q-item-label>
</q-item-section>
<q-item-section side >
<q-item-section side>
<div class="row">
<q-radio
checked-icon="task_alt"
unchecked-icon="panorama_fish_eye"
v-model="radio_4"
val="1"
label="ดำเนินการเเล้ว"
/>
<q-radio
checked-icon="task_alt"
unchecked-icon="panorama_fish_eye"
v-model="radio_4"
val="0"
label=" ยังไม่ได้ดำเนินการ"
/>
<q-radio checked-icon="task_alt" unchecked-icon="panorama_fish_eye"
v-model="radio_4" val="1" label="ดำเนินการเเล้ว" />
<q-radio checked-icon="task_alt" unchecked-icon="panorama_fish_eye"
v-model="radio_4" val="0" label=" ยังไม่ได้ดำเนินการ" />
</div>
</q-item-section>
</q-item>
@ -780,49 +616,25 @@
งคบบญชาผมอบหมายงาน
</div>
<div class="col-12 row q-col-gutter-md">
<q-select
class="col-xs-12 col-sm-8"
dense
v-model="Autherise"
outlined
:options="option"
<q-select class="col-xs-12 col-sm-8" dense v-model="Autherise" outlined :options="option"
label="ผู้บังคับบัญชา" />
<div class="col-xs-12 col-sm-4">
<datepicker
menu-class-name="modalfix"
v-model="dateAutherise"
:locale="'th'"
autoApply
borderless
:enableTimePicker="false"
week-start="0"
>
<datepicker menu-class-name="modalfix" v-model="dateAutherise" :locale="'th'" autoApply
borderless :enableTimePicker="false" week-start="0">
<template #year="{ year }">
{{ year + 543 }}
{{ year + 543 }}
</template>
<template #year-overlay-value="{ value }">
{{ parseInt(value + 543) }}
{{ parseInt(value + 543) }}
</template>
<template #trigger>
<q-input
outlined
dense
class="full-width datepicker col-3"
:model-value="
dateAutherise != null ? date2Thai(dateAutherise) : null
"
:label="`${'ลงวันที่'}`"
:rules="[(val) => !!val || `${'กรุณาเลือกลงวันที่'}`]"
>
<template v-slot:prepend>
<q-icon
name="event"
class="cursor-pointer"
style="color: var(--q-primary)"
>
</q-icon>
</template>
</q-input>
<q-input outlined dense class="full-width datepicker col-3" :model-value="dateAutherise != null ? date2Thai(dateAutherise) : null
" :label="`${'ลงวันที่'}`" :rules="[(val) => !!val || `${'กรุณาเลือกลงวันที่'}`]">
<template v-slot:prepend>
<q-icon name="event" class="cursor-pointer" style="color: var(--q-primary)">
</q-icon>
</template>
</q-input>
</template>
</datepicker>
</div>
@ -832,7 +644,7 @@
</div>
<q-separator />
<div class="flex justify-end q-px-sm q-pt-sm">
<q-btn dense class="q-px-md" unelevated label="บันทึก" color="public"/>
<q-btn dense class="q-px-md" unelevated label="บันทึก" color="public" />
</div>
</div>
</div>
@ -845,40 +657,40 @@ import { useQuasar } from "quasar";
import router from "@/router";
const $q = useQuasar();
const ratingColors = [ 'light-blue-3', 'light-blue-6', 'blue', 'blue-9', 'blue-10' ];
const ratingColors = ['light-blue-3', 'light-blue-6', 'blue', 'blue-9', 'blue-10'];
const list1_1 = [
{id: '1', label: 'ผลผลิตของงานที่คาดหวัง 1'},
{id: '2', label: 'ผลผลิตของงานที่คาดหวัง 2'},
{id: '3', label: 'ผลผลิตของงานที่คาดหวัง 3'},
{id: '4', label: 'ผลผลิตของงานที่คาดหวัง 4'},
{id: '5', label: 'ผลผลิตของงานที่คาดหวัง 5'}
{ id: '1', label: 'ผลผลิตของงานที่คาดหวัง 1' },
{ id: '2', label: 'ผลผลิตของงานที่คาดหวัง 2' },
{ id: '3', label: 'ผลผลิตของงานที่คาดหวัง 3' },
{ id: '4', label: 'ผลผลิตของงานที่คาดหวัง 4' },
{ id: '5', label: 'ผลผลิตของงานที่คาดหวัง 5' }
];
const list1_2 = [
{id: '1', label: 'ผลผลิตของงานที่เกิดขึ้น 1'},
{id: '2', label: 'ผลผลิตของงานที่เกิดขึ้น 2'},
{id: '3', label: 'ผลผลิตของงานที่เกิดขึ้น 3'},
{id: '4', label: 'ผลผลิตของงานที่เกิดขึ้น 4'},
{id: '5', label: 'ผลผลิตของงานที่เกิดขึ้น 5'}
{ id: '1', label: 'ผลผลิตของงานที่เกิดขึ้น 1' },
{ id: '2', label: 'ผลผลิตของงานที่เกิดขึ้น 2' },
{ id: '3', label: 'ผลผลิตของงานที่เกิดขึ้น 3' },
{ id: '4', label: 'ผลผลิตของงานที่เกิดขึ้น 4' },
{ id: '5', label: 'ผลผลิตของงานที่เกิดขึ้น 5' }
];
const list2_1 = [
{id: '1', label: 'ให้บริการประชาชนหรือผู้รับบริการด้วยอัธยาศัยดี'},
{id: '2', label: 'มีความรับผิดชอบในการปฏิบัติบัติงาน'},
{id: '3', label: 'ให้บริการประชาชนหรือผู้รับบริการด้วยความรวดเร็ว เอาใจใส่เป็นมาตรฐานเดียวกัน'},
{id: '4', label: 'ตั้งใจปฏิบัติบัติหน้าที่ราชการด้วยความอุตสาหะ ขยันหมั่นเพียร'},
{ id: '1', label: 'ให้บริการประชาชนหรือผู้รับบริการด้วยอัธยาศัยดี' },
{ id: '2', label: 'มีความรับผิดชอบในการปฏิบัติบัติงาน' },
{ id: '3', label: 'ให้บริการประชาชนหรือผู้รับบริการด้วยความรวดเร็ว เอาใจใส่เป็นมาตรฐานเดียวกัน' },
{ id: '4', label: 'ตั้งใจปฏิบัติบัติหน้าที่ราชการด้วยความอุตสาหะ ขยันหมั่นเพียร' },
];
const list2_2 = [
{id: '1', label: 'อุทิศตนและเสียสละเวลาในการปฏิบัติบัติงานอย่างเต็มกำลังความสามารถ'},
{id: '2', label: 'มีจิตสำนึกที่ดี ปฏิบัติบัติงานด้วยความซื่อสัตย์ สุจริต'},
{id: '3', label: 'ยึดมั่นในสถาบันบัพระมหากษัตริย์ และไม่กระทำการใด ๆ อันจะก่อให้เกิดความเสียหายต่อประเทศชาติ'},
{ id: '1', label: 'อุทิศตนและเสียสละเวลาในการปฏิบัติบัติงานอย่างเต็มกำลังความสามารถ' },
{ id: '2', label: 'มีจิตสำนึกที่ดี ปฏิบัติบัติงานด้วยความซื่อสัตย์ สุจริต' },
{ id: '3', label: 'ยึดมั่นในสถาบันบัพระมหากษัตริย์ และไม่กระทำการใด ๆ อันจะก่อให้เกิดความเสียหายต่อประเทศชาติ' },
];
const list2_3 = [
{id: '1', label: 'มีความรับรัผิดชอบในการรักษาเวลาทำงาน'},
{id: '2', label: 'แต่งกายในการปฏิบัติบัติงานได้อย่างเหมาะสมกับการเป็นข้าราชการ'},
{id: '3', label: 'ไม่กระทำการใด ๆ อันอาจก่อให้เกิดความเสียหายแก่ชื่อเสียงของหน่วยงาน'},
{id: '4', label: 'ไม่กระทำการใด ๆ อันเป็นการเสื่อมเกียรติและศักดิ์ศรีของความเป็นข้าราชการ'},
{id: '5', label: 'ปฏิบัติบัติหน้าที่อย่างตรงไปตรงมาโดยยึกหลักจรรยาบรรณวิชาชีพ'}
{ id: '1', label: 'มีความรับรัผิดชอบในการรักษาเวลาทำงาน' },
{ id: '2', label: 'แต่งกายในการปฏิบัติบัติงานได้อย่างเหมาะสมกับการเป็นข้าราชการ' },
{ id: '3', label: 'ไม่กระทำการใด ๆ อันอาจก่อให้เกิดความเสียหายแก่ชื่อเสียงของหน่วยงาน' },
{ id: '4', label: 'ไม่กระทำการใด ๆ อันเป็นการเสื่อมเกียรติและศักดิ์ศรีของความเป็นข้าราชการ' },
{ id: '5', label: 'ปฏิบัติบัติหน้าที่อย่างตรงไปตรงมาโดยยึกหลักจรรยาบรรณวิชาชีพ' }
];
const etc_text = ref<any>(null);
@ -914,37 +726,40 @@ const text2_1 = ref<string>('');
const text2_2 = ref<string>('');
const onSubmit = () => {
$q.notify({
color: "green-4",
textColor: "white",
icon: "cloud_done",
message: "ส่งแบบประเมินเเล้ว",
});
$q.notify({
color: "green-4",
textColor: "white",
icon: "cloud_done",
message: "ส่งแบบประเมินเเล้ว",
});
};
const onReset = () => {
router.push({ name: "probation" });
router.push({ name: "probation" });
};
</script>
<style lang="scss" scoped>
.text-top2{
.text-top2 {
font-weight: 500;
padding-bottom: 8px;
color: rgb(70, 68, 68);
color: rgb(70, 68, 68);
}
.text-top0{
.text-top0 {
font-weight: 600;
padding-bottom: 8px;
color: rgb(70, 68, 68);
color: rgb(70, 68, 68);
}
.text-Hd{
.text-Hd {
font-weight: 600;
font-size: 1rem;
padding-bottom: 5px;
color: #02A998;
font-size: 1rem;
padding-bottom: 5px;
color: #02A998;
}
.q-rating__icon{
.q-rating__icon {
text-shadow: transparent !important;
}
</style>

View file

@ -33,7 +33,7 @@
</q-item-section>
<q-item-section>
นทกผลการทดลองปฏหนาทราชการ
นทกผลการทดลองปฏหนาทราชการ (2)
</q-item-section>
</q-item>
@ -44,7 +44,7 @@
</q-item-section>
<q-item-section>
ประเมนผลการทดลองปฏหนาทราชการ
ประเมนผลการทดลองปฏหนาทราชการ (1)
</q-item-section>
</q-item>

View file

@ -485,7 +485,7 @@ const OriginalDataFetch = async () => {
//
const redirectToPage = (id?: number) => {
router.push(`/retirement/dismiss-order/add`);
router.push(`/dismiss-order/add`);
};
const clickDelete = (id: string) => {

View file

@ -9,14 +9,19 @@ const $q = useQuasar(); //ใช้ noti quasar
const mixin = useCounterMixin();
const { messageError, success } = mixin;
const props = defineProps({
retireld: String,
});
const modal = ref<boolean>(false);
const retireld = ref<any>();
const columns = ref<any["columns"]>([
{
name: "index",
name: "order",
required: true,
label: "ลำดับ",
field: "index",
field: "order",
align: "left",
},
{
@ -41,10 +46,10 @@ const columns = ref<any["columns"]>([
align: "left",
},
{
name: "affiliation",
name: "organizationOrganization",
required: true,
label: "สังกัด",
field: "affiliation",
field: "organizationOrganization",
align: "left",
},
{
@ -56,64 +61,72 @@ const columns = ref<any["columns"]>([
},
]);
const rows = ref<any>([
{
fullname: "นายใจดี ยอดใจ",
position: "นักวิชาการพัสดุ",
level: "ปฎิบัติการ",
affiliation: "กลุ่มงานโครงสร้างและอัตรากำลัง ๒",
},
{
fullname: "นายจักกริน บัณฑิต",
position: "นักวิชาการพัสดุ",
level: "ปฎิบัติการ",
affiliation: "กลุ่มงานโครงสร้างและอัตรากำลัง ๒",
},
{
fullname: "นายจักกริน บัณฑิต",
position: "นักวิชาการพัสดุ",
level: "ปฎิบัติการ",
affiliation: "กลุ่มงานโครงสร้างและอัตรากำลัง ๒",
},
{
fullname: "นายจักกริน บัณฑิต",
position: "นักวิชาการพัสดุ",
level: "ปฎิบัติการ",
affiliation: "กลุ่มงานโครงสร้างและอัตรากำลัง ๒",
},
{
fullname: "นายจักกริน บัณฑิต",
position: "นักวิชาการพัสดุ",
level: "ปฎิบัติการ",
affiliation: "กลุ่มงานโครงสร้างและอัตรากำลัง ๒",
},
{
fullname: "นายจักกริน บัณฑิต",
position: "นักวิชาการพัสดุ",
level: "ปฎิบัติการ",
affiliation: "กลุ่มงานโครงสร้างและอัตรากำลัง ๒",
},
{
fullname: "นายจักกริน บัณฑิต",
position: "นักวิชาการพัสดุ",
level: "ปฎิบัติการ",
affiliation: "กลุ่มงานโครงสร้างและอัตรากำลัง ๒",
},
// {
// fullname: " ",
// position: "",
// level: "",
// affiliation: " ",
// },
// {
// fullname: " ",
// position: "",
// level: "",
// affiliation: " ",
// },
// {
// fullname: " ",
// position: "",
// level: "",
// affiliation: " ",
// },
// {
// fullname: " ",
// position: "",
// level: "",
// affiliation: " ",
// },
// {
// fullname: " ",
// position: "",
// level: "",
// affiliation: " ",
// },
// {
// fullname: " ",
// position: "",
// level: "",
// affiliation: " ",
// },
// {
// fullname: " ",
// position: "",
// level: "",
// affiliation: " ",
// },
]);
const filter = ref<string>("");
watch(modal, () => {
if (modal.value === true) {
fecthProfile();
retireld.value = props.retireld;
fecthlistRetire(retireld.value);
}
});
const fecthProfile = async () => {
await http
.get(config.API.getprofileRetire("1234"))
.then((res) => {
console.log(res);
})
.catch((e) => {
messageError($q, e);
});
const fecthlistRetire = async (retireld: any) => {
// await http
// .get(config.API.listRetire(retireld))
// .then((res) => {
// console.log(res);
// rows.value = res.data.result.map((e: any) => ({
// order: e.order,
// fullname: e.fullName,
// position: e.position,
// level: e.positionEmployeeLevel,
// organizationOrganization: e.organizationOrganization,
// }));
// })
// .catch((e) => {
// messageError($q, e);
// });
};
const clickAdd = () => {
$q.dialog({
@ -136,7 +149,7 @@ const clickAdd = () => {
messageError($q, e);
})
.finally(() => {
fecthProfile();
fecthlistRetire();
});
})
.onCancel(() => {})
@ -223,7 +236,10 @@ const paginationLabel = (start: number, end: number, total: number) => {
</template>
<template v-slot:body="props">
<q-tr :props="props" class="cursor-pointer">
<q-td>{{ props.rowIndex + 1 }}</q-td>
<!-- <q-td>{{ props.rowIndex + 1 }}</q-td> -->
<q-td key="order" :props="props">
{{ props.row.order }}
</q-td>
<q-td key="fullname" :props="props">
{{ props.row.fullname }}
</q-td>
@ -231,8 +247,8 @@ const paginationLabel = (start: number, end: number, total: number) => {
{{ props.row.position }}
</q-td>
<q-td key="level" :props="props">{{ props.row.level }}</q-td>
<q-td key="affiliation" :props="props">
{{ props.row.affiliation }}
<q-td key="organizationOrganization" :props="props">
{{ props.row.organizationOrganization }}
</q-td>
<q-td>

View file

@ -1,5 +1,5 @@
<script setup lang="ts">
import { ref, onMounted, computed, watch } from "vue";
import { ref, onMounted, computed } from "vue";
import AddList from "../ListRetirement/AddList.vue";
import { useCounterMixin } from "@/stores/mixin";
import { useQuasar } from "quasar";
@ -11,21 +11,69 @@ const route = useRoute();
const $q = useQuasar(); // noti quasar
const mixin = useCounterMixin();
const { showLoader, hideLoader, messageError, success } = mixin;
const no = route.params.id;
const type_params = route.params.type;
const year_params = route.params.year;
const retireld_params = route.params.id;
const modalNote = ref<boolean>(false);
const note = ref<string>("");
const retireProfileId = ref<string>("");
const retireld = ref<string>();
onMounted(() => {
console.log(no);
fecthlist();
console.log(visibleNote.value);
console.log(route.params.id);
if (route.params.id === undefined) {
fecthlistprofile(type_params, year_params);
} else fecthlist(retireld_params);
});
const fecthlist = async () => {
const fecthlistprofile = async (type: any, year: any) => {
showLoader();
await http
.get(config.API.profile("emplayee", 2023))
.get(config.API.profile(type, year))
.then((res: any) => {
console.log(res);
retireld.value = res.data.result.id;
rows.value = res.data.result.profile.map((e: any) => ({
id: e.id,
order: e.order,
fixname: e.prefix,
name: e.fullName,
organizationOrganization: e.organizationOrganization,
positionType: e.positionType,
position: e.position,
positionNumber: e.posNoEmployee,
positionLavel: e.positionEmployeeLevel,
bureau: e.oc,
}));
console.log(rows.value);
})
.catch((e: any) => {
messageError($q, e);
})
.finally(() => {
hideLoader();
});
};
const fecthlist = async (id: any) => {
showLoader();
await http
.get(config.API.listRetire(id))
.then((res: any) => {
console.log(res);
retireld.value = res.data.result.id;
rows.value = res.data.result.map((e: any) => ({
id: e.id,
order: e.order,
fixname: e.prefix,
name: e.fullName,
organizationOrganization: e.organizationOrganization,
positionType: e.positionType,
position: e.position,
positionNumber: e.posNoEmployee,
positionLavel: e.positionEmployeeLevel,
bureau: e.oc,
}));
console.log(rows.value);
})
.catch((e: any) => {
messageError($q, e);
@ -36,10 +84,10 @@ const fecthlist = async () => {
};
const columns = ref<any["columns"]>([
{
name: "index",
name: "order",
required: true,
label: "ลำดับ",
field: "index",
field: "order",
align: "left",
headerStyle: "font-size: 14px",
style: "font-size: 14px",
@ -61,10 +109,10 @@ const columns = ref<any["columns"]>([
style: "font-size: 14px",
},
{
name: "brand",
name: "organizationOrganization",
align: "left",
label: "สังกัด",
field: "brand",
field: "organizationOrganization",
headerStyle: "font-size: 14px",
style: "font-size: 14px",
},
@ -78,11 +126,11 @@ const columns = ref<any["columns"]>([
style: "font-size: 14px",
},
{
name: "positionManager",
name: "position",
align: "left",
label: "ตำแหน่ง ",
sublabel: "ทางการบริหาร",
field: "positionManager",
field: "position",
headerStyle: "font-size: 14px",
style: "font-size: 14px",
},
@ -144,49 +192,50 @@ const columns = ref<any["columns"]>([
},
]);
const rows = ref<any>([
{
fixname: "นางสาว",
name: "รัชภรณ์ ภัคดี",
brand: "ฝ่ายบริหารทั่วไป",
positionType: "บริหาร",
positionManager: "จัดการทั่วไป",
positionLavel: "ชำนาญการ",
positionNumber: "กบห.2",
govGroup: "ฝ่ายบริหารทั่วไป",
govOffice: "ฝ่ายบริหารทั่วไป",
bureau: "บริหาร",
},
{
fixname: "นางสาว",
name: "รัชภรณ์ ภัคดี",
brand: "ฝ่ายบริหารทั่วไป",
positionType: "บริหาร",
positionManager: "จัดการทั่วไป",
positionLavel: "ชำนาญการ",
positionNumber: "กบห.2",
govGroup: "ฝ่ายบริหารทั่วไป",
govOffice: "ฝ่ายบริหารทั่วไป",
bureau: "บริหาร",
},
{
fixname: "นางสาว",
name: "รัชภรณ์ ภัคดี",
brand: "ฝ่ายบริหารทั่วไป",
positionType: "บริหาร",
positionManager: "จัดการทั่วไป",
positionLavel: "ชำนาญการ",
positionNumber: "กบห.2",
govGroup: "ฝ่ายบริหารทั่วไป",
govOffice: "ฝ่ายบริหารทั่วไป",
bureau: "บริหาร",
},
// {
// fixname: "",
// name: " ",
// brand: "",
// positionType: "",
// positionManager: "",
// positionLavel: "",
// positionNumber: ".2",
// govGroup: "",
// govOffice: "",
// bureau: "",
// },
// {
// fixname: "",
// name: " ",
// brand: "",
// positionType: "",
// positionManager: "",
// positionLavel: "",
// positionNumber: ".2",
// govGroup: "",
// govOffice: "",
// bureau: "",
// },
// {
// fixname: "",
// name: " ",
// brand: "",
// positionType: "",
// positionManager: "",
// positionLavel: "",
// positionNumber: ".2",
// govGroup: "",
// govOffice: "",
// bureau: "",
// },
]);
const visibleColumns = ref<any>([
"order",
"fixname",
"name",
"brand",
"organizationOrganization",
"positionType",
"positionManager",
"position",
"positionLavel",
"positionNumber",
"govGroup",
@ -198,7 +247,7 @@ const visibleColumns = ref<any>([
const filter = ref<string>("");
const clickDelete = (prop: any) => {
console.log(prop);
console.log(prop.id);
$q.dialog({
title: "ยืนยันการลบข้อมูล",
message: "ต้องการลบข้อมูลนี้ใช่หรือไม่?",
@ -210,7 +259,7 @@ const clickDelete = (prop: any) => {
})
.onOk(async () => {
await http
.delete(config.API.profileRetire("123"))
.delete(config.API.profileRetire(prop.id))
.then(() => {
success($q, "ลบข้อมูลสำเร็จ");
})
@ -218,7 +267,9 @@ const clickDelete = (prop: any) => {
messageError($q, e);
})
.finally(() => {
fecthlist();
if (route.params.id === undefined) {
fecthlistprofile(type_params, year_params);
} else fecthlist(retireld_params);
});
})
.onCancel(() => {})
@ -227,26 +278,21 @@ const clickDelete = (prop: any) => {
const backHistory = () => {
window.history.back();
};
watch(modalNote, () => {
if (modalNote.value === true) {
fetchReason();
}
});
const fetchReason = async () => {
const fetchReason = async (val: string) => {
await http
.get(config.API.reasonId("123"))
.get(config.API.reasonId(val))
.then((res: any) => {
console.log(res);
console.log(res.data.result);
note.value = res.data.result.reason;
retireProfileId.value = res.data.result.id;
})
.catch((e: any) => {
messageError($q, e);
})
.finally(() => {
hideLoader();
});
};
const saveNote = () => {
console.log(note.value);
$q.dialog({
title: "ยืนยันการบันทึกข้อมูลข้อมูล",
message: "ต้องการบันทึกข้อมูลนี้ใช่หรือไม่?",
@ -259,15 +305,19 @@ const saveNote = () => {
.onOk(async () => {
console.log("บันทึกข้อมูล");
await http
.post(config.API.createnote(), note.value)
.post(config.API.createnote(), {
retireProfileId: retireProfileId.value,
reason: note.value,
})
.then(() => {
success($q, "บันทึกข้อมูล");
success($q, "บันทึกข้อมูลสำเร็จ");
})
.catch((e) => {
messageError($q, e);
})
.finally(() => {
fecthlist();
fecthlist(retireld_params);
modalNote.value = false;
});
})
.onCancel(() => {})
@ -278,6 +328,33 @@ const visibleNote = computed(() => {
return true;
}
});
// const saveList = () => {
// $q.dialog({
// title: "",
// message: "?",
// cancel: {
// flat: true,
// color: "negative",
// },
// persistent: true,
// })
// .onOk(async () => {
// const retireld = "1233444";
// await http
// .post(config.API.listRetire("123"), { retireld: retireld })
// .then(() => {
// success($q, "");
// })
// .catch((e) => {
// messageError($q, e);
// })
// .finally(() => {
// fecthlist();
// });
// })
// .onCancel(() => {})
// .onDismiss(() => {});
// };
</script>
<template>
@ -297,10 +374,10 @@ const visibleNote = computed(() => {
<div>
<q-card class="col-12 q-pa-md">
<q-toolbar>
<AddList />
<q-btn flat round color="blue-12" icon="save">
<AddList :retireld="retireld" />
<!-- <q-btn flat round color="blue-12" icon="save" @click="saveList">
<q-tooltip>นทกขอม</q-tooltip>
</q-btn>
</q-btn> -->
<q-btn color="primary" flat round icon="download">
<q-menu>
<q-list style="min-width: 100px">
@ -385,15 +462,17 @@ const visibleNote = computed(() => {
</template>
<template v-slot:body="props">
<q-tr :props="props" class="cursor-pointer">
<q-td>{{ props.rowIndex + 1 }}</q-td>
<q-td key="order" :props="props">{{ props.row.order }}</q-td>
<q-td key="fixname" :props="props">{{ props.row.fixname }}</q-td>
<q-td key="name" :props="props">{{ props.row.name }}</q-td>
<q-td key="brand" :props="props">{{ props.row.brand }}</q-td>
<q-td key="organizationOrganization" :props="props">{{
props.row.organizationOrganization
}}</q-td>
<q-td key="positionType" :props="props">{{
props.row.positionType
}}</q-td>
<q-td key="positionManager" :props="props">{{
props.row.positionManager
<q-td key="position" :props="props">{{
props.row.position
}}</q-td>
<q-td key="positionLavel" :props="props">{{
props.row.positionLavel
@ -416,8 +495,10 @@ const visibleNote = computed(() => {
class="text-teal-5"
icon="mdi-note"
size="md"
v-if="no !== undefined"
@click="(modalNote = true), (note = '')"
v-if="retireld_params !== undefined"
@click="
fetchReason(props.row.id), (modalNote = true), (note = '')
"
>
<q-tooltip>โน</q-tooltip></q-btn
>

View file

@ -22,8 +22,8 @@ export default [
},
},
{
path: "/retirement/list",
name: "retirement/list",
path: "/retirement/list/:type/:year",
name: "retirement/list/",
component: Listretirement,
meta: {
Auth: true,
@ -92,7 +92,7 @@ export default [
},
},
{
path: "retirement/dismiss-order/add",
path: "/dismiss-order/add",
name: "dismiss-order-add",
component: addOrder,
meta: {

View file

@ -13,8 +13,12 @@
indicator-color="primary"
align="left"
>
<q-tab name="samun" label="ขรก.กทม.สามัญ" @click="getYear('officer')"/>
<q-tab name="employee" label="ลูกจ้างประจำ" @click="getYear('employee')"/>
<q-tab name="officer" label="ขรก.กทม.สามัญ" @click="type = 'officer'" />
<q-tab
name="employee"
label="ลูกจ้างประจำ"
@click="type = 'employee'"
/>
</q-tabs>
</div>
<q-separator />
@ -37,7 +41,6 @@
:outlined="true"
:hide-dropdown-icon="false"
style="min-width: 150px"
/>
<div>
<q-btn
@ -48,7 +51,7 @@
color="add"
icon="mdi-plus"
>
<q-tooltip>เพทดลองปฏหนาทราชการ</q-tooltip>
<q-tooltip>เพ</q-tooltip>
</q-btn>
<!-- <q-menu>
<q-list style="min-width: 100px">
@ -175,7 +178,7 @@
</template>
<script setup lang="ts">
import { onMounted, ref, useAttrs ,reactive} from "vue";
import { onMounted, ref, useAttrs, reactive, watch } from "vue";
import type { QTableProps } from "quasar";
import type {
FormMainProbation,
@ -185,12 +188,12 @@ import { useQuasar } from "quasar";
import { useRouter } from "vue-router";
import http from "@/plugins/http";
import config from "@/app.config";
import { useCounterMixin } from "@/stores/mixin"
import type { resMain } from '@/modules/06_retirement/interface/response/Main'
import { useCounterMixin } from "@/stores/mixin";
import type { resMain } from "@/modules/06_retirement/interface/response/Main";
const yearOptions = reactive<any[]>([]);
const mixin = useCounterMixin()
const { messageError ,date2Thai,showLoader,hideLoader} = mixin
const mixin = useCounterMixin();
const { messageError, date2Thai, showLoader, hideLoader } = mixin;
const router = useRouter();
const $q = useQuasar(); // noti quasar
const modal = ref<boolean>(false);
@ -201,7 +204,7 @@ const pagination = ref({
rowsPerPage: 10,
});
const type = ref<string>('employee')
const type = ref<string>("officer");
const visibleColumns = ref<string[]>(["no", "Date", "retireNumber"]); //
//
@ -236,55 +239,41 @@ const columns = ref<QTableProps["columns"]>([
]);
// ()
const currentYear = new Date().getFullYear();
const rows = ref<resMain[]>([]);
const tab = ref<any>("samun");
const tab = ref<any>("officer");
const visibleColumns2 = ref<string[]>(["no", "name", "retireNumber"]);
const getYear = async(type:string) =>{
const getYear = () => {
yearOptions.length = 0;
yearOptions.push(currentYear + 543);
console.log(yearOptions);
get(type.value, currentYear);
fiscalyear.value = currentYear + 543;
};
const get = async (type: string, year: string) => {
await http
.get(config.API.yearOptions())
.then((res)=>{
yearOptions.length = 0;
const response = res.data.result;
yearOptions.push(...response);
.get(config.API.retirement(type, year))
.then((res) => {
console.log(res);
console.log(yearOptions)
const maxNumber = yearOptions.reduce((max: any, e: any) => {
return e.id > max ? e.id : max;
}, "");
console.log(maxNumber)
get(type,maxNumber)
})
}
const get = async(type:string,year:number) =>{
await http
.get(config.API.retirement(type,year))
.then((res)=>{
rows.value =[]
let data = res.data.result
rows.value = data.map((items:resMain) =>({
id:items.id,
Date:date2Thai(items.createdAt),
year:items.year,
retireNumber:items.round,
total:items.total
}))
}).catch((e) => {
messageError($q, e);
rows.value = [];
let data = res.data.result;
rows.value = data.map((items: resMain) => ({
id: items.id,
Date: date2Thai(items.createdAt),
year: items.year,
retireNumber: items.round,
total: items.total,
}));
})
.catch((e) => {})
.finally(() => {
hideLoader()
hideLoader();
});
}
onMounted(()=>{
// get
getYear()
})
};
onMounted(() => {
getYear();
});
// 2
const columns2 = ref<QTableProps["columns"]>([
{
@ -355,34 +344,35 @@ const rows2 = ref<FormMainProbation2[]>([
},
]);
const clickDelete = (id: string) => {
$q.dialog({
title: "ยืนยันการลบข้อมูล",
message: "ต้องการลบข้อมูลนี้ใช่หรือไม่?",
cancel: {
flat: true,
color: "negative",
},
persistent: true,
})
.onOk(async () => {})
.onCancel(() => {})
.onDismiss(() => {});
};
// const clickDelete = (id: string) => {
// $q.dialog({
// title: "",
// message: "?",
// cancel: {
// flat: true,
// color: "negative",
// },
// persistent: true,
// })
// .onOk(async () => {})
// .onCancel(() => {})
// .onDismiss(() => {});
// };
const clickAdd = () => {
// modal.value = true;
router.push("/retirement/list");
router.push(`/retirement/list/${type.value}/${currentYear}`);
};
const clickClose = async () => {
modal.value = false;
};
const fiscalyear = ref(["2566"]);
const fiscalyear = ref<number>();
const fiscalyearOP = ref<any>([
{ id: 1, name: "ทั้งหมด" },
{ id: 2, name: "2565" },
{ id: 3, name: "2565" },
]);
//
const filterKeyword = ref<string>("");
const filterRef = ref<any>(null);
@ -405,9 +395,15 @@ const paginationLabel = (start: string, end: string, total: string) => {
if (paging.value == true) return " " + start + "-" + end + " ใน " + total;
else return start + "-" + end + " ใน " + total;
};
const nextPage = (val: any) => {
router.push(`/retirement/list/${val.no}`);
const nextPage = (prop: any) => {
console.log(prop.id);
router.push(`/retirement/list/${prop.id}`);
};
watch(type, () => {
get(type.value, currentYear);
});
</script>
<style lang="scss" scope>