Merge branch 'develop' into devTee

This commit is contained in:
STW_TTTY\stwtt 2024-06-19 10:48:37 +07:00
commit defcfd56da
10 changed files with 125 additions and 98 deletions

View file

@ -0,0 +1,3 @@
<template>
<div class="q-pa-md">สรปผลการประเม</div>
</template>

View file

@ -13,7 +13,7 @@ const store = useKpiDataStore();
const route = useRoute();
const router = useRouter();
const id = ref<string>(route.params.id as string)
const id = ref<string>(route.params.id as string);
const work = ref<boolean>(false);
const $q = useQuasar();
const mixin = useCounterMixin();
@ -29,35 +29,37 @@ const {
} = mixin;
const modal = defineModel<boolean>("modal", { required: true });
const isProbation = defineModel<boolean>("isProbation", { required: true });
function close() {
modal.value = false;
}
function getData() {
showLoader();
http
.get(config.API.orgPosition+`/${store.dataProfile.profileId}`)
.then((res) => {
const data = res.data.result.isProbation;
work.value = data;
})
.catch((e) => {
messageError($q, e);
})
.finally(() => {
hideLoader();
});
}
watch(
() => modal.value,
(n) => {
if (n == true) {
getData();
}
}
);
// function getData() {
// showLoader();
// http
// .get(config.API.orgPosition+`/${store.dataProfile.profileId}`)
// .then((res) => {
// const data = res.data.result.isProbation;
// work.value = data;
// })
// .catch((e) => {
// messageError($q, e);
// })
// .finally(() => {
// hideLoader();
// });
// }
// watch(
// () => modal.value,
// (n) => {
// if (n == true) {
// getData();
// }
// }
// );
</script>
<template>
<q-dialog persistent v-model="modal">
<q-card bordered style="min-width: 20vw">
@ -66,7 +68,9 @@ watch(
<q-card-section class="q-pa-sm">
<div class="row">
<div class="col-12 text-center bg-grey-1 q-pa-md rounded-borders">
<span class="text-weight-bold text-teal">{{work ? `อยู่ระหว่างทดลองงาน`:'พ้นจากการทดลองงาน'}}</span>
<span class="text-weight-bold text-teal">{{
isProbation ? `อยู่ระหว่างทดลองงาน` : "-"
}}</span>
</div>
</div>
</q-card-section>

View file

@ -4,7 +4,7 @@ import { useKpiDataStore } from "@/modules/08_KPI/store";
import { useRoute } from "vue-router";
import Assessment from "@/modules/08_KPI/components/Tab/01_Assessment.vue";
import Evaluator from "@/modules/08_KPI/components/Tab/02_Evaluator.vue";
import Result from "@/modules/08_KPI/components/Tab/04_Result.vue";
import CommanderAbove from "@/modules/08_KPI/components/Tab/03_CommanderAbove.vue";
import CommanderAboveOneStep from "@/modules/08_KPI/components/Tab/04_CommanderAboveOneStep.vue";
import File from "@/modules/08_KPI/components/Tab/05_File.vue";
@ -25,6 +25,10 @@ const itemsTab = ref<any>([
name: "3",
label: "รายงานผลสำเร็จของงาน",
},
{
name: "4",
label: "สรุปผลการประเมิน",
},
{
name: "5",
label: "ไฟล์เอกสาร",
@ -59,6 +63,7 @@ const splitterModel = ref<number>(12);
label="รายงานผลสำเร็จของงาน"
:disable="store.tabOpen < 3"
/>
<q-tab name="4" label="สรุปผลการประเมิน" />
<q-tab name="5" label="ไฟล์เอกสาร" />
</q-tabs>
</template>
@ -81,7 +86,7 @@ const splitterModel = ref<number>(12);
<Assessment v-if="store.tabMain === '1'" />
<Assessment v-if="store.tabMain === '2'" :type="'evaluator'" />
<Assessment v-if="store.tabMain === '3'" :type="'commander'" />
<Assessment v-if="store.tabMain === '4'" :type="'commanderHigh'" />
<Result v-if="store.tabMain === '4'" :type="'result'" />
<File v-if="store.tabMain === '5'" />
</q-tab-panel>
</q-tab-panels>

View file

@ -47,7 +47,7 @@ const visibleColumns = ref<string[]>(
"achievement",
"evaluationResults",
]
: ["includingName", "target", "weight"]
: ["includingName", "target", "point", "weight"]
);
const columns = ref<QTableProps["columns"]>([
{

View file

@ -108,7 +108,7 @@ const columns = ref<QTableProps["columns"]>([
const visibleColumns = ref<string[]>(
store.tabOpen === 3 && store.tabMain === "3"
? ["name", "level", "point", "weight", "summary"]
: ["name", "level", "weight"]
: ["name", "level", "point", "weight"]
);
const typeCompetency = ref<string>("");