Merge branch 'develop' of github.com:Frappet/bma-ehr-frontend into develop

* 'develop' of github.com:Frappet/bma-ehr-frontend:
  แก้ไขคำผิด
  รายการลาออก
  รายการลาออก
This commit is contained in:
Warunee Tamkoo 2024-05-23 17:20:42 +07:00
commit bb2d03e499
15 changed files with 452 additions and 425 deletions

View file

@ -27,14 +27,20 @@ export default {
listResign: () => `${retirement}/resign`, listResign: () => `${retirement}/resign`,
resignReport: `${retirement}/resign/report`, resignReport: `${retirement}/resign/report`,
resingByid: (id: string) => `${retirement}/resign/${id}`, resingByid: (id: string) => `${retirement}/resign/${id}`,
resignConfirm: (role: String, id: string) => `${retirement}/resign/${role}/confirm/${id}`, resignConfirm: (role: String, id: string) =>
resignReject: (role: String, id: string) => `${retirement}/resign/${role}/reject/${id}`, `${retirement}/resign/${role}/confirm/${id}`,
resignReject: (role: String, id: string) =>
`${retirement}/resign/${role}/reject/${id}`,
listExitInterview: () => `${retirement}/resign/questionnaire`, listExitInterview: () => `${retirement}/resign/questionnaire`,
commentExitInterview: (id:string) => `${retirement}/resign/questionnaire/comment/${id}`, commentExitInterview: (id: string) =>
`${retirement}/resign/questionnaire/comment/${id}`,
questionExitInterview: () => `${retirement}/resign/questionnaire/question`, questionExitInterview: () => `${retirement}/resign/questionnaire/question`,
ExitInterviewByid: (id: string) => `${retirement}/resign/questionnaire/${id}`, ExitInterviewByid: (id: string) => `${retirement}/resign/questionnaire/${id}`,
ExitInterviewReport: `${retirement}/resign/questionnaire/report`, ExitInterviewReport: `${retirement}/resign/questionnaire/report`,
AppointInterview: (id: string) => `${retirement}/resign/questionnaire/appoint/${id}`, AppointInterview: (id: string) =>
`${retirement}/resign/questionnaire/appoint/${id}`,
resignConditions: (id: string) => `${retirement}/resign/debt/${id}`,
// ปลดออก // ปลดออก
retirementDischarge, retirementDischarge,
listDischarge: () => `${retirement}/discharge`, listDischarge: () => `${retirement}/discharge`,
@ -58,8 +64,5 @@ export default {
editDetail: (retireId: string) => `${retirement}/detail/${retireId}`, editDetail: (retireId: string) => `${retirement}/detail/${retireId}`,
// ตำถาม Exit interview // ตำถาม Exit interview
questionnaireList: () => `${retirement}/resign/questionnaire/question` questionnaireList: () => `${retirement}/resign/questionnaire/question`,
}; };

View file

@ -9,6 +9,8 @@ import { useRetirementDataStore } from "@/modules/06_retirement/store";
import CurrencyInput from "@/components/CurruncyInput.vue"; import CurrencyInput from "@/components/CurruncyInput.vue";
import http from "@/plugins/http"; import http from "@/plugins/http";
import config from "@/app.config"; import config from "@/app.config";
import axios from "axios";
import keycloak from "@/plugins/keycloak"; import keycloak from "@/plugins/keycloak";
import type { import type {
TypeFile, TypeFile,
@ -23,7 +25,6 @@ import type { DataProfile } from "@/modules/05_placement/interface/index/Main";
/** importComponents*/ /** importComponents*/
import CardProfile from "@/components/CardProfile.vue"; import CardProfile from "@/components/CardProfile.vue";
const avatar = ref<string>("");
const modalPersonal = ref<boolean>(false); const modalPersonal = ref<boolean>(false);
const personId = ref<string>(""); const personId = ref<string>("");
/** Use */ /** Use */
@ -38,7 +39,7 @@ const {
showLoader, showLoader,
hideLoader, hideLoader,
success, success,
dialogMessage,
dialogConfirm, dialogConfirm,
dialogRemove, dialogRemove,
} = mixin; } = mixin;
@ -133,16 +134,21 @@ const checkboxGroup = ref<CheckBoxType[]>([]);
const checkboxOp = ref<CheckBoxType[]>([ const checkboxOp = ref<CheckBoxType[]>([
{ label: "ไม่เป็นหนี้สหกรณ์", value: "debt" }, { label: "ไม่เป็นหนี้สหกรณ์", value: "debt" },
]); ]);
/** Hook */ /** Hook */
onMounted(async () => { onMounted(async () => {
fetchData(id.value); fetchData(id.value);
fetchFile();
if (keycloak.tokenParsed !== undefined) { if (keycloak.tokenParsed !== undefined) {
const commander = await keycloak.tokenParsed.role.includes("commander"); const commander = await keycloak.tokenParsed.role.includes("commander");
const oligarch = await keycloak.tokenParsed.role.includes("oligarch"); const oligarch = await keycloak.tokenParsed.role.includes("oligarch");
const officer = await keycloak.tokenParsed.role.includes("officer");
if (commander) { if (commander) {
roleUser.value = "commander"; roleUser.value = "commander";
} else if (oligarch) { } else if (oligarch) {
roleUser.value = "oligarch"; roleUser.value = "oligarch";
} else if (officer) {
roleUser.value = "officer";
} else { } else {
roleUser.value = "admin"; roleUser.value = "admin";
} }
@ -154,7 +160,6 @@ const diffDate = () => {
const time = dateLeave.value.getTime() - date.value.getTime(); const time = dateLeave.value.getTime() - date.value.getTime();
// - // -
const day = time / (1000 * 3600 * 24); const day = time / (1000 * 3600 * 24);
if (day < 30) { if (day < 30) {
return true; return true;
} }
@ -163,9 +168,7 @@ const diffDate = () => {
return false; return false;
}; };
/** /** นำข้อมูลมาจาก API*/
* นำขอมลมาจาก API
*/
const fetchData = async (id: string) => { const fetchData = async (id: string) => {
showLoader(); showLoader();
await http await http
@ -196,7 +199,6 @@ const fetchData = async (id: string) => {
location.value = data.location ?? ""; location.value = data.location ?? "";
status.value = data.status ?? ""; status.value = data.status ?? "";
remarkHorizontal.value = data.remarkHorizontal ?? "-"; remarkHorizontal.value = data.remarkHorizontal ?? "-";
// getAvatar(data.profileId);
}) })
.catch((e) => { .catch((e) => {
messageError($q, e); messageError($q, e);
@ -206,30 +208,6 @@ const fetchData = async (id: string) => {
}); });
}; };
// function getAvatar(id: string) {
// if (id) {
// http
// .get(config.API.profileAvaId(id))
// .then((res) => {
// console.log(res);
// const dataList = res.data.result;
// avatar.value = dataList.avatar;
// })
// .catch((e) => {})
// .finally(() => {});
// }
// }
// const downloadFile = (response: any, filename: string) => {
// const link = document.createElement("a");
// var fileName = filename;
// link.href = window.URL.createObjectURL(new Blob([response.data]));
// link.setAttribute("download", fileName);
// document.body.appendChild(link);
// link.click();
// document.body.removeChild(link);
// };
/**Pop up */ /**Pop up */
const popUp = (action: "pass" | "passNot") => { const popUp = (action: "pass" | "passNot") => {
reasonReign.value = ""; reasonReign.value = "";
@ -237,6 +215,7 @@ const popUp = (action: "pass" | "passNot") => {
actionPass.value = action === "pass"; actionPass.value = action === "pass";
openModal(); openModal();
}; };
//pop up //pop up
const conditionPopup = () => { const conditionPopup = () => {
if (myFormConfirm.value !== null) { if (myFormConfirm.value !== null) {
@ -311,6 +290,7 @@ const rejectpopUp = async () => {
const clickCancel = async () => { const clickCancel = async () => {
await fetchData(id.value); await fetchData(id.value);
edit.value = false; edit.value = false;
myForm.value?.resetValidation();
}; };
/** /**
* กดยกเล * กดยกเล
@ -320,86 +300,60 @@ const clickCancelConditions = async () => {
conditions.value = false; conditions.value = false;
}; };
const saveConditions = () => { /** Function บันทึก รายการตรวจสอบเงื่อนไขต่าง ๆ*/
if (myForm.value !== null) { const onSubmitConditions = () => {
myForm.value.validate().then((success) => { dialogConfirm($q, () => {
if (success) { showLoader();
dialogConfirm($q, () => { http
dataSave(); .put(config.API.resignConditions(id.value), {
}); IsNoDebt: checkboxGroup.value[0] ? true : false,
// dialogMessage( })
// $q, .then(() => {
// "?", fetchData(id.value);
// "", success($q, "บันทึกเงื่อนไขต่าง ๆ สำเร็จ");
// "mdi-help-circle-outline", conditions.value = false;
// "", })
// "public", .catch((err) => {
// async () => await dataSave(), messageError($q, err);
// undefined })
// ); .finally(() => {
} hideLoader();
}); });
} });
}; };
//Save Api /** Function บันทึก ,แก้ไขข้อมูลเพื่อลงบัญชีแนบท้าย*/
const dataSave = async () => {}; const onSubmitAttached = () => {
dialogConfirm($q, () => {
/** const formData = new FormData();
* Functionบนท const send = date.value !== null ? new Date(date.value).toUTCString() : "";
*/ const activeDate =
const conditionSave = () => { dateLeave.value !== null ? new Date(dateLeave.value).toUTCString() : "";
if (myForm.value !== null) { formData.append("Location", location.value);
myForm.value.validate().then((success) => { formData.append("SendDate", send);
if (success) { formData.append("ActiveDate", activeDate);
dialogConfirm($q, () => { formData.append("Reason", reason.value);
saveData(); formData.append("OrganizationPositionOld", organizationPositionOld.value);
}); formData.append("PositionTypeOld", positionTypeOld.value);
// dialogMessage( formData.append("PositionLevelOld", positionLevelOld.value);
// $q, formData.append("PositionNumberOld", posNo.value);
// "?", formData.append("AmountOld", salary.value.toString());
// "", formData.append("remarkHorizontal", remarkHorizontal.value);
// "mdi-help-circle-outline", showLoader();
// "", http
// "public", .put(config.API.resingByid(id.value), formData)
// async () => , .then(() => {
// undefined edit.value = false;
// ); success($q, "บันทึกข้อมูลสำเร็จ");
} })
}); .catch((e) => {
} messageError($q, e);
}; })
.finally(async () => {
//Save Api await fetchData(id.value);
const saveData = async () => { await hideLoader();
const formData = new FormData(); });
const send = date.value !== null ? new Date(date.value).toUTCString() : ""; });
const activeDate =
dateLeave.value !== null ? new Date(dateLeave.value).toUTCString() : "";
formData.append("Location", location.value);
formData.append("SendDate", send);
formData.append("ActiveDate", activeDate);
formData.append("Reason", reason.value);
formData.append("OrganizationPositionOld", organizationPositionOld.value);
formData.append("PositionTypeOld", positionTypeOld.value);
formData.append("PositionLevelOld", positionLevelOld.value);
formData.append("PositionNumberOld", posNo.value);
formData.append("AmountOld", salary.value.toString());
formData.append("remarkHorizontal", remarkHorizontal.value);
showLoader();
await http
.put(config.API.resingByid(id.value), formData)
.then(() => {
success($q, "แก้ไขข้อมูลเพื่อลงบัญชีแนบท้ายสำเร็จ");
edit.value = false;
})
.catch((e) => {
messageError($q, e);
})
.finally(async () => {
await fetchData(id.value);
hideLoader();
});
}; };
/** /**
@ -464,52 +418,117 @@ function updatemodalPersonal(modal: boolean) {
modalPersonal.value = modal; modalPersonal.value = modal;
} }
async function fetchFile() {
showLoader();
await http
.get(config.API.file("พ้นจากราชการ", "หลักฐานลาออก", id.value))
.then((res) => {
fileList.value = res.data;
})
.catch((e) => {
messageError($q, e);
})
.finally(() => {
hideLoader();
});
}
function uploadFiles() { function uploadFiles() {
showLoader();
http
.post(config.API.file("พ้นจากราชการ", "หลักฐานลาออก", id.value), {
replace: true,
fileList: [
{
fileName: file.value.name,
},
],
})
.then(async (res) => {
const foundKey: string | undefined = Object.keys(res.data).find(
(key) =>
res.data[key]?.fileName !== undefined &&
res.data[key]?.fileName !== ""
);
foundKey && uploadFileURL(res.data[foundKey]?.uploadUrl);
})
.catch((err) => {
messageError($q, err);
})
.finally(() => {
hideLoader();
});
}
async function uploadFileURL(uploadUrl: string) {
const Data = new FormData(); const Data = new FormData();
Data.append("file", file.value); Data.append("file", file.value);
showLoader(); showLoader();
http await axios
.put(config.API.investigateRelevantUploadFile(id.value), Data) .put(uploadUrl, file.value, {
headers: {
"Content-Type": file.value.type,
},
})
.then(() => { .then(() => {
success($q, "อัปโหลดไฟล์สำเร็จ"); success($q, "อัปโหลดไฟล์สำเร็จ");
fetchFile();
})
.catch((e) => {
messageError($q, e);
})
.finally(() => {
hideLoader();
file.value = null;
});
}
function downloadFiles(fileName: string) {
showLoader();
http
.get(
config.API.fileByFile("พ้นจากราชการ", "หลักฐานลาออก", id.value, fileName)
)
.then((res) => {
const data = res.data.downloadUrl;
window.open(data, "_blank");
}) })
.catch((e) => { .catch((e) => {
messageError($q, e); messageError($q, e);
}) })
.finally(async () => { .finally(async () => {
hideLoader(); hideLoader();
file.value = null;
}); });
} }
function downloadFiles(link: string) {
window.open(link, "_blank");
}
/** /**
* ลบไฟล * ลบไฟล
* @param id id file * @param id id file
*/ */
function removeFile(id: string) { function removeFile(fileName: string) {
dialogRemove($q, () => confirmRemove(id)); dialogRemove($q, () => {
} showLoader();
http
/** .delete(
* นย ลบ ไฟล config.API.fileByFile(
* @param id id file "พ้นจากราชการ",
*/ "หลักฐานลาออก",
function confirmRemove(fileId: string) { id.value,
showLoader(); fileName
http )
.delete(config.API.investigateRelevantFileDelete(id.value, fileId)) )
.then((res) => { .then(() => {
success($q, `ลบไฟล์สำเร็จ`); success($q, `ลบไฟล์สำเร็จ`);
fetchData(id.value); setTimeout(() => {
}) fetchFile();
.catch((e) => { hideLoader();
messageError($q, e); }, 1000);
}) })
.finally(() => {}); .catch((e) => {
messageError($q, e);
hideLoader();
});
});
} }
</script> </script>
<template> <template>
@ -596,10 +615,14 @@ function confirmRemove(fileId: string) {
<div <div
class="q-gutter-x-sm" class="q-gutter-x-sm"
v-if=" v-if="
(roleUser === 'commander' && dataDetail.commanderReject === null) || (roleUser === 'commander' &&
dataDetail.commanderReject === null &&
dataDetail.officerReject === null) ||
(roleUser === 'oligarch' && (roleUser === 'oligarch' &&
dataDetail.oligarchReject === null && dataDetail.oligarchReject === null &&
dataDetail.commanderReject !== null) dataDetail.commanderReject !== null &&
dataDetail.officerReject === null) ||
(roleUser === 'officer' && dataDetail.officerReject === null)
" "
> >
<q-btn <q-btn
@ -768,121 +791,186 @@ function confirmRemove(fileId: string) {
<div class="q-pl-sm text-weight-bold text-dark"> <div class="q-pl-sm text-weight-bold text-dark">
รายการตรวจสอบเงอนไขตาง รายการตรวจสอบเงอนไขตาง
</div> </div>
<q-space />
<div v-if="!conditions">
<q-btn
outline
color="primary"
dense
icon-right="mdi-file-edit-outline"
class="q-px-sm"
label="แก้ไข"
style="width: 80px"
@click="conditions = !conditions"
/>
</div>
<div v-else class="q-gutter-x-sm">
<q-btn
outline
color="public"
dense
class="q-px-sm"
label="บันทึก"
style="width: 80px"
@click="saveConditions"
/>
<q-btn
outline
color="red"
dense
class="q-px-sm"
label="ยกเลิก"
style="width: 80px"
@click="clickCancelConditions"
/>
</div>
</div> </div>
<div class="col-12"><q-separator /></div> <div class="col-12"><q-separator /></div>
<div class="col-7"> <div class="row col-12 q-pa-sm q-col-gutter-sm">
<q-option-group <div class="col-6">
:options="checkboxOp" <q-card bordered class="row col-12 text-dark q-mt-sm">
type="checkbox" <div class="bg-grey-1 q-pa-sm col-12 row items-center text-primary">
v-model="checkboxGroup" <div class="q-pl-sm text-weight-bold text-dark">เงอนไขตาง </div>
:disable="!conditions" <q-space />
/> <div v-if="!conditions">
</div>
<div class="col-5">
<div class="row col-12 q-col-gutter-y-sm q-pa-sm">
<div class="col-12 row">
<q-file
class="col-12"
for="#evidenceFiles"
outlined
dense
v-model="file"
label="อัปโหลดเอกสารหลักฐานต่าง ๆ"
hide-bottom-space
:disable="!conditions"
>
<template v-slot:prepend>
<q-icon name="attach_file" color="primary" />
</template>
<template v-slot:after>
<q-btn <q-btn
v-if="file" outline
size="14px" color="primary"
flat
round
dense dense
color="add" icon-right="mdi-file-edit-outline"
icon="mdi-upload" class="q-px-sm"
@click="uploadFiles" label="แก้ไข"
><q-tooltip>ปโหลดเอกสาร</q-tooltip></q-btn style="width: 80px"
@click="conditions = !conditions"
/>
</div>
<div v-else class="q-gutter-x-sm">
<q-btn
outline
color="public"
dense
class="q-px-sm"
label="บันทึก"
style="width: 80px"
@click="onSubmitConditions"
/>
<q-btn
outline
color="red"
dense
class="q-px-sm"
label="ยกเลิก"
style="width: 80px"
@click="clickCancelConditions"
/>
</div>
</div>
<div class="col-12"><q-separator /></div>
<!-- <q-checkbox v-model="teal" label="Teal" color="teal" :disable="!conditions" /> -->
<q-option-group
:options="checkboxOp"
type="checkbox"
v-model="checkboxGroup"
:disable="!conditions"
/>
</q-card>
</div>
<div class="col-6">
<q-card bordered class="row col-12 text-dark q-mt-sm">
<div class="bg-grey-1 q-pa-sm col-12 row items-center text-primary">
<div class="q-pl-sm text-weight-bold text-dark">
เอกสารหลกฐานตาง
</div>
</div>
<div class="col-12"><q-separator /></div>
<div class="row col-12 q-col-gutter-y-sm q-pa-sm">
<div class="col-12 row">
<q-file
class="col-12"
for="#evidenceFiles"
outlined
dense
v-model="file"
label="อัปโหลดเอกสารหลักฐานต่าง ๆ"
hide-bottom-space
> >
</template> <template v-slot:prepend>
</q-file> <q-icon name="attach_file" color="primary" />
</div> </template>
<template v-slot:after>
<q-btn
v-if="file"
size="14px"
flat
round
dense
color="add"
icon="mdi-upload"
@click="uploadFiles"
><q-tooltip>ปโหลดเอกสาร</q-tooltip></q-btn
>
</template>
</q-file>
</div>
<div v-if="fileList.length > 0" class="col-xs-12 row"> <div v-if="fileList.length > 0" class="col-xs-12 row">
<q-list class="full-width rounded-borders" bordered separator> <q-list class="full-width rounded-borders" bordered separator>
<q-item v-for="File in fileList" :key="File.id" clickable v-ripple> <q-item
<q-item-section>{{ File.fileName }}</q-item-section> v-for="File in fileList"
<q-item-section avatar> :key="File.id"
<div class="row"> clickable
<div> v-ripple
<q-btn >
dense <q-item-section>{{ File.title }}</q-item-section>
flat <q-item-section avatar>
round <div class="row">
size="12px" <div>
color="blue" <q-btn
icon="mdi-download-outline" dense
@click="downloadFiles(File.pathName)" flat
> round
<q-tooltip>ดาวนโหลดไฟล</q-tooltip> size="12px"
</q-btn> color="blue"
</div> icon="mdi-download-outline"
<div> @click="downloadFiles(File.fileName)"
<q-btn >
dense <q-tooltip>ดาวนโหลดไฟล</q-tooltip>
flat </q-btn>
round </div>
size="12px" <div>
color="red" <q-btn
icon="mdi-delete-outline" dense
@click="removeFile(file.id)" flat
><q-tooltip>ลบไฟล</q-tooltip></q-btn round
> size="12px"
</div> color="red"
</div> icon="mdi-delete-outline"
</q-item-section> @click="removeFile(File.fileName)"
</q-item> ><q-tooltip>ลบไฟล</q-tooltip></q-btn
</q-list> >
</div> </div>
</div>
</q-item-section>
</q-item>
</q-list>
</div>
<div class="col-12" v-else> <div class="col-12" v-else>
<q-card class="q-pa-sm" bordered> ไมรายการเอกสาร </q-card> <q-card class="q-pa-sm" bordered> ไมรายการเอกสาร </q-card>
</div>
</div>
</q-card>
</div>
</div>
</q-card>
<q-card bordered class="row col-12 text-dark q-mt-sm">
<div class="bg-grey-1 q-pa-sm col-12 row items-center text-primary">
<div class="q-pl-sm text-weight-bold text-dark">
ผลการพจารณาของการเจาหนาท
</div>
</div>
<q-separator />
<div class="row col-12 q-pa-md">
<div class="col-12 row bg-white q-col-gutter-md">
<div class="col-xs-6 row items-start">
<div class="col-12 text-top">สถานะ</div>
<div class="col-12 text-detail">
{{
dataDetail.officerReject !== null
? statusOrder(dataDetail.officerReject)
: "-"
}}
</div>
</div>
<div class="col-xs-6 row items-start">
<div class="col-12 text-top">นสดทายทบย</div>
<div class="col-12 text-detail">
{{
dataDetail.officerRejectDate !== null
? date2Thai(dataDetail.officerRejectDate)
: "-"
}}
</div>
</div>
<div class="col-xs-12 row items-start">
<div class="col-12 text-top">ความคดเหนและเหตผล</div>
<div class="col-12 text-detail">
{{
dataDetail.commanderReject
? dataDetail.officerRejectReason || "-"
: dataDetail.officerApproveReason || "-"
}}
</div>
</div> </div>
</div> </div>
</div> </div>
@ -919,24 +1007,11 @@ function confirmRemove(fileId: string) {
</div> </div>
<div class="col-xs-12 row items-start"> <div class="col-xs-12 row items-start">
<div class="col-12 text-top">ความคดเหนและเหตผล</div> <div class="col-12 text-top">ความคดเหนและเหตผล</div>
<div <div class="col-12 text-detail">
class="col-12 text-detail"
v-if="dataDetail.commanderReject === false"
>
{{ {{
dataDetail.commanderApproveReason !== null dataDetail.commanderReject
? dataDetail.commanderApproveReason ? dataDetail.commanderRejectReason || "-"
: "-" : dataDetail.commanderApproveReason || "-"
}}
</div>
<div
class="col-12 text-detail"
v-if="dataDetail.commanderReject === true"
>
{{
dataDetail.commanderRejectReason !== null
? dataDetail.commanderRejectReason
: "-"
}} }}
</div> </div>
</div> </div>
@ -975,24 +1050,11 @@ function confirmRemove(fileId: string) {
</div> </div>
<div class="col-xs-12 row items-start"> <div class="col-xs-12 row items-start">
<div class="col-12 text-top">ความคดเหนและเหตผล</div> <div class="col-12 text-top">ความคดเหนและเหตผล</div>
<div <div class="col-12 text-detail">
class="col-12 text-detail"
v-if="dataDetail.oligarchReject == false"
>
{{ {{
dataDetail.oligarchApproveReason !== null dataDetail.commanderReject
? dataDetail.oligarchApproveReason ? dataDetail.oligarchRejectReason || "-"
: "-" : dataDetail.oligarchApproveReason || "-"
}}
</div>
<div
class="col-12 text-detail"
v-else-if="dataDetail.oligarchReject == true"
>
{{
dataDetail.oligarchRejectReason !== null
? dataDetail.oligarchRejectReason
: "-"
}} }}
</div> </div>
</div> </div>
@ -1001,47 +1063,53 @@ function confirmRemove(fileId: string) {
</q-card> </q-card>
<q-card bordered class="row col-12 text-dark q-mt-sm"> <q-card bordered class="row col-12 text-dark q-mt-sm">
<div class="bg-grey-1 q-pa-sm col-12 row items-center text-primary"> <q-form
<div class="q-pl-sm text-weight-bold text-dark"> ref="myForm"
แกไขขอมลเพอลงบญชแนบทาย greedy
@submit.prevent
@validation-success="onSubmitAttached"
>
<div class="bg-grey-1 q-pa-sm col-12 row items-center text-primary">
<div class="q-pl-sm text-weight-bold text-dark">
แกไขขอมลเพอลงบญชแนบทาย
</div>
<q-space />
<div class="q-gutter-sm" v-if="!edit">
<q-btn
outline
color="primary"
dense
icon-right="mdi-file-edit-outline"
class="q-px-sm"
label="แก้ไข"
style="width: 80px"
@click="edit = !edit"
v-if="!(status == 'REPORT' || status == 'DONE')"
/>
</div>
<div class="q-gutter-sm" v-else>
<q-btn
outline
color="public"
dense
class="q-px-sm"
label="บันทึก"
style="width: 80px"
type="submit"
/>
<q-btn
outline
color="red"
dense
class="q-px-sm"
label="ยกเลิก"
style="width: 80px"
@click="clickCancel"
/>
</div>
</div> </div>
<q-space /> <div class="col-12"><q-separator /></div>
<div class="q-gutter-sm" v-if="!edit">
<q-btn
outline
color="primary"
dense
icon-right="mdi-file-edit-outline"
class="q-px-sm"
label="แก้ไข"
style="width: 80px"
@click="edit = !edit"
v-if="!(status == 'REPORT' || status == 'DONE')"
/>
</div>
<div class="q-gutter-sm" v-else>
<q-btn
outline
color="public"
dense
class="q-px-sm"
label="บันทึก"
style="width: 80px"
@click="conditionSave"
/>
<q-btn
outline
color="red"
dense
class="q-px-sm"
label="ยกเลิก"
style="width: 80px"
@click="clickCancel"
/>
</div>
</div>
<div class="col-12"><q-separator /></div>
<q-form ref="myForm">
<div class="row col-12 q-pa-md"> <div class="row col-12 q-pa-md">
<div class="col-12 row bg-white q-col-gutter-md"> <div class="col-12 row bg-white q-col-gutter-md">
<div class="col-xs-12 row items-center"> <div class="col-xs-12 row items-center">
@ -1187,56 +1255,6 @@ function confirmRemove(fileId: string) {
</datepicker> </datepicker>
</div> </div>
</div> </div>
<!-- <div class="col-xs-4 row">
<div class="col-12">
<datepicker
menu-class-name="modalfix"
:readonly="!edit"
v-model="dateLeave"
:locale="'th'"
autoApply
:enableTimePicker="false"
week-start="0"
>
<template #year="{ year }">{{ year + 543 }}</template>
<template #year-overlay-value="{ value }">{{
parseInt(value + 543)
}}</template>
<template #trigger>
<q-input
:readonly="!edit"
:class="getClass(edit)"
:outlined="edit"
dense
lazy-rules
:borderless="!edit"
:model-value="
dateLeave !== null ? date2Thai(dateLeave) : null
"
:rules="[
(val) =>
!!val || `${'กรุณาเลือก วันที่ขอลาออกจากราชการ'}`,
]"
hide-bottom-space
:label="`${' วันที่ขอลาออกจากราชการ'}`"
>
<template v-slot:prepend>
<q-icon
name="event"
class="cursor-pointer"
:style="
edit
? 'color: var(--q-primary)'
: 'color: var(--q-grey)'
"
>
</q-icon>
</template>
</q-input>
</template>
</datepicker>
</div>
</div> -->
<div class="col-12"> <div class="col-12">
<q-input <q-input
:class="getClass(edit)" :class="getClass(edit)"
@ -1273,6 +1291,7 @@ function confirmRemove(fileId: string) {
</div> </div>
</q-form> </q-form>
</q-card> </q-card>
<q-dialog v-model="modal" persistent> <q-dialog v-model="modal" persistent>
<q-card style="width: 800px"> <q-card style="width: 800px">
<q-form ref="myFormConfirm"> <q-form ref="myFormConfirm">

View file

@ -36,21 +36,26 @@ interface TypeFile {
} }
interface rowFile { interface rowFile {
fileName: string fileName: string;
pathName: string pathName: string;
} }
interface FileList { interface FileList {
id: string id: string;
fileName: string fileName: string;
pathName: string pathName: string;
title: string;
} }
interface CheckBoxType { interface CheckBoxType {
label: string label: string;
value: string value: string;
} }
export type { resMain, ResponseItems, TypeFile, rowFile,FileList,CheckBoxType }; export type {
resMain,
ResponseItems,
TypeFile,
rowFile,
FileList,
CheckBoxType,
};

View file

@ -1071,9 +1071,9 @@ const getClass = (val: boolean) => {
:rules="[ :rules="[
(val) => (val) =>
!!val || !!val ||
`${'กรุณากรอกมติ กก. ครั้งที่ (เรื่อง รับสมัครสอบฯ)'}`, `${'กรุณากรอกมติ กก. ครั้งที่ (เรื่อง รับสมัครสอบ ฯ)'}`,
]" ]"
:label="`${'มติ กก. ครั้งที่ (เรื่อง รับสมัครสอบฯ)'}`" :label="`${'มติ กก. ครั้งที่ (เรื่อง รับสมัครสอบ ฯ)'}`"
hide-bottom-space hide-bottom-space
/> />
</div> </div>
@ -1104,10 +1104,10 @@ const getClass = (val: boolean) => {
? date2Thai(conclusionRegisterDate) ? date2Thai(conclusionRegisterDate)
: null : null
" "
:label="`${'ลงวันที่ (เรื่อง รับสมัครสอบฯ)'}`" :label="`${'ลงวันที่ (เรื่อง รับสมัครสอบ ฯ)'}`"
:rules="[ :rules="[
(val) => (val) =>
!!val || `${'กรุณาเลือกลงวันที่ (เรื่อง รับสมัครสอบฯ)'}`, !!val || `${'กรุณาเลือกลงวันที่ (เรื่อง รับสมัครสอบ ฯ)'}`,
]" ]"
> >
<template v-slot:prepend> <template v-slot:prepend>
@ -1132,7 +1132,7 @@ const getClass = (val: boolean) => {
(val) => (val) =>
!!val || `${'กรุณากรอกมติ กก. ครั้งที่ (เรื่อง ผลการสอบฯ)'}`, !!val || `${'กรุณากรอกมติ กก. ครั้งที่ (เรื่อง ผลการสอบฯ)'}`,
]" ]"
:label="`${'มติ กก. ครั้งที่ (เรื่อง ผลการสอบฯ)'}`" :label="`${'มติ กก. ครั้งที่ (เรื่อง ผลการสอบ ฯ)'}`"
hide-bottom-space hide-bottom-space
/> />
</div> </div>
@ -1163,7 +1163,7 @@ const getClass = (val: boolean) => {
? date2Thai(conclusionResultDate) ? date2Thai(conclusionResultDate)
: null : null
" "
:label="`${'ลงวันที่ (เรื่อง ผลการสอบฯ)'}`" :label="`${'ลงวันที่ (เรื่อง ผลการสอบ ฯ)'}`"
:rules="[ :rules="[
(val) => (val) =>
!!val || `${'กรุณาเลือกลงวันที่ (เรื่อง ผลการสอบฯ)'}`, !!val || `${'กรุณาเลือกลงวันที่ (เรื่อง ผลการสอบฯ)'}`,

View file

@ -36,7 +36,7 @@ function nextPage(type: string, title: string) {
<q-item <q-item
clickable clickable
@click=" nextPage( '2', 'รายงานเรื่องร้องเรียนข้าราชการสามัญฯ ในสังกัดกรุงเทพมหานคร แยกตามหน่วยงาน' ) " @click=" nextPage( '2', 'รายงานเรื่องร้องเรียนข้าราชการสามัญ ฯ ในสังกัดกรุงเทพมหานคร แยกตามหน่วยงาน' ) "
dense dense
class="hover-green" class="hover-green"
> >
@ -44,14 +44,14 @@ function nextPage(type: string, title: string) {
<q-icon color="primary" name="mdi-file" size="xs" /> <q-icon color="primary" name="mdi-file" size="xs" />
</q-item-section> </q-item-section>
<q-item-section class="text-dark"> <q-item-section class="text-dark">
รายงานเรองรองเรยนขาราชการสามในสงกดกรงเทพมหานคร รายงานเรองรองเรยนขาราชการสาม ในสงกดกรงเทพมหานคร
แยกตามหนวยงาน แยกตามหนวยงาน
</q-item-section> </q-item-section>
</q-item> </q-item>
<q-item <q-item
clickable clickable
@click=" nextPage( '3', 'รายงานจำนวนข้าราชการสามัญฯ ที่กระทำความผิดทางวินัย แยกตามลักษณะความผิด' ) " @click=" nextPage( '3', 'รายงานจำนวนข้าราชการสามัญ ฯ ที่กระทำความผิดทางวินัย แยกตามลักษณะความผิด' ) "
dense dense
class="hover-green" class="hover-green"
> >
@ -59,7 +59,7 @@ function nextPage(type: string, title: string) {
<q-icon color="primary" name="mdi-file" size="xs" /> <q-icon color="primary" name="mdi-file" size="xs" />
</q-item-section> </q-item-section>
<q-item-section class="text-dark"> <q-item-section class="text-dark">
รายงานจำนวนขาราชการสามกระทำความผดทางว รายงานจำนวนขาราชการสาม กระทำความผดทางว
แยกตามลกษณะความผ แยกตามลกษณะความผ
</q-item-section> </q-item-section>
</q-item> </q-item>
@ -74,7 +74,7 @@ function nextPage(type: string, title: string) {
<q-icon color="primary" name="mdi-file" size="xs" /> <q-icon color="primary" name="mdi-file" size="xs" />
</q-item-section> </q-item-section>
<q-item-section class="text-dark"> <q-item-section class="text-dark">
รายงานรายชอขาราชการสาม รายงานรายชอขาราชการสาม
กระทำความผดทางวยแยกตามลกษณะความผ กระทำความผดทางวยแยกตามลกษณะความผ
</q-item-section> </q-item-section>
</q-item> </q-item>
@ -89,13 +89,13 @@ function nextPage(type: string, title: string) {
<q-icon color="primary" name="mdi-file" size="xs" /> <q-icon color="primary" name="mdi-file" size="xs" />
</q-item-section> </q-item-section>
<q-item-section class="text-dark"> <q-item-section class="text-dark">
รายงานจำนวนขาราชการสามกระทำความผดแยกตามระดบความผ รายงานจำนวนขาราชการสาม กระทำความผดแยกตามระดบความผ
</q-item-section> </q-item-section>
</q-item> </q-item>
<q-item <q-item
clickable clickable
@click=" nextPage( '6', 'รายงานรายชื่อข้าราชการสามัญฯ ที่กระทำความผิดทางวินัยแยกตามลักษณะความผิด' ) " @click=" nextPage( '6', 'รายงานรายชื่อข้าราชการสามัญ ฯ ที่กระทำความผิดทางวินัยแยกตามลักษณะความผิด' ) "
dense dense
class="hover-green" class="hover-green"
> >
@ -103,14 +103,14 @@ function nextPage(type: string, title: string) {
<q-icon color="primary" name="mdi-file" size="xs" /> <q-icon color="primary" name="mdi-file" size="xs" />
</q-item-section> </q-item-section>
<q-item-section class="text-dark"> <q-item-section class="text-dark">
รายงานรายชอขาราชการสาม รายงานรายชอขาราชการสาม
กระทำความผดทางวยแยกตามลกษณะความผ กระทำความผดทางวยแยกตามลกษณะความผ
</q-item-section> </q-item-section>
</q-item> </q-item>
<q-item <q-item
clickable clickable
@click=" nextPage( '7', 'รายงานจำนวนข้าราชการสามัญฯ ที่กระทำความผิดทางวินัยแต่ยุติเรื่อง แยกลักษณะความผิด' ) " @click=" nextPage( '7', 'รายงานจำนวนข้าราชการสามัญ ฯ ที่กระทำความผิดทางวินัยแต่ยุติเรื่อง แยกลักษณะความผิด' ) "
dense dense
class="hover-green" class="hover-green"
> >
@ -118,14 +118,14 @@ function nextPage(type: string, title: string) {
<q-icon color="primary" name="mdi-file" size="xs" /> <q-icon color="primary" name="mdi-file" size="xs" />
</q-item-section> </q-item-section>
<q-item-section class="text-dark"> <q-item-section class="text-dark">
รายงานจำนวนขาราชการสามกระทำความผดทางวยแตเรอง รายงานจำนวนขาราชการสาม กระทำความผดทางวยแตเรอง
แยกลกษณะความผ แยกลกษณะความผ
</q-item-section> </q-item-section>
</q-item> </q-item>
<q-item <q-item
clickable clickable
@click=" nextPage( '8', 'รายงานจำนวนข้าราชการสามัญฯ ที่กระทำความผิดทางวินัยแต่ยุติเรื่อง แยกตามตำแหน่ง' ) " @click=" nextPage( '8', 'รายงานจำนวนข้าราชการสามัญ ฯ ที่กระทำความผิดทางวินัยแต่ยุติเรื่อง แยกตามตำแหน่ง' ) "
dense dense
class="hover-green" class="hover-green"
> >
@ -133,7 +133,7 @@ function nextPage(type: string, title: string) {
<q-icon color="primary" name="mdi-file" size="xs" /> <q-icon color="primary" name="mdi-file" size="xs" />
</q-item-section> </q-item-section>
<q-item-section class="text-dark"> <q-item-section class="text-dark">
รายงานจำนวนขาราชการสามกระทำความผดทางวยแตเรอง รายงานจำนวนขาราชการสาม กระทำความผดทางวยแตเรอง
แยกตามตำแหน แยกตามตำแหน
</q-item-section> </q-item-section>
</q-item> </q-item>

View file

@ -22,13 +22,13 @@ export const useReportDataStore = defineStore("DisciplineReport11", () => {
]); ]);
const optionReport = ref<DataOption[]>([ const optionReport = ref<DataOption[]>([
{ id: "1", name: "รายงานเรื่องร้องเรียนแยกรายวัน รายเดือน รายปี" }, { id: "1", name: "รายงานเรื่องร้องเรียนแยกรายวัน รายเดือน รายปี" },
{ id: "2", name: "รายงานเรื่องร้องเรียนข้าราชการสามัญฯ ในสังกัดกรุงเทพมหานคร แยกตามหน่วยงาน" }, { id: "2", name: "รายงานเรื่องร้องเรียนข้าราชการสามัญ ฯ ในสังกัดกรุงเทพมหานคร แยกตามหน่วยงาน" },
{ id: "3", name: "รายงานจำนวนข้าราชการสามัญฯ ที่กระทำความผิดทางวินัย แยกตามลักษณะความผิด" }, { id: "3", name: "รายงานจำนวนข้าราชการสามัญ ฯ ที่กระทำความผิดทางวินัย แยกตามลักษณะความผิด" },
{ id: "4", name: "รายงานรายชื่อข้าราชการสามัญฯ ที่กระทำความผิดทางวินัยแยกตามลักษณะความผิด" }, { id: "4", name: "รายงานรายชื่อข้าราชการสามัญ ฯ ที่กระทำความผิดทางวินัยแยกตามลักษณะความผิด" },
{ id: "5", name: "รายงานจำนวนข้าราชการสามัญฯ ที่กระทำความผิดแยกตามระดับความผิด" }, { id: "5", name: "รายงานจำนวนข้าราชการสามัญ ฯ ที่กระทำความผิดแยกตามระดับความผิด" },
{ id: "6", name: "รายงานรายชื่อข้าราชการสามัญฯ ที่กระทำความผิดทางวินัยแยกตามลักษณะความผิด" }, { id: "6", name: "รายงานรายชื่อข้าราชการสามัญ ฯ ที่กระทำความผิดทางวินัยแยกตามลักษณะความผิด" },
{ id: "7", name: "รายงานจำนวนข้าราชการสามัญฯ ที่กระทำความผิดทางวินัยแต่ยุติเรื่อง แยกลักษณะความผิด" }, { id: "7", name: "รายงานจำนวนข้าราชการสามัญ ฯ ที่กระทำความผิดทางวินัยแต่ยุติเรื่อง แยกลักษณะความผิด" },
{ id: "8", name: "รายงานจำนวนข้าราชการสามัญฯ ที่กระทำความผิดทางวินัยแต่ยุติเรื่อง แยกตามตำแหน่ง" }, { id: "8", name: "รายงานจำนวนข้าราชการสามัญ ฯ ที่กระทำความผิดทางวินัยแต่ยุติเรื่อง แยกตามตำแหน่ง" },
]); ]);
/** /**

View file

@ -28,7 +28,7 @@ function closeDialog() {
> >
<thead> <thead>
<tr> <tr>
<th class="text-center">หลกเกณฑในการพจารณาเลอนข</th> <th class="text-center">หลกเกณฑในการพจารณาเลอนข </th>
<th class="text-center">หนงข</th> <th class="text-center">หนงข</th>
<th class="text-center">ครงข</th> <th class="text-center">ครงข</th>
<th class="text-center">ไมไดบการเลอนข</th> <th class="text-center">ไมไดบการเลอนข</th>

View file

@ -131,7 +131,7 @@ const columns = ref<QTableProps["columns"]>([
{ {
name: "result", name: "result",
align: "center", align: "center",
label: "ผลการประเมินฯ", label: "ผลการประเมิน ฯ",
sortable: false, sortable: false,
field: "result", field: "result",
headerStyle: "font-size: 14px", headerStyle: "font-size: 14px",

View file

@ -28,7 +28,7 @@ function closeDialog() {
> >
<thead> <thead>
<tr> <tr>
<th class="text-center">หลกเกณฑในการพจารณาเลอนข</th> <th class="text-center">หลกเกณฑในการพจารณาเลอนข </th>
<th class="text-center">หนงข</th> <th class="text-center">หนงข</th>
<th class="text-center">ครงข</th> <th class="text-center">ครงข</th>
<th class="text-center">ไมไดบการเลอนข</th> <th class="text-center">ไมไดบการเลอนข</th>

View file

@ -119,7 +119,7 @@ const columns = ref<QTableProps["columns"]>([
{ {
name: "result", name: "result",
align: "center", align: "center",
label: "ผลการประเมินฯ", label: "ผลการประเมิน ฯ",
sortable: false, sortable: false,
field: "result", field: "result",
headerStyle: "font-size: 14px", headerStyle: "font-size: 14px",

View file

@ -94,7 +94,7 @@ const columns = ref<QTableProps["columns"]>([
{ {
name: "groupRateHigh", name: "groupRateHigh",
align: "left", align: "left",
label: "อัตราค่าจ้างสูงกว่าฯ กลุ่มบัญชีค่าจ่าง", label: "อัตราค่าจ้างสูงกว่า ฯ กลุ่มบัญชีค่าจ่าง",
sortable: true, sortable: true,
field: "groupRateHigh", field: "groupRateHigh",
headerStyle: "font-size: 14px", headerStyle: "font-size: 14px",
@ -103,7 +103,7 @@ const columns = ref<QTableProps["columns"]>([
{ {
name: "rateHighMax", name: "rateHighMax",
align: "left", align: "left",
label: "อัตราค่าจ้างสูงกว่าฯ ขั้นสูงใหม่", label: "อัตราค่าจ้างสูงกว่า ฯ ขั้นสูงใหม่",
sortable: true, sortable: true,
field: "rateHighMax", field: "rateHighMax",
headerStyle: "font-size: 14px", headerStyle: "font-size: 14px",

View file

@ -169,7 +169,7 @@ export const useSalaryEmployeeListSDataStore = defineStore(
}, },
{ {
id: "emp2-13", id: "emp2-13",
name: "บัญชีรายละเอียดแสดงการเลื่อนขั้นค่าจ้างและให้ลูกจ้างประจำกรุงเทพมหานครได้รับอัตราค่าจ้างสูงกว่าฯ ที่เกษียณอายุราชการ ในสิ้นปีงบประมาณ (แนบท้ายคำสั่ง)", name: "บัญชีรายละเอียดแสดงการเลื่อนขั้นค่าจ้างและให้ลูกจ้างประจำกรุงเทพมหานครได้รับอัตราค่าจ้างสูงกว่า ฯ ที่เกษียณอายุราชการ ในสิ้นปีงบประมาณ (แนบท้ายคำสั่ง)",
}, },
{ {
id: "emp2-14", id: "emp2-14",

View file

@ -447,7 +447,7 @@ onMounted(() => {
dense dense
class="inputgreen" class="inputgreen"
v-model="formData.accept" v-model="formData.accept"
label="จํานวนงบประมาณที่ขอรับการจัดสรรฯ" label="จํานวนงบประมาณที่ขอรับการจัดสรร ฯ"
mask="###,###,###,###,###" mask="###,###,###,###,###"
reverse-fill-mask reverse-fill-mask
/> />
@ -460,7 +460,7 @@ onMounted(() => {
v-model="formData.receive" v-model="formData.receive"
mask="###,###,###,###,###" mask="###,###,###,###,###"
reverse-fill-mask reverse-fill-mask
label="จํานวนงบประมาณที่ได้รับการจัดสรรฯ" label="จํานวนงบประมาณที่ได้รับการจัดสรร ฯ"
/> />
</div> </div>
<div class="col-3"> <div class="col-3">

View file

@ -678,7 +678,7 @@ onMounted(() => {
checked-icon="task_alt" checked-icon="task_alt"
unchecked-icon="panorama_fish_eye" unchecked-icon="panorama_fish_eye"
val="INPLAN" val="INPLAN"
label="ในแผนฯ" label="ในแผน ฯ"
dense dense
/> />
<q-radio <q-radio
@ -686,7 +686,7 @@ onMounted(() => {
checked-icon="task_alt" checked-icon="task_alt"
unchecked-icon="panorama_fish_eye" unchecked-icon="panorama_fish_eye"
val="OUTPLAN" val="OUTPLAN"
label="นอกแผนฯ" label="นอกแผน ฯ"
dense dense
class="q-pl-sm" class="q-pl-sm"
/> />

View file

@ -44,7 +44,7 @@ onMounted(async () => {
<template> <template>
<div class="row items-center"> <div class="row items-center">
<div class="toptitle text-dark row items-center q-py-xs"> <div class="toptitle text-dark row items-center q-py-xs">
ตรากำลงลกจางประจำ ตรากำลงลกจางประจำ
</div> </div>
</div> </div>