KPI
This commit is contained in:
parent
82b6f07897
commit
74bd72c70c
9 changed files with 123 additions and 75 deletions
|
|
@ -396,9 +396,9 @@ onMounted(() => {
|
|||
bordered
|
||||
class="q-mt-md"
|
||||
v-if="
|
||||
store.rolePerson == 'COMMANDER' &&
|
||||
evaluatorComment !== null &&
|
||||
store.dataEvaluation.commanderId !== null
|
||||
store.dataEvaluation.commanderId !== null &&
|
||||
store.dataEvaluation.evaluationStatus !== 'SUMMARY'
|
||||
"
|
||||
>
|
||||
<q-form greedy @submit.prevent @validation-success="onSubmitCommander">
|
||||
|
|
@ -422,7 +422,12 @@ onMounted(() => {
|
|||
'SUMMARY_COMMANDER'
|
||||
"
|
||||
label="เห็นด้วยกับผลการประเมิน"
|
||||
@click="resetCommander()"
|
||||
@click="
|
||||
store.dataEvaluation.evaluationStatus !==
|
||||
'SUMMARY_COMMANDER'
|
||||
? ''
|
||||
: resetCommander()
|
||||
"
|
||||
/>
|
||||
<q-radio
|
||||
v-model="superiorCommentCheck"
|
||||
|
|
@ -457,11 +462,17 @@ onMounted(() => {
|
|||
</div>
|
||||
</q-card-section>
|
||||
<q-separator
|
||||
v-if="store.dataEvaluation.evaluationStatus == 'SUMMARY_COMMANDER'"
|
||||
v-if="
|
||||
store.dataEvaluation.evaluationStatus == 'SUMMARY_COMMANDER' &&
|
||||
store.rolePerson === 'COMMANDER'
|
||||
"
|
||||
/>
|
||||
<q-card-actions
|
||||
align="right"
|
||||
v-if="store.dataEvaluation.evaluationStatus == 'SUMMARY_COMMANDER'"
|
||||
v-if="
|
||||
store.dataEvaluation.evaluationStatus == 'SUMMARY_COMMANDER' &&
|
||||
store.rolePerson === 'COMMANDER'
|
||||
"
|
||||
>
|
||||
<q-btn label="บันทึก" color="secondary" type="submit"
|
||||
><q-tooltip>บันทึกข้อมูล</q-tooltip></q-btn
|
||||
|
|
@ -474,8 +485,8 @@ onMounted(() => {
|
|||
bordered
|
||||
class="q-mt-md"
|
||||
v-if="
|
||||
store.rolePerson == 'COMMANDERHIGH' &&
|
||||
superiorComment !== '' &&
|
||||
store.dataEvaluation.evaluationStatus !== 'SUMMARY' &&
|
||||
store.dataEvaluation.evaluationStatus !== 'SUMMARY_COMMANDER' &&
|
||||
store.dataEvaluation.commanderHighId !== null
|
||||
"
|
||||
>
|
||||
|
|
@ -504,7 +515,12 @@ onMounted(() => {
|
|||
unchecked-icon="panorama_fish_eye"
|
||||
val="true"
|
||||
label="เห็นด้วยกับผลการประเมิน"
|
||||
@click="resetCommanderHigh()"
|
||||
@click="
|
||||
store.dataEvaluation.evaluationStatus !==
|
||||
'SUMMARY_COMMANDER_HIGH'
|
||||
? ''
|
||||
: resetCommanderHigh()
|
||||
"
|
||||
/>
|
||||
<q-radio
|
||||
:disable="
|
||||
|
|
|
|||
|
|
@ -556,8 +556,8 @@ const title = computed(() => {
|
|||
|
||||
<q-card bordered flat class="q-mt-sm no-shadow bg-white col-12">
|
||||
<div class="row q-px-md q-py-sm items-center bg-grey-1">
|
||||
<div class="col-4">ลำดับ/รหัสตัวชี้วัด</div>
|
||||
<div class="col-4">ชื่อตัวชี้วัด</div>
|
||||
<div class="col-5">ลำดับ/รหัสตัวชี้วัด</div>
|
||||
<div class="col-7">ชื่อตัวชี้วัด</div>
|
||||
</div>
|
||||
<q-separator />
|
||||
|
||||
|
|
@ -574,11 +574,11 @@ const title = computed(() => {
|
|||
@click="clickList(item.id)"
|
||||
>
|
||||
<q-item-section class="q-pa-none">
|
||||
<div class="row items-center" style="height: 50px">
|
||||
<div class="col-4">
|
||||
<div class="row items-center full-width ">
|
||||
<div class="col-5">
|
||||
{{ item.including }}
|
||||
</div>
|
||||
<div class="col-4">
|
||||
<div class="col-7">
|
||||
{{ item.includingName }}
|
||||
</div>
|
||||
</div>
|
||||
|
|
@ -964,6 +964,7 @@ const title = computed(() => {
|
|||
.my-menu-link {
|
||||
background: #ebf9f7 !important;
|
||||
color: #1bb19ab8 !important;
|
||||
border: 0;
|
||||
}
|
||||
.no-shadow {
|
||||
box-shadow: none !important;
|
||||
|
|
|
|||
|
|
@ -277,12 +277,22 @@ watch(
|
|||
<q-dialog v-model="modal" persistent>
|
||||
<q-card class="col-12" style="width: 85%">
|
||||
<q-form greedy @submit.prevent @validation-success="onSubmit">
|
||||
<DialogHeader :tittle="`เพิ่มสมรรถนะ`" :close="closeDialog" />
|
||||
<DialogHeader
|
||||
:tittle="
|
||||
competencyType == 'HEAD' || competencyType == 'GROUP'
|
||||
? `รายละเอียดสมรรถนะ`
|
||||
: `เพิ่มสมรรถนะ`
|
||||
"
|
||||
:close="closeDialog"
|
||||
/>
|
||||
<q-separator />
|
||||
|
||||
<q-card-section class="q-pa-none scroll" style="max-height: 80vh">
|
||||
<div class="row">
|
||||
<div class="bg-grey-1 q-pa-md col-3 row lineRight">
|
||||
<div
|
||||
v-if="competencyType != 'HEAD' && competencyType != 'GROUP'"
|
||||
class="bg-grey-1 q-pa-md col-xs-12 col-md-3 row lineRight"
|
||||
>
|
||||
<div class="col-12 q-col-gutter-sm fit">
|
||||
<div class="col-12">
|
||||
<q-select
|
||||
|
|
@ -362,7 +372,13 @@ watch(
|
|||
</div>
|
||||
</div>
|
||||
|
||||
<div class="col-9 q-pa-md q-col-gutter-sm">
|
||||
<div
|
||||
:class="
|
||||
competencyType == 'HEAD' || competencyType == 'GROUP'
|
||||
? `col-xs-12 col-md-12 q-pa-md q-col-gutter-sm`
|
||||
: `col-xs-12 col-md-9 q-pa-md q-col-gutter-sm`
|
||||
"
|
||||
>
|
||||
<span class="text-body2 text-weight-medium"
|
||||
>รายละเอียดสมรรถนะ</span
|
||||
>
|
||||
|
|
|
|||
|
|
@ -655,6 +655,7 @@ watch(
|
|||
.my-menu-link {
|
||||
background: #ebf9f7 !important;
|
||||
color: #1bb19ab8 !important;
|
||||
border: 0;
|
||||
}
|
||||
|
||||
.q-btn-group--outline > .q-btn-item:not(:last-child):before {
|
||||
|
|
|
|||
|
|
@ -271,34 +271,40 @@ function updateSelect() {
|
|||
search.value = "";
|
||||
}
|
||||
|
||||
function getOrgOp() {
|
||||
http
|
||||
.get(config.API.Kpiorg)
|
||||
.then((res) => {
|
||||
const data = res.data.result;
|
||||
evaluatorIdMainOp.value = data.caregiver.map((i: any) => ({
|
||||
id: i.id,
|
||||
name: `${i.prefix ? i.prefix : ""}${i.firstName ? i.firstName : ""} ${
|
||||
i.lastName ? i.lastName : ""
|
||||
}`,
|
||||
}));
|
||||
commanderIdMainOp.value = data.commander.map((i: any) => ({
|
||||
id: i.id,
|
||||
name: `${i.prefix ? i.prefix : ""}${i.firstName ? i.firstName : ""} ${
|
||||
i.lastName ? i.lastName : ""
|
||||
}`,
|
||||
}));
|
||||
commanderHighMainOp.value = data.chairman.map((i: any) => ({
|
||||
id: i.id,
|
||||
name: `${i.prefix ? i.prefix : ""}${i.firstName ? i.firstName : ""} ${
|
||||
i.lastName ? i.lastName : ""
|
||||
}`,
|
||||
}));
|
||||
})
|
||||
.catch((e) => {
|
||||
messageError($q, e);
|
||||
})
|
||||
.finally(() => {});
|
||||
function getOrgOp(check: boolean,id:string) {
|
||||
if (check == false) {
|
||||
http
|
||||
.get(config.API.Kpiorg+`/${id}`)
|
||||
.then((res) => {
|
||||
const data = res.data.result;
|
||||
evaluatorIdMainOp.value = data.caregiver.map((i: any) => ({
|
||||
id: i.id,
|
||||
name: `${i.prefix ? i.prefix : ""}${i.firstName ? i.firstName : ""} ${
|
||||
i.lastName ? i.lastName : ""
|
||||
}`,
|
||||
}));
|
||||
commanderIdMainOp.value = data.commander.map((i: any) => ({
|
||||
id: i.id,
|
||||
name: `${i.prefix ? i.prefix : ""}${i.firstName ? i.firstName : ""} ${
|
||||
i.lastName ? i.lastName : ""
|
||||
}`,
|
||||
}));
|
||||
commanderHighMainOp.value = data.chairman.map((i: any) => ({
|
||||
id: i.id,
|
||||
name: `${i.prefix ? i.prefix : ""}${i.firstName ? i.firstName : ""} ${
|
||||
i.lastName ? i.lastName : ""
|
||||
}`,
|
||||
}));
|
||||
})
|
||||
.catch((e) => {
|
||||
messageError($q, e);
|
||||
})
|
||||
.finally(() => {});
|
||||
} else {
|
||||
evaluatorIdMainOp.value = [];
|
||||
commanderIdMainOp.value = [];
|
||||
commanderHighMainOp.value = [];
|
||||
}
|
||||
}
|
||||
|
||||
function onSubmit() {
|
||||
|
|
@ -346,7 +352,6 @@ watch(
|
|||
(n) => {
|
||||
if (n == true) {
|
||||
fetchRoundOption();
|
||||
getOrgOp();
|
||||
}
|
||||
}
|
||||
);
|
||||
|
|
@ -456,6 +461,7 @@ watch(
|
|||
color="primary"
|
||||
dense
|
||||
v-model="props.selected"
|
||||
@click="getOrgOp(props.selected,props.row.id)"
|
||||
/>
|
||||
</q-td>
|
||||
<q-td
|
||||
|
|
|
|||
|
|
@ -56,8 +56,8 @@ const columns = ref<QTableProps["columns"]>([
|
|||
label: "ตัวชี้วัด",
|
||||
sortable: true,
|
||||
field: "includingName",
|
||||
headerStyle: "font-size: 14px",
|
||||
style: "font-size: 14px",
|
||||
headerStyle: "font-size: 14px;width:200px",
|
||||
style: "font-size: 14px;",
|
||||
sort: (a: string, b: string) =>
|
||||
a.localeCompare(b, undefined, { numeric: true, sensitivity: "base" }),
|
||||
},
|
||||
|
|
@ -334,6 +334,9 @@ const isEditStep3 = computed(() => {
|
|||
<div v-else-if="col.name === 'achievement'">
|
||||
{{ props.row.point ? `ระดับ ${props.row.point}` : "" }}
|
||||
</div>
|
||||
<div v-else-if="col.name === 'includingName'" style="width: 200px; white-space: normal;">
|
||||
{{ props.row.includingName ? props.row.includingName : "-" }}
|
||||
</div>
|
||||
<div v-else-if="col.name === 'evaluationResults'">
|
||||
{{
|
||||
parseFloat(
|
||||
|
|
@ -347,9 +350,10 @@ const isEditStep3 = computed(() => {
|
|||
</q-td>
|
||||
<td>
|
||||
<div
|
||||
v-if="
|
||||
store.dataEvaluation.evaluationStatus == 'APPROVE' &&
|
||||
store.tabMain === '2'
|
||||
v-if="
|
||||
(store.dataEvaluation.evaluationStatus == 'APPROVE' &&
|
||||
store.tabMain === '2') ||
|
||||
store.tabMain === '3'
|
||||
"
|
||||
>
|
||||
<q-btn
|
||||
|
|
@ -437,8 +441,9 @@ const isEditStep3 = computed(() => {
|
|||
<q-card-actions
|
||||
align="around"
|
||||
v-if="
|
||||
store.dataEvaluation.evaluationStatus == 'APPROVE' &&
|
||||
store.tabMain === '2'
|
||||
(store.dataEvaluation.evaluationStatus == 'APPROVE' &&
|
||||
store.tabMain === '2') ||
|
||||
store.tabMain === '3'
|
||||
"
|
||||
>
|
||||
<q-btn
|
||||
|
|
|
|||
|
|
@ -349,7 +349,7 @@ onMounted(() => {
|
|||
<d-table
|
||||
ref="table"
|
||||
:columns="columns"
|
||||
:rows="rows[item.id].length !== 0 ? rows[item.id]:[]"
|
||||
:rows="rows[item.id]?.length !== 0 ? rows[item.id]:[]"
|
||||
row-key="id"
|
||||
flat
|
||||
bordered
|
||||
|
|
@ -439,9 +439,10 @@ onMounted(() => {
|
|||
</q-td>
|
||||
<q-td>
|
||||
<div
|
||||
v-if="
|
||||
store.dataEvaluation.evaluationStatus == 'APPROVE' &&
|
||||
store.tabMain === '2'
|
||||
v-if="
|
||||
(store.dataEvaluation.evaluationStatus == 'APPROVE' &&
|
||||
store.tabMain === '2') ||
|
||||
store.tabMain === '3'
|
||||
"
|
||||
>
|
||||
<q-btn
|
||||
|
|
@ -463,13 +464,16 @@ onMounted(() => {
|
|||
round
|
||||
:icon="
|
||||
item.id == 'HEAD' || item.id == 'GROUP'
|
||||
? 'edit'
|
||||
? 'mdi-eye'
|
||||
: 'edit'
|
||||
"
|
||||
color="info"
|
||||
@click.stop.pervent="onEdit(props.row, item.id)"
|
||||
>
|
||||
<q-tooltip>แก้ไข </q-tooltip>
|
||||
<q-tooltip v-if="item.id == 'HEAD' || item.id == 'GROUP'"
|
||||
>ดูรายละเอียด</q-tooltip
|
||||
>
|
||||
<q-tooltip v-else>แก้ไข</q-tooltip>
|
||||
</q-btn>
|
||||
<q-btn
|
||||
flat
|
||||
|
|
@ -530,8 +534,9 @@ onMounted(() => {
|
|||
<q-card-actions
|
||||
align="around"
|
||||
v-if="
|
||||
store.dataEvaluation.evaluationStatus == 'APPROVE' &&
|
||||
store.tabMain === '2'
|
||||
(store.dataEvaluation.evaluationStatus == 'APPROVE' &&
|
||||
store.tabMain === '2') ||
|
||||
store.tabMain === '3'
|
||||
"
|
||||
>
|
||||
<q-btn
|
||||
|
|
|
|||
|
|
@ -309,23 +309,24 @@ onMounted(() => {
|
|||
</q-td>
|
||||
<q-td>
|
||||
<div
|
||||
v-if="
|
||||
store.dataEvaluation.evaluationStatus == 'APPROVE' &&
|
||||
store.tabMain === '2'
|
||||
v-if="
|
||||
(store.dataEvaluation.evaluationStatus == 'APPROVE' &&
|
||||
store.tabMain === '2') ||
|
||||
store.tabMain === '3'
|
||||
"
|
||||
>
|
||||
<q-btn
|
||||
flat
|
||||
round
|
||||
icon="mdi-developer-board"
|
||||
icon="mdi-account-details"
|
||||
color="blue-6"
|
||||
size="12px"
|
||||
dense
|
||||
@click="openPopupProgress(props.row.id)"
|
||||
>
|
||||
<q-tooltip>รายงานความก้าวหน้า</q-tooltip>
|
||||
<q-tooltip>บันทึกเหตุการณ์/พฤติกรรม</q-tooltip>
|
||||
</q-btn>
|
||||
<q-btn
|
||||
<!-- <q-btn
|
||||
flat
|
||||
round
|
||||
icon="warning"
|
||||
|
|
@ -336,7 +337,7 @@ onMounted(() => {
|
|||
@click="openPopupProblem(props.row.id)"
|
||||
>
|
||||
<q-tooltip>รายงานปัญหา</q-tooltip>
|
||||
</q-btn>
|
||||
</q-btn> -->
|
||||
</div>
|
||||
|
||||
<div v-if="isEditStep1">
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue