Merge branch 'develop' into warunee-dev

This commit is contained in:
Warunee Tamkoo 2023-09-26 16:48:33 +07:00
commit 3acd86c45b
6 changed files with 491 additions and 145 deletions

View file

@ -226,7 +226,7 @@ const putformData = () => {
dialogConfirm($q, async () => { dialogConfirm($q, async () => {
await http await http
.post(config.API.createformCommader(assignId.value), data) .post(config.API.createformCommader(assignId.value), data)
.then((res: any) => { .then(() => {
success($q, "บันทึกสำเร็จ"); success($q, "บันทึกสำเร็จ");
router.push(`/probation/detail/${personalId.value}/${assignId.value}`); router.push(`/probation/detail/${personalId.value}/${assignId.value}`);
}) })

View file

@ -342,7 +342,7 @@ const putformData = () => {
dialogConfirm($q, async () => { dialogConfirm($q, async () => {
await http await http
.post(config.API.createformChairman(assignId.value), data) .post(config.API.createformChairman(assignId.value), data)
.then((res: any) => { .then(() => {
success($q, "บันทึกสำเร็จ"); success($q, "บันทึกสำเร็จ");
router.push(`/probation/detail/${personalId.value}/${assignId.value}`); router.push(`/probation/detail/${personalId.value}/${assignId.value}`);
}) })

View file

@ -9,7 +9,7 @@ import { useRoute, useRouter } from "vue-router";
import http from "@/plugins/http"; import http from "@/plugins/http";
import config from "@/app.config"; import config from "@/app.config";
import criterion from "@/modules/05_placement/components/Other/Criterion.vue" import criterion from "@/modules/05_placement/components/Other/Criterion.vue";
const $q = useQuasar(); const $q = useQuasar();
const route = useRoute(); const route = useRoute();
@ -57,7 +57,9 @@ const fecthFormdata = async (id: string) => {
person.value = res.data.data.person; person.value = res.data.data.person;
assign.value = res.data.data.assign; assign.value = res.data.data.assign;
option.value.push(res.data.data.director); option.value.push(res.data.data.director);
Autherise.value = res.data.data.director.name + ` (${res.data.data.director.PositionLineName}, ${res.data.data.director.PositionLevelName}, ${res.data.data.director.Oc})`; Autherise.value =
res.data.data.director.name +
` (${res.data.data.director.PositionLineName}, ${res.data.data.director.PositionLevelName}, ${res.data.data.director.Oc})`;
list1_1.value = res.data.data.assign_output; list1_1.value = res.data.data.assign_output;
res.data.data.assign_output.forEach((e: any) => { res.data.data.assign_output.forEach((e: any) => {
@ -75,11 +77,10 @@ const fecthFormdata = async (id: string) => {
})); }));
checkArray.value = list1_1.value.length; checkArray.value = list1_1.value.length;
}) })
.catch((e: any) => { }); .catch((e: any) => {});
}; };
const list1_1 = ref<any>([ const list1_1 = ref<any>([]);
]);
const list1_2 = [{ id: "", label: "" }]; const list1_2 = [{ id: "", label: "" }];
const list2_1 = probationStore.behavior_no1; const list2_1 = probationStore.behavior_no1;
@ -91,8 +92,7 @@ const option = ref<any>([]);
// part 1 // part 1
const evaluate_expenct_level = ref<any>([]); const evaluate_expenct_level = ref<any>([]);
const evaluate_ouptut = ref<any>([ const evaluate_ouptut = ref<any>([]);
]);
const knowledge_level = ref<number>(0); const knowledge_level = ref<number>(0);
const skill_level = ref<number>(0); const skill_level = ref<number>(0);
const competency_level = ref<number>(0); const competency_level = ref<number>(0);
@ -169,7 +169,7 @@ const savaForm = () => {
if ( if (
lengthevaluate_expenct_level.value !== lengthevaluate_expenct_level.value !==
evaluate_expenct_level.value.length || evaluate_expenct_level.value.length ||
lengthevaluate_ouptut.value !== evaluate_ouptut.value.length || lengthevaluate_ouptut.value !== evaluate_ouptut.value.length ||
knowledge_level.value === 0 || knowledge_level.value === 0 ||
skill_level.value === 0 || skill_level.value === 0 ||
@ -280,7 +280,7 @@ const putformData = () => {
const saveformdata = async (data: any) => { const saveformdata = async (data: any) => {
await http await http
.post(config.API.createformevaluate(assignId.value), data) .post(config.API.createformevaluate(assignId.value), data)
.then((res: any) => { .then(() => {
success($q, "บันทึกสำเร็จ"); success($q, "บันทึกสำเร็จ");
router.push(`/probation/detail/${personalId.value}/${assignId.value}`); router.push(`/probation/detail/${personalId.value}/${assignId.value}`);
}) })
@ -338,8 +338,19 @@ const getBordered = (i: boolean) => {
<template> <template>
<q-card class="my-card" flat bordered> <q-card class="my-card" flat bordered>
<q-toolbar> <q-toolbar>
<div class="text-h6 text-weight-medium text-dark col-12 row items-center q-py-md"> <div
<q-btn icon="mdi-arrow-left" unelevated round dense flat color="primary" class="q-mr-sm" @click="router.go(-1)" /> class="text-h6 text-weight-medium text-dark col-12 row items-center q-py-md"
>
<q-btn
icon="mdi-arrow-left"
unelevated
round
dense
flat
color="primary"
class="q-mr-sm"
@click="router.go(-1)"
/>
การทดลองปฏหนาทราชการของ {{ person.name }} การทดลองปฏหนาทราชการของ {{ person.name }}
</div> </div>
</q-toolbar> </q-toolbar>
@ -350,21 +361,30 @@ const getBordered = (i: boolean) => {
<div class="col-12 row"> <div class="col-12 row">
<div class="col-12 row text-top0"> <div class="col-12 row text-top0">
<q-icon name="mdi-label" color="grey-4" class="q-pr-sm" /> <q-icon name="mdi-label" color="grey-4" class="q-pr-sm" />
ทดลองปฏหนาทราชการ {{person.name}} ทดลองปฏหนาทราชการ {{ person.name }}
</div> </div>
<div class="col-12 q-pl-md q-pb-md"> <div class="col-12 q-pl-md q-pb-md">
<!-- <div class="col-12"><span class="text-top0 q-pl-sm">ตำแหน</span> {{ person.Position }}</div> --> <!-- <div class="col-12"><span class="text-top0 q-pl-sm">ตำแหน</span> {{ person.Position }}</div> -->
<div class="col-12"><span class="text-top0 q-pl-sm">ตำแหนงในสายงาน</span> {{ person.PositionLineName }}</div> <div class="col-12">
<div class="col-12"><span class="text-top0 q-pl-sm">ระด</span> {{ person.PositionLevelName }} </div> <span class="text-top0 q-pl-sm">ตำแหนงในสายงาน</span>
<div class="col-12"><span class="text-top0 q-pl-sm">งก</span> {{ person.Oc }}</div> {{ person.PositionLineName }}
</div>
<div class="col-12">
<span class="text-top0 q-pl-sm">ระด</span>
{{ person.PositionLevelName }}
</div>
<div class="col-12">
<span class="text-top0 q-pl-sm">งก</span> {{ person.Oc }}
</div>
</div> </div>
<div class="col-12 text-top0 row items-center"> <div class="col-12 text-top0 row items-center">
<q-icon name="mdi-label" color="grey-4" class="q-pr-sm" /> <q-icon name="mdi-label" color="grey-4" class="q-pr-sm" />
การทดลองปฎหนาทราชการ<span class="text-primary q-pr-sm">{{ การทดลองปฎหนาทราชการ<span class="text-primary q-pr-sm">{{
"ครั้งที่ " + assign.round_no "ครั้งที่ " + assign.round_no
}}</span> งแตนท }}</span>
งแตนท
<span class="text-black q-px-sm">{{ <span class="text-black q-px-sm">{{
date2Thai(assign.date_start) date2Thai(assign.date_start)
}}</span> }}</span>
@ -408,18 +428,29 @@ const getBordered = (i: boolean) => {
<div class="col-xs-12 col-sm-11 col-md-10 offset-md-1 text-top2"> <div class="col-xs-12 col-sm-11 col-md-10 offset-md-1 text-top2">
ผลผลตของงานทคาดหว ผลผลตของงานทคาดหว
</div> </div>
<q-card flat bordered :class="[ <q-card
'col-xs-12 col-sm-11 col-md-10 offset-md-1 q-pa-sm bg-grey-1', flat
getBordered(alerts[0].value), bordered
]"> :class="[
'col-xs-12 col-sm-11 col-md-10 offset-md-1 q-pa-sm bg-grey-1',
getBordered(alerts[0].value),
]"
>
<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 dense tag="label" v-ripple>
<q-item-section> <q-item-section>
<q-item-label>{{ list.output_desc }}</q-item-label> <q-item-label>{{ list.output_desc }}</q-item-label>
</q-item-section> </q-item-section>
<q-item-section side> <q-item-section side>
<q-rating v-model="evaluate_expenct_level[i].level" :val="list.id" max="5" size="sm" color="grey" <q-rating
:color-selected="ratingColors" label="ระดับการประเมินพฤติกรรม"> v-model="evaluate_expenct_level[i].level"
:val="list.id"
max="5"
size="sm"
color="grey"
:color-selected="ratingColors"
label="ระดับการประเมินพฤติกรรม"
>
<template v-slot:tip-1> <template v-slot:tip-1>
<q-tooltip>ำกวาความคาดหวงมาก (1)</q-tooltip> <q-tooltip>ำกวาความคาดหวงมาก (1)</q-tooltip>
</template> </template>
@ -446,20 +477,40 @@ const getBordered = (i: boolean) => {
<div class="col-xs-12 col-sm-11 col-md-10 offset-md-1 text-top2"> <div class="col-xs-12 col-sm-11 col-md-10 offset-md-1 text-top2">
ผลผลตของงานทเกดขนจร ผลผลตของงานทเกดขนจร
</div> </div>
<q-card flat bordered :class="[ <q-card
'col-xs-12 col-sm-11 col-md-10 offset-md-1 q-pa-sm bg-grey-1', flat
getBordered(alerts[1].value), bordered
]"> :class="[
'col-xs-12 col-sm-11 col-md-10 offset-md-1 q-pa-sm bg-grey-1',
getBordered(alerts[1].value),
]"
>
<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 v-if="i < checkArray"> <q-item dense tag="label" v-ripple v-if="i < checkArray">
<q-item-section> <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="evaluate_ouptut[i].text" lazy-rules autogrow <q-input
label="ผลผลิตของงานที่เกิดขึ้นจริง" hide-bottom-space :row="1" :rules="evaluate_ouptutRules" /> outlined
dense
v-model="evaluate_ouptut[i].text"
lazy-rules
autogrow
label="ผลผลิตของงานที่เกิดขึ้นจริง"
hide-bottom-space
:row="1"
:rules="evaluate_ouptutRules"
/>
</q-item-section> </q-item-section>
<q-item-section side> <q-item-section side>
<q-rating v-model="evaluate_ouptut[i].level" :val="list.id" max="5" size="sm" color="grey" <q-rating
:color-selected="ratingColors" label="ระดับการประเมินพฤติกรรม"> v-model="evaluate_ouptut[i].level"
:val="list.id"
max="5"
size="sm"
color="grey"
:color-selected="ratingColors"
label="ระดับการประเมินพฤติกรรม"
>
<template v-slot:tip-1> <template v-slot:tip-1>
<q-tooltip>ำกวาความคาดหวงมาก (1)</q-tooltip> <q-tooltip>ำกวาความคาดหวงมาก (1)</q-tooltip>
</template> </template>
@ -486,15 +537,27 @@ const getBordered = (i: boolean) => {
<div class="col-12 row"> <div class="col-12 row">
<q-card class="text-top0 col-xs-12 col-sm-11 q-pa-sm q-pl-sm"> <q-card class="text-top0 col-xs-12 col-sm-11 q-pa-sm q-pl-sm">
<q-list dense> <q-list dense>
<q-item dense tag="label" v-ripple :class="getBordered(alerts[2].value)"> <q-item
dense
tag="label"
v-ripple
:class="getBordered(alerts[2].value)"
>
<q-item-section> <q-item-section>
<q-item-label> <q-item-label>
<q-icon name="mdi-label" color="grey-4" class="q-pr-sm" /> <q-icon name="mdi-label" color="grey-4" class="q-pr-sm" />
1.2. ความรความสามารถ</q-item-label> 1.2. ความรความสามารถ</q-item-label
>
</q-item-section> </q-item-section>
<q-item-section side> <q-item-section side>
<q-rating v-model="knowledge_level" max="5" size="sm" color="grey" :color-selected="ratingColors" <q-rating
label="ระดับการประเมินพฤติกรรม"> v-model="knowledge_level"
max="5"
size="sm"
color="grey"
:color-selected="ratingColors"
label="ระดับการประเมินพฤติกรรม"
>
<template v-slot:tip-1> <template v-slot:tip-1>
<q-tooltip>ำกวาความคาดหวงมาก (1)</q-tooltip> <q-tooltip>ำกวาความคาดหวงมาก (1)</q-tooltip>
</template> </template>
@ -518,15 +581,27 @@ const getBordered = (i: boolean) => {
<q-card class="text-top0 col-xs-12 col-sm-11 q-pa-sm q-pl-sm"> <q-card class="text-top0 col-xs-12 col-sm-11 q-pa-sm q-pl-sm">
<q-list dense> <q-list dense>
<q-item dense tag="label" v-ripple :class="getBordered(alerts[3].value)"> <q-item
dense
tag="label"
v-ripple
:class="getBordered(alerts[3].value)"
>
<q-item-section> <q-item-section>
<q-item-label> <q-item-label>
<q-icon name="mdi-label" color="grey-4" class="q-pr-sm" /> <q-icon name="mdi-label" color="grey-4" class="q-pr-sm" />
1.3. กษะ</q-item-label> 1.3. กษะ</q-item-label
>
</q-item-section> </q-item-section>
<q-item-section side> <q-item-section side>
<q-rating v-model="skill_level" max="5" size="sm" color="grey" :color-selected="ratingColors" <q-rating
label="ระดับการประเมินพฤติกรรม"> v-model="skill_level"
max="5"
size="sm"
color="grey"
:color-selected="ratingColors"
label="ระดับการประเมินพฤติกรรม"
>
<template v-slot:tip-1> <template v-slot:tip-1>
<q-tooltip>ำกวาความคาดหวงมาก (1)</q-tooltip> <q-tooltip>ำกวาความคาดหวงมาก (1)</q-tooltip>
</template> </template>
@ -550,15 +625,27 @@ const getBordered = (i: boolean) => {
<q-card class="text-top0 col-xs-12 col-sm-11 q-pa-sm q-pl-sm"> <q-card class="text-top0 col-xs-12 col-sm-11 q-pa-sm q-pl-sm">
<q-list dense> <q-list dense>
<q-item dense tag="label" v-ripple :class="getBordered(alerts[4].value)"> <q-item
dense
tag="label"
v-ripple
:class="getBordered(alerts[4].value)"
>
<q-item-section> <q-item-section>
<q-item-label> <q-item-label>
<q-icon name="mdi-label" color="grey-4" class="q-pr-sm" /> <q-icon name="mdi-label" color="grey-4" class="q-pr-sm" />
1.4. สมมรถนะ</q-item-label> 1.4. สมมรถนะ</q-item-label
>
</q-item-section> </q-item-section>
<q-item-section side> <q-item-section side>
<q-rating v-model="competency_level" max="5" size="sm" color="grey" :color-selected="ratingColors" <q-rating
label="ระดับการประเมินพฤติกรรม"> v-model="competency_level"
max="5"
size="sm"
color="grey"
:color-selected="ratingColors"
label="ระดับการประเมินพฤติกรรม"
>
<template v-slot:tip-1> <template v-slot:tip-1>
<q-tooltip>ำกวาความคาดหวงมาก (1)</q-tooltip> <q-tooltip>ำกวาความคาดหวงมาก (1)</q-tooltip>
</template> </template>
@ -582,15 +669,27 @@ const getBordered = (i: boolean) => {
<q-card class="text-top0 col-xs-12 col-sm-11 q-pa-sm q-pl-sm"> <q-card class="text-top0 col-xs-12 col-sm-11 q-pa-sm q-pl-sm">
<q-list dense> <q-list dense>
<q-item dense tag="label" v-ripple :class="getBordered(alerts[5].value)"> <q-item
dense
tag="label"
v-ripple
:class="getBordered(alerts[5].value)"
>
<q-item-section> <q-item-section>
<q-item-label> <q-item-label>
<q-icon name="mdi-label" color="grey-4" class="q-pr-sm" /> <q-icon name="mdi-label" color="grey-4" class="q-pr-sm" />
1.5. ความสามารถในการเรยนรงาน</q-item-label> 1.5. ความสามารถในการเรยนรงาน</q-item-label
>
</q-item-section> </q-item-section>
<q-item-section side> <q-item-section side>
<q-rating v-model="learn_level" max="5" size="sm" color="grey" :color-selected="ratingColors" <q-rating
label="ระดับการประเมินพฤติกรรม"> v-model="learn_level"
max="5"
size="sm"
color="grey"
:color-selected="ratingColors"
label="ระดับการประเมินพฤติกรรม"
>
<template v-slot:tip-1> <template v-slot:tip-1>
<q-tooltip>ำกวาความคาดหวงมาก (1)</q-tooltip> <q-tooltip>ำกวาความคาดหวงมาก (1)</q-tooltip>
</template> </template>
@ -614,16 +713,28 @@ const getBordered = (i: boolean) => {
<q-card class="text-top0 col-xs-12 col-sm-11 q-pa-sm q-pl-sm"> <q-card class="text-top0 col-xs-12 col-sm-11 q-pa-sm q-pl-sm">
<q-list dense> <q-list dense>
<q-item dense tag="label" v-ripple :class="getBordered(alerts[6].value)"> <q-item
dense
tag="label"
v-ripple
:class="getBordered(alerts[6].value)"
>
<q-item-section> <q-item-section>
<q-item-label> <q-item-label>
<q-icon name="mdi-label" color="grey-4" class="q-pr-sm" /> <q-icon name="mdi-label" color="grey-4" class="q-pr-sm" />
1.6. 1.6.
ความสามารถในการปรบใชความรบงานในหนาท</q-item-label> ความสามารถในการปรบใชความรบงานในหนาท</q-item-label
>
</q-item-section> </q-item-section>
<q-item-section side> <q-item-section side>
<q-rating v-model="apply_level" max="5" size="sm" color="grey" :color-selected="ratingColors" <q-rating
label="ระดับการประเมินพฤติกรรม"> v-model="apply_level"
max="5"
size="sm"
color="grey"
:color-selected="ratingColors"
label="ระดับการประเมินพฤติกรรม"
>
<template v-slot:tip-1> <template v-slot:tip-1>
<q-tooltip>ำกวาความคาดหวงมาก (1)</q-tooltip> <q-tooltip>ำกวาความคาดหวงมาก (1)</q-tooltip>
</template> </template>
@ -647,15 +758,27 @@ const getBordered = (i: boolean) => {
<q-card class="text-top0 col-xs-12 col-sm-11 q-pa-sm q-pl-sm"> <q-card class="text-top0 col-xs-12 col-sm-11 q-pa-sm q-pl-sm">
<q-list dense> <q-list dense>
<q-item dense tag="label" v-ripple :class="getBordered(alerts[7].value)"> <q-item
dense
tag="label"
v-ripple
:class="getBordered(alerts[7].value)"
>
<q-item-section> <q-item-section>
<q-item-label> <q-item-label>
<q-icon name="mdi-label" color="grey-4" class="q-pr-sm" /> <q-icon name="mdi-label" color="grey-4" class="q-pr-sm" />
1.7. ความสำเรจของงานทไดบมอบหมาย</q-item-label> 1.7. ความสำเรจของงานทไดบมอบหมาย</q-item-label
>
</q-item-section> </q-item-section>
<q-item-section side> <q-item-section side>
<q-rating v-model="success_level" max="5" size="sm" color="grey" :color-selected="ratingColors" <q-rating
label="ระดับการประเมินพฤติกรรม"> v-model="success_level"
max="5"
size="sm"
color="grey"
:color-selected="ratingColors"
label="ระดับการประเมินพฤติกรรม"
>
<template v-slot:tip-1> <template v-slot:tip-1>
<q-tooltip>ำกวาความคาดหวงมาก (1)</q-tooltip> <q-tooltip>ำกวาความคาดหวงมาก (1)</q-tooltip>
</template> </template>
@ -684,30 +807,53 @@ const getBordered = (i: boolean) => {
<q-item-label> <q-item-label>
<q-icon name="mdi-label" color="grey-4" class="q-pr-sm" /> <q-icon name="mdi-label" color="grey-4" class="q-pr-sm" />
1.8 นๆ 1.8 นๆ
<q-checkbox class="q-ml-sm" dense v-model="etc" @click=" <q-checkbox
(achievement_other.text = ''), class="q-ml-sm"
(achievement_other.level = 0) dense
" /></q-item-label> v-model="etc"
@click="
(achievement_other.text = ''),
(achievement_other.level = 0)
"
/></q-item-label>
</q-item-section> </q-item-section>
</q-item> </q-item>
</q-list> </q-list>
</q-card> </q-card>
<q-card v-if="etc" class="text-top0 col-xs-12 col-sm-11 q-pa-sm q-mt-sm q-pl-lg"> <q-card
v-if="etc"
class="text-top0 col-xs-12 col-sm-11 q-pa-sm q-mt-sm q-pl-lg"
>
<q-list dense> <q-list dense>
<q-item dense tag="label" v-ripple> <q-item dense tag="label" v-ripple>
<q-item-section class="q-ml-md"> <q-item-section class="q-ml-md">
<q-item-label> <q-item-label>
<q-input v-model="achievement_other.text" label="กรอกอื่นๆ" dense lazy-rules autogrow <q-input
hide-bottom-space outlined class="bg-white" :rules="[ v-model="achievement_other.text"
label="กรอกอื่นๆ"
dense
lazy-rules
autogrow
hide-bottom-space
outlined
class="bg-white"
:rules="[
(val) => (val) =>
(val && val.length > 0) || 'กรุณากรอกข้อความ', (val && val.length > 0) || 'กรุณากรอกข้อความ',
]" /> ]"
/>
</q-item-label> </q-item-label>
</q-item-section> </q-item-section>
<q-item-section side> <q-item-section side>
<q-rating v-model="achievement_other.level" max="5" size="sm" color="grey" <q-rating
:color-selected="ratingColors" label="ระดับการประเมินพฤติกรรม"> v-model="achievement_other.level"
max="5"
size="sm"
color="grey"
:color-selected="ratingColors"
label="ระดับการประเมินพฤติกรรม"
>
<template v-slot:tip-1> <template v-slot:tip-1>
<q-tooltip>ำกวาความคาดหวงมาก (1)</q-tooltip> <q-tooltip>ำกวาความคาดหวงมาก (1)</q-tooltip>
</template> </template>
@ -736,17 +882,35 @@ const getBordered = (i: boolean) => {
<q-icon name="mdi-label" color="grey-4" class="q-pr-sm" /> <q-icon name="mdi-label" color="grey-4" class="q-pr-sm" />
ดเด (ไมเก 5 บรรท) ดเด (ไมเก 5 บรรท)
</div> </div>
<q-input outlined dense v-model="achievement_strength_desc" <q-input
class="col-xs-12 col-sm-11 col-md-10 offset-md-1" lazy-rules type="textarea" label="กรอกจุดเด่น" outlined
hide-bottom-space :row="5" :rules="achievement_strengthRules" ref="achievement_strengthRef" /> dense
v-model="achievement_strength_desc"
class="col-xs-12 col-sm-11 col-md-10 offset-md-1"
lazy-rules
type="textarea"
label="กรอกจุดเด่น"
hide-bottom-space
:row="5"
:rules="achievement_strengthRules"
ref="achievement_strengthRef"
/>
</div> </div>
<div class="col-12 row"> <div class="col-12 row">
<div class="col-12 text-top0 row items-center q-pl-lg"> <div class="col-12 text-top0 row items-center q-pl-lg">
<q-icon name="mdi-label" color="grey-4" class="q-pr-sm" /> <q-icon name="mdi-label" color="grey-4" class="q-pr-sm" />
งทควรปรบปร (ไมเก 5 บรรท) งทควรปรบปร (ไมเก 5 บรรท)
</div> </div>
<q-input outlined dense v-model="achievement_improve_desc" class="col-xs-12 col-sm-11 col-md-10 offset-md-1" <q-input
type="textarea" hide-bottom-space label="กรอกสิ่งที่ควรปรับปรุง" :row="5" /> outlined
dense
v-model="achievement_improve_desc"
class="col-xs-12 col-sm-11 col-md-10 offset-md-1"
type="textarea"
hide-bottom-space
label="กรอกสิ่งที่ควรปรับปรุง"
:row="5"
/>
</div> </div>
</div> </div>
@ -763,29 +927,44 @@ const getBordered = (i: boolean) => {
2.1 ความประพฤต 2.1 ความประพฤต
</div> </div>
<q-card flat bordered :class="[ <q-card
'col-xs-12 col-sm-11 col-md-10 offset-md-1 q-pa-sm bg-grey-1', flat
getBordered(alerts[8].value), bordered
]"> :class="[
'col-xs-12 col-sm-11 col-md-10 offset-md-1 q-pa-sm bg-grey-1',
getBordered(alerts[8].value),
]"
>
<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 dense tag="label" v-ripple>
<q-item-section> <q-item-section>
<q-item-label>{{ list.label }}</q-item-label> <q-item-label>{{ list.label }}</q-item-label>
</q-item-section> </q-item-section>
<q-item-section side> <q-item-section side>
<q-rating v-model="conduct_level[i]" :val="list.id" max="5" size="sm" color="grey" <q-rating
:color-selected="ratingColors" label="ระดับการประเมินพฤติกรรม"> v-model="conduct_level[i]"
:val="list.id"
max="5"
size="sm"
color="grey"
:color-selected="ratingColors"
label="ระดับการประเมินพฤติกรรม"
>
<template v-slot:tip-1> <template v-slot:tip-1>
<q-tooltip>ำกวาความคาดหวงมาก (1)</q-tooltip> <q-tooltip>ำกวาความคาดหวงมาก (1)</q-tooltip>
</template> </template>
<template v-slot:tip-2> <template v-slot:tip-2>
<q-tooltip>ำกวาความคาดหวงคอนขางมาก (2)</q-tooltip> <q-tooltip
>ำกวาความคาดหวงคอนขางมาก (2)</q-tooltip
>
</template> </template>
<template v-slot:tip-3> <template v-slot:tip-3>
<q-tooltip>เปนไปตามความคาดหว (3)</q-tooltip> <q-tooltip>เปนไปตามความคาดหว (3)</q-tooltip>
</template> </template>
<template v-slot:tip-4> <template v-slot:tip-4>
<q-tooltip>งวาความคาดหวงคอนขางมาก (4)</q-tooltip> <q-tooltip
>งวาความคาดหวงคอนขางมาก (4)</q-tooltip
>
</template> </template>
<template v-slot:tip-5> <template v-slot:tip-5>
<q-tooltip>งกวาความคาดหวงมาก (5)</q-tooltip> <q-tooltip>งกวาความคาดหวงมาก (5)</q-tooltip>
@ -802,29 +981,44 @@ const getBordered = (i: boolean) => {
<q-icon name="mdi-label" color="grey-4" class="q-pr-sm" /> <q-icon name="mdi-label" color="grey-4" class="q-pr-sm" />
2.2 ความมณธรรมจรยธรรม 2.2 ความมณธรรมจรยธรรม
</div> </div>
<q-card flat bordered :class="[ <q-card
'col-xs-12 col-sm-11 col-md-10 offset-md-1 q-pa-sm bg-grey-1', flat
getBordered(alerts[9].value), bordered
]"> :class="[
'col-xs-12 col-sm-11 col-md-10 offset-md-1 q-pa-sm bg-grey-1',
getBordered(alerts[9].value),
]"
>
<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 dense tag="label" v-ripple>
<q-item-section> <q-item-section>
<q-item-label>{{ list.label }}</q-item-label> <q-item-label>{{ list.label }}</q-item-label>
</q-item-section> </q-item-section>
<q-item-section side> <q-item-section side>
<q-rating v-model="moral_level[i]" :val="list.id" max="5" size="sm" color="grey" <q-rating
:color-selected="ratingColors" label="ระดับการประเมินพฤติกรรม"> v-model="moral_level[i]"
:val="list.id"
max="5"
size="sm"
color="grey"
:color-selected="ratingColors"
label="ระดับการประเมินพฤติกรรม"
>
<template v-slot:tip-1> <template v-slot:tip-1>
<q-tooltip>ำกวาความคาดหวงมาก (1)</q-tooltip> <q-tooltip>ำกวาความคาดหวงมาก (1)</q-tooltip>
</template> </template>
<template v-slot:tip-2> <template v-slot:tip-2>
<q-tooltip>ำกวาความคาดหวงคอนขางมาก (2)</q-tooltip> <q-tooltip
>ำกวาความคาดหวงคอนขางมาก (2)</q-tooltip
>
</template> </template>
<template v-slot:tip-3> <template v-slot:tip-3>
<q-tooltip>เปนไปตามความคาดหว (3)</q-tooltip> <q-tooltip>เปนไปตามความคาดหว (3)</q-tooltip>
</template> </template>
<template v-slot:tip-4> <template v-slot:tip-4>
<q-tooltip>งวาความคาดหวงคอนขางมาก (4)</q-tooltip> <q-tooltip
>งวาความคาดหวงคอนขางมาก (4)</q-tooltip
>
</template> </template>
<template v-slot:tip-5> <template v-slot:tip-5>
<q-tooltip>งกวาความคาดหวงมาก (5)</q-tooltip> <q-tooltip>งกวาความคาดหวงมาก (5)</q-tooltip>
@ -841,29 +1035,44 @@ const getBordered = (i: boolean) => {
<q-icon name="mdi-label" color="grey-4" class="q-pr-sm" /> <q-icon name="mdi-label" color="grey-4" class="q-pr-sm" />
2.3 การรกษาว 2.3 การรกษาว
</div> </div>
<q-card flat bordered :class="[ <q-card
'col-xs-12 col-sm-11 col-md-10 offset-md-1 q-pa-sm bg-grey-1', flat
getBordered(alerts[10].value), bordered
]"> :class="[
'col-xs-12 col-sm-11 col-md-10 offset-md-1 q-pa-sm bg-grey-1',
getBordered(alerts[10].value),
]"
>
<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 dense tag="label" v-ripple>
<q-item-section> <q-item-section>
<q-item-label>{{ list.label }}</q-item-label> <q-item-label>{{ list.label }}</q-item-label>
</q-item-section> </q-item-section>
<q-item-section side> <q-item-section side>
<q-rating v-model="discipline_level[i]" :val="list.id" max="5" size="sm" color="grey" <q-rating
:color-selected="ratingColors" label="ระดับการประเมินพฤติกรรม"> v-model="discipline_level[i]"
:val="list.id"
max="5"
size="sm"
color="grey"
:color-selected="ratingColors"
label="ระดับการประเมินพฤติกรรม"
>
<template v-slot:tip-1> <template v-slot:tip-1>
<q-tooltip>ำกวาความคาดหวงมาก (1)</q-tooltip> <q-tooltip>ำกวาความคาดหวงมาก (1)</q-tooltip>
</template> </template>
<template v-slot:tip-2> <template v-slot:tip-2>
<q-tooltip>ำกวาความคาดหวงคอนขางมาก (2)</q-tooltip> <q-tooltip
>ำกวาความคาดหวงคอนขางมาก (2)</q-tooltip
>
</template> </template>
<template v-slot:tip-3> <template v-slot:tip-3>
<q-tooltip>เปนไปตามความคาดหว (3)</q-tooltip> <q-tooltip>เปนไปตามความคาดหว (3)</q-tooltip>
</template> </template>
<template v-slot:tip-4> <template v-slot:tip-4>
<q-tooltip>งวาความคาดหวงคอนขางมาก (4)</q-tooltip> <q-tooltip
>งวาความคาดหวงคอนขางมาก (4)</q-tooltip
>
</template> </template>
<template v-slot:tip-5> <template v-slot:tip-5>
<q-tooltip>งกวาความคาดหวงมาก (5)</q-tooltip> <q-tooltip>งกวาความคาดหวงมาก (5)</q-tooltip>
@ -879,36 +1088,65 @@ const getBordered = (i: boolean) => {
<div class="col-12 text-top0 row items-center q-pl-lg"> <div class="col-12 text-top0 row items-center q-pl-lg">
<q-icon name="mdi-label" color="grey-4" class="q-pr-sm" /> <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="etc2" @click=" <q-checkbox
(behavio_orther.text = ''), (behavio_orther.level = 0) class="q-ml-sm"
" /> dense
v-model="etc2"
@click="
(behavio_orther.text = ''), (behavio_orther.level = 0)
"
/>
</div> </div>
<q-card v-if="etc2" 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="etc2"
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-list dense>
<q-item dense tag="label" v-ripple> <q-item dense tag="label" v-ripple>
<q-item-section> <q-item-section>
<q-item-label> <q-item-label>
<q-input v-model="behavio_orther.text" label="กรอกอื่นๆ" dense lazy-rules autogrow <q-input
hide-bottom-space outlined class="bg-white" :rules="[ v-model="behavio_orther.text"
label="กรอกอื่นๆ"
dense
lazy-rules
autogrow
hide-bottom-space
outlined
class="bg-white"
:rules="[
(val) => (val) =>
(val && val.length > 0) || 'กรุณากรอกข้อความ', (val && val.length > 0) || 'กรุณากรอกข้อความ',
]" /> ]"
/>
</q-item-label> </q-item-label>
</q-item-section> </q-item-section>
<q-item-section side> <q-item-section side>
<q-rating v-model="behavio_orther.level" max="5" size="sm" color="grey" <q-rating
:color-selected="ratingColors" label="ระดับการประเมินพฤติกรรม"> v-model="behavio_orther.level"
max="5"
size="sm"
color="grey"
:color-selected="ratingColors"
label="ระดับการประเมินพฤติกรรม"
>
<template v-slot:tip-1> <template v-slot:tip-1>
<q-tooltip>ำกวาความคาดหวงมาก (1)</q-tooltip> <q-tooltip>ำกวาความคาดหวงมาก (1)</q-tooltip>
</template> </template>
<template v-slot:tip-2> <template v-slot:tip-2>
<q-tooltip>ำกวาความคาดหวงคอนขางมาก (2)</q-tooltip> <q-tooltip
>ำกวาความคาดหวงคอนขางมาก (2)</q-tooltip
>
</template> </template>
<template v-slot:tip-3> <template v-slot:tip-3>
<q-tooltip>เปนไปตามความคาดหว (3)</q-tooltip> <q-tooltip>เปนไปตามความคาดหว (3)</q-tooltip>
</template> </template>
<template v-slot:tip-4> <template v-slot:tip-4>
<q-tooltip>งวาความคาดหวงคอนขางมาก (4)</q-tooltip> <q-tooltip
>งวาความคาดหวงคอนขางมาก (4)</q-tooltip
>
</template> </template>
<template v-slot:tip-5> <template v-slot:tip-5>
<q-tooltip>งกวาความคาดหวงมาก (5)</q-tooltip> <q-tooltip>งกวาความคาดหวงมาก (5)</q-tooltip>
@ -926,17 +1164,35 @@ const getBordered = (i: boolean) => {
<q-icon name="mdi-label" color="grey-4" class="q-pr-sm" /> <q-icon name="mdi-label" color="grey-4" class="q-pr-sm" />
ดเด (ไมเก 5 บรรท) ดเด (ไมเก 5 บรรท)
</div> </div>
<q-input outlined dense v-model="behavior_strength_desc" class="col-xs-12 col-sm-11 col-md-10 offset-md-1" <q-input
lazy-rules type="textarea" label="กรอกจุดเด่น" hide-bottom-space :row="5" :rules="behavio_strengthRules" outlined
ref="behavio_strengthRef" /> dense
v-model="behavior_strength_desc"
class="col-xs-12 col-sm-11 col-md-10 offset-md-1"
lazy-rules
type="textarea"
label="กรอกจุดเด่น"
hide-bottom-space
:row="5"
:rules="behavio_strengthRules"
ref="behavio_strengthRef"
/>
</div> </div>
<div class="col-12 row"> <div class="col-12 row">
<div class="col-12 text-top0 row items-center q-pl-lg"> <div class="col-12 text-top0 row items-center q-pl-lg">
<q-icon name="mdi-label" color="grey-4" class="q-pr-sm" /> <q-icon name="mdi-label" color="grey-4" class="q-pr-sm" />
งทควรปรบปร (ไมเก 5 บรรท) งทควรปรบปร (ไมเก 5 บรรท)
</div> </div>
<q-input outlined dense v-model="behavior_improve_desc" class="col-xs-12 col-sm-11 col-md-10 offset-md-1" <q-input
type="textarea" hide-bottom-space label="กรอกสิ่งที่ควรปรับปรุง" :row="5" /> outlined
dense
v-model="behavior_improve_desc"
class="col-xs-12 col-sm-11 col-md-10 offset-md-1"
type="textarea"
hide-bottom-space
label="กรอกสิ่งที่ควรปรับปรุง"
:row="5"
/>
</div> </div>
</div> </div>
</div> </div>
@ -949,61 +1205,122 @@ const getBordered = (i: boolean) => {
<q-avatar class="bg-grey-2 q-mr-sm" size="28px">3</q-avatar> <q-avatar class="bg-grey-2 q-mr-sm" size="28px">3</q-avatar>
การพฒนาผทดลองปฏหนาทราชการ การพฒนาผทดลองปฏหนาทราชการ
</div> </div>
<q-card flat bordered class="col-xs-12 col-sm-11 col-md-11 q-pa-sm bg-grey-1"> <q-card
flat
bordered
class="col-xs-12 col-sm-11 col-md-11 q-pa-sm bg-grey-1"
>
<q-list dense> <q-list dense>
<q-item dense tag="label" v-ripple :class="getBordered(alerts[11].value)"> <q-item
dense
tag="label"
v-ripple
:class="getBordered(alerts[11].value)"
>
<q-item-section> <q-item-section>
<q-item-label>1. การปฐมนเทศ</q-item-label> <q-item-label>1. การปฐมนเทศ</q-item-label>
</q-item-section> </q-item-section>
<q-item-section side> <q-item-section side>
<div class="row"> <div class="row">
<q-radio checked-icon="task_alt" unchecked-icon="panorama_fish_eye" v-model="orientation" val="1" <q-radio
label="ดำเนินการเเล้ว" /> checked-icon="task_alt"
<q-radio checked-icon="task_alt" unchecked-icon="panorama_fish_eye" v-model="orientation" val="0" unchecked-icon="panorama_fish_eye"
label=" ยังไม่ได้ดำเนินการ" /> v-model="orientation"
val="1"
label="ดำเนินการเเล้ว"
/>
<q-radio
checked-icon="task_alt"
unchecked-icon="panorama_fish_eye"
v-model="orientation"
val="0"
label=" ยังไม่ได้ดำเนินการ"
/>
</div> </div>
</q-item-section> </q-item-section>
</q-item> </q-item>
<q-separator class="q-my-xs" /> <q-separator class="q-my-xs" />
<q-item dense tag="label" v-ripple :class="getBordered(alerts[12].value)"> <q-item
dense
tag="label"
v-ripple
:class="getBordered(alerts[12].value)"
>
<q-item-section> <q-item-section>
<q-item-label>2. การเรยนรวยตนเอง</q-item-label> <q-item-label>2. การเรยนรวยตนเอง</q-item-label>
</q-item-section> </q-item-section>
<q-item-section side> <q-item-section side>
<div class="row"> <div class="row">
<q-radio checked-icon="task_alt" unchecked-icon="panorama_fish_eye" v-model="self_learning" <q-radio
val="1" label="ดำเนินการเเล้ว" /> checked-icon="task_alt"
<q-radio checked-icon="task_alt" unchecked-icon="panorama_fish_eye" v-model="self_learning" unchecked-icon="panorama_fish_eye"
val="0" label=" ยังไม่ได้ดำเนินการ" /> v-model="self_learning"
val="1"
label="ดำเนินการเเล้ว"
/>
<q-radio
checked-icon="task_alt"
unchecked-icon="panorama_fish_eye"
v-model="self_learning"
val="0"
label=" ยังไม่ได้ดำเนินการ"
/>
</div> </div>
</q-item-section> </q-item-section>
</q-item> </q-item>
<q-separator class="q-my-xs" /> <q-separator class="q-my-xs" />
<q-item dense tag="label" v-ripple :class="getBordered(alerts[13].value)"> <q-item
dense
tag="label"
v-ripple
:class="getBordered(alerts[13].value)"
>
<q-item-section> <q-item-section>
<q-item-label>3. การอบรมสมนารวมก</q-item-label> <q-item-label>3. การอบรมสมนารวมก</q-item-label>
</q-item-section> </q-item-section>
<q-item-section side> <q-item-section side>
<div class="row"> <div class="row">
<q-radio checked-icon="task_alt" unchecked-icon="panorama_fish_eye" v-model="training_seminar" <q-radio
val="1" label="ดำเนินการเเล้ว" /> checked-icon="task_alt"
<q-radio checked-icon="task_alt" unchecked-icon="panorama_fish_eye" v-model="training_seminar" unchecked-icon="panorama_fish_eye"
val="0" label=" ยังไม่ได้ดำเนินการ" /> v-model="training_seminar"
val="1"
label="ดำเนินการเเล้ว"
/>
<q-radio
checked-icon="task_alt"
unchecked-icon="panorama_fish_eye"
v-model="training_seminar"
val="0"
label=" ยังไม่ได้ดำเนินการ"
/>
</div> </div>
</q-item-section> </q-item-section>
</q-item> </q-item>
<q-separator class="q-my-xs" /> <q-separator class="q-my-xs" />
<q-item dense tag="label" v-ripple> <q-item dense tag="label" v-ripple>
<q-item-section> <q-item-section>
<q-item-label>4. การอบรมอ ตามทหนวยงานกำหนด <q-item-label
(าม)</q-item-label> >4. การอบรมอ ตามทหนวยงานกำหนด
(าม)</q-item-label
>
</q-item-section> </q-item-section>
<q-item-section side> <q-item-section side>
<div class="row"> <div class="row">
<q-radio checked-icon="task_alt" unchecked-icon="panorama_fish_eye" v-model="other_training" <q-radio
val="1" label="ดำเนินการเเล้ว" /> checked-icon="task_alt"
<q-radio checked-icon="task_alt" unchecked-icon="panorama_fish_eye" v-model="other_training" unchecked-icon="panorama_fish_eye"
val="0" label=" ยังไม่ได้ดำเนินการ" /> v-model="other_training"
val="1"
label="ดำเนินการเเล้ว"
/>
<q-radio
checked-icon="task_alt"
unchecked-icon="panorama_fish_eye"
v-model="other_training"
val="0"
label=" ยังไม่ได้ดำเนินการ"
/>
</div> </div>
</q-item-section> </q-item-section>
</q-item> </q-item>
@ -1020,11 +1337,26 @@ const getBordered = (i: boolean) => {
งคบบญชา/มอบหมายงาน งคบบญชา/มอบหมายงาน
</div> </div>
<div class="col-12 row q-col-gutter-md"> <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
label="ผู้บังคับบัญชา" option-label="name" disable /> class="col-xs-12 col-sm-8"
dense
v-model="Autherise"
outlined
:options="option"
label="ผู้บังคับบัญชา"
option-label="name"
disable
/>
<div class="col-xs-12 col-sm-4"> <div class="col-xs-12 col-sm-4">
<datepicker menu-class-name="modalfix" v-model="dateAutherise" :locale="'th'" autoApply borderless <datepicker
:enableTimePicker="false" week-start="0"> menu-class-name="modalfix"
v-model="dateAutherise"
:locale="'th'"
autoApply
borderless
:enableTimePicker="false"
week-start="0"
>
<template #year="{ year }"> <template #year="{ year }">
{{ year + 543 }} {{ year + 543 }}
</template> </template>
@ -1032,12 +1364,24 @@ const getBordered = (i: boolean) => {
{{ parseInt(value + 543) }} {{ parseInt(value + 543) }}
</template> </template>
<template #trigger> <template #trigger>
<q-input outlined dense class="full-width datepicker col-3" :model-value="dateAutherise != null <q-input
? date2Thai(dateAutherise) outlined
: null dense
" :label="`${'ลงวันที่'}`" :rules="[(val) => !!val || `${'กรุณาเลือกลงวันที่'}`]"> class="full-width datepicker col-3"
:model-value="
dateAutherise != null
? date2Thai(dateAutherise)
: null
"
:label="`${'ลงวันที่'}`"
:rules="[(val) => !!val || `${'กรุณาเลือกลงวันที่'}`]"
>
<template v-slot:prepend> <template v-slot:prepend>
<q-icon name="event" class="cursor-pointer" style="color: var(--q-primary)"> <q-icon
name="event"
class="cursor-pointer"
style="color: var(--q-primary)"
>
</q-icon> </q-icon>
</template> </template>
</q-input> </q-input>

View file

@ -284,7 +284,7 @@ const putformData = () => {
const saveformdata = async (data: any) => { const saveformdata = async (data: any) => {
await http await http
.post(config.API.formevaluateCommander(assignId.value), data) .post(config.API.formevaluateCommander(assignId.value), data)
.then((res: any) => { .then(() => {
success($q, "บันทึกสำเร็จ"); success($q, "บันทึกสำเร็จ");
router.push(`/probation/detail/${personalId.value}/${assignId.value}`); router.push(`/probation/detail/${personalId.value}/${assignId.value}`);
}) })

View file

@ -52,7 +52,9 @@ const activeTab = ref<string>("");
const personalId = ref<string>(route.params.personalId.toString()); const personalId = ref<string>(route.params.personalId.toString());
onMounted(() => { onMounted(() => {
activeTab.value = DataStore.mainTab; if (DataStore.mainTab) {
activeTab.value = DataStore.mainTab;
} else activeTab.value = "tab1";
}); });
const changeTab = (tab: string) => { const changeTab = (tab: string) => {
DataStore.mainTab = tab; DataStore.mainTab = tab;

View file

@ -5,7 +5,7 @@ export const useProbationDataStore = defineStore("probationStore", () => {
const assign = ref<any>([]) const assign = ref<any>([])
const evaluate = ref<any>([]) const evaluate = ref<any>([])
const tabs = ref<any>([]); const tabs = ref<any>([]);
const mainTab = ref<string>('tab1') const mainTab = ref<string>('')
const assignOutput = ref<any>([]) const assignOutput = ref<any>([])
const director = ref<any>([]) const director = ref<any>([])