ปรับการแสดงผลสมรรถนะ
This commit is contained in:
parent
613fbece2e
commit
d0627e3c5c
3 changed files with 69 additions and 9 deletions
|
|
@ -171,8 +171,26 @@ function onSubmit() {
|
||||||
<q-tr :props="props" class="cursor-pointer">
|
<q-tr :props="props" class="cursor-pointer">
|
||||||
<q-td v-for="col in props.cols" :key="col.id">
|
<q-td v-for="col in props.cols" :key="col.id">
|
||||||
<div v-if="col.name === 'point'">
|
<div v-if="col.name === 'point'">
|
||||||
<div v-if="type == 'HEAD' || type == 'GROUP'">
|
<div>
|
||||||
<q-rating
|
<q-btn-group outline>
|
||||||
|
<q-btn
|
||||||
|
v-for="(i, index) in sortedDataListCriteria"
|
||||||
|
:key="index"
|
||||||
|
:class="props.row.point == i.level && 'active'"
|
||||||
|
outline
|
||||||
|
color="grey-6"
|
||||||
|
:label="i.level"
|
||||||
|
@click="props.row.point = i.level"
|
||||||
|
>
|
||||||
|
<q-tooltip>
|
||||||
|
<div class="text-body2">
|
||||||
|
<span v-html="i.description"></span>
|
||||||
|
</div>
|
||||||
|
</q-tooltip>
|
||||||
|
</q-btn>
|
||||||
|
</q-btn-group>
|
||||||
|
|
||||||
|
<!-- <q-rating
|
||||||
v-model="props.row.point"
|
v-model="props.row.point"
|
||||||
max="5"
|
max="5"
|
||||||
size="sm"
|
size="sm"
|
||||||
|
|
@ -191,9 +209,8 @@ function onSubmit() {
|
||||||
</div>
|
</div>
|
||||||
</q-tooltip>
|
</q-tooltip>
|
||||||
</template>
|
</template>
|
||||||
</q-rating>
|
</q-rating> -->
|
||||||
</div>
|
</div>
|
||||||
<div v-else>รอ ทำ select</div>
|
|
||||||
</div>
|
</div>
|
||||||
<div v-else-if="col.name === 'summary'">
|
<div v-else-if="col.name === 'summary'">
|
||||||
{{ props.row.point !== 0 ? props.row.point * 20 : "-" }}
|
{{ props.row.point !== 0 ? props.row.point * 20 : "-" }}
|
||||||
|
|
@ -260,4 +277,14 @@ function onSubmit() {
|
||||||
top: 0;
|
top: 0;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
.q-btn-group--outline > .q-btn-item:not(:last-child):before {
|
||||||
|
border-right: 1px solid #c4c4c4;
|
||||||
|
}
|
||||||
|
.q-btn-group--outline > .q-btn-item.active {
|
||||||
|
color: #2196f3 !important;
|
||||||
|
background-color: #fff;
|
||||||
|
}
|
||||||
|
.q-btn-group--outline > .q-btn-item.active:not(:last-child):before {
|
||||||
|
border: 1px solid #2196f3;
|
||||||
|
}
|
||||||
</style>
|
</style>
|
||||||
|
|
|
||||||
|
|
@ -107,6 +107,12 @@ const columns = ref<QTableProps["columns"]>([
|
||||||
},
|
},
|
||||||
]);
|
]);
|
||||||
|
|
||||||
|
const visibleColumns = ref<string[]>(
|
||||||
|
store.tabOpen === 3
|
||||||
|
? ["name", "level", "point", "weight", "summary"]
|
||||||
|
: ["name", "level", "weight"]
|
||||||
|
);
|
||||||
|
|
||||||
const typeCompetency = ref<string>("");
|
const typeCompetency = ref<string>("");
|
||||||
function onAdd(type: string) {
|
function onAdd(type: string) {
|
||||||
typeCompetency.value = type;
|
typeCompetency.value = type;
|
||||||
|
|
@ -239,7 +245,7 @@ onMounted(() => {
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<q-space />
|
<q-space />
|
||||||
<!-- <q-btn
|
<q-btn
|
||||||
v-if="!isReadonly"
|
v-if="!isReadonly"
|
||||||
flat
|
flat
|
||||||
round
|
round
|
||||||
|
|
@ -250,7 +256,7 @@ onMounted(() => {
|
||||||
@click="onEvaluate(item.id)"
|
@click="onEvaluate(item.id)"
|
||||||
>
|
>
|
||||||
<q-tooltip>ประเมิน</q-tooltip>
|
<q-tooltip>ประเมิน</q-tooltip>
|
||||||
</q-btn> -->
|
</q-btn>
|
||||||
</div>
|
</div>
|
||||||
</q-card-section>
|
</q-card-section>
|
||||||
<q-card-section class="q-pa-sm">
|
<q-card-section class="q-pa-sm">
|
||||||
|
|
@ -266,6 +272,7 @@ onMounted(() => {
|
||||||
hide-pagination
|
hide-pagination
|
||||||
class="custom-table2"
|
class="custom-table2"
|
||||||
no-data-label="ไม่มีข้อมูล"
|
no-data-label="ไม่มีข้อมูล"
|
||||||
|
:visible-columns="visibleColumns"
|
||||||
>
|
>
|
||||||
<template v-slot:header="props">
|
<template v-slot:header="props">
|
||||||
<q-tr :props="props">
|
<q-tr :props="props">
|
||||||
|
|
@ -283,7 +290,23 @@ onMounted(() => {
|
||||||
</div>
|
</div>
|
||||||
<div v-else-if="col.name == 'point'">
|
<div v-else-if="col.name == 'point'">
|
||||||
<div>
|
<div>
|
||||||
<q-rating
|
<q-btn-group outline>
|
||||||
|
<q-btn
|
||||||
|
v-for="(i, index) in sortedDataListCriteria"
|
||||||
|
:key="index"
|
||||||
|
:class="props.row.point == i.level && 'active'"
|
||||||
|
outline
|
||||||
|
color="grey-6"
|
||||||
|
:label="i.level"
|
||||||
|
>
|
||||||
|
<q-tooltip>
|
||||||
|
<div class="text-body2">
|
||||||
|
<span v-html="i.description"></span>
|
||||||
|
</div>
|
||||||
|
</q-tooltip>
|
||||||
|
</q-btn>
|
||||||
|
</q-btn-group>
|
||||||
|
<!-- <q-rating
|
||||||
v-model="props.row.point"
|
v-model="props.row.point"
|
||||||
max="5"
|
max="5"
|
||||||
size="sm"
|
size="sm"
|
||||||
|
|
@ -303,7 +326,7 @@ onMounted(() => {
|
||||||
</div>
|
</div>
|
||||||
</q-tooltip>
|
</q-tooltip>
|
||||||
</template>
|
</template>
|
||||||
</q-rating>
|
</q-rating> -->
|
||||||
</div>
|
</div>
|
||||||
<!-- <div v-else>รอ ทำ select</div> -->
|
<!-- <div v-else>รอ ทำ select</div> -->
|
||||||
</div>
|
</div>
|
||||||
|
|
@ -402,4 +425,14 @@ onMounted(() => {
|
||||||
top: 0;
|
top: 0;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
.q-btn-group--outline > .q-btn-item:not(:last-child):before {
|
||||||
|
border-right: 1px solid #c4c4c4;
|
||||||
|
}
|
||||||
|
.q-btn-group--outline > .q-btn-item.active {
|
||||||
|
color: #2196f3 !important;
|
||||||
|
background-color: #fff;
|
||||||
|
}
|
||||||
|
.q-btn-group--outline > .q-btn-item.active:not(:last-child):before {
|
||||||
|
border: 1px solid #2196f3;
|
||||||
|
}
|
||||||
</style>
|
</style>
|
||||||
|
|
|
||||||
|
|
@ -284,7 +284,7 @@ async function clearScore() {
|
||||||
|
|
||||||
async function getAll() {
|
async function getAll() {
|
||||||
await fetchEvaluation();
|
await fetchEvaluation();
|
||||||
await getProfile(); // await (store.dataProfile === null ? getProfile() : "");
|
await (store.dataProfile.profileId === null ? getProfile() : ""); // await getProfile();
|
||||||
await getOrgOp();
|
await getOrgOp();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue