ประกาศผล => fix bug

This commit is contained in:
DESKTOP-1R2VSQH\Lenovo ThinkPad E490 2024-07-16 13:08:40 +07:00
parent 45a06402fe
commit 2ebcb1961c
3 changed files with 11 additions and 14 deletions

View file

@ -55,7 +55,7 @@ const columns = ref<QTableProps["columns"]>([
name: "detail",
align: "left",
label: "เกณฑ์การประเมิน",
sortable: true,
sortable: false,
field: "detail",
headerStyle: "font-size: 14px",
style: "font-size: 14px; width:80%;",
@ -90,11 +90,10 @@ function fetchDetailIndividual() {
.then((res) => {
const data = res.data.result;
title.value = data.name;
develop.value = [
data.isDevelopment70 ? "isDevelopment70" : "",
data.isDevelopment20 ? "isDevelopment20" : "",
data.isDevelopment10 ? "isDevelopment10" : "",
];
const developKeys = [70, 20, 10];
develop.value = developKeys
.filter((key) => data[`isDevelopment${key}`])
.map((key) => `isDevelopment${key}`);
target.value = data.target;
const achievements = ["10", "5", "0"];

View file

@ -187,12 +187,10 @@ function onAnnounce() {
.post(config.API.evaluationUserDone, {
id: ids,
})
.then(() => {
setTimeout(async () => {
await porps.fetchData();
await success($q, "ประกาศผลสำเร็จ");
selected.value = [];
}, 1500);
.then(async () => {
await porps.fetchData();
await success($q, "ประกาศผลสำเร็จ");
selected.value = [];
})
.catch((err) => {
messageError($q, err);

View file

@ -259,7 +259,7 @@ function filterSelector(val: string, update: Function, type: string) {
switch (type) {
case "typereport":
update(() => {
typeReport.value = "";
typeReport.value = val ? "" : typeReport.value;
listReport.value = listReportMain.value.filter(
(v: DataOption) => v.name.toLowerCase().indexOf(val) > -1
);
@ -267,7 +267,7 @@ function filterSelector(val: string, update: Function, type: string) {
break;
case "organization":
update(() => {
organization.value = "";
organization.value = val ? "" : organization.value;
organizationOps.value = organizationOpsMain.value.filter(
(v: DataOption) => v.name.toLowerCase().indexOf(val) > -1
);