ประเมิน

This commit is contained in:
DESKTOP-1R2VSQH\Lenovo ThinkPad E490 2024-05-27 11:59:26 +07:00
parent 6b1a397ac6
commit 8d0ac4eb7c
4 changed files with 18 additions and 50 deletions

View file

@ -130,7 +130,7 @@ function onSubmit() {
? commanderHighId.value.id
: null,
})
.then((res) => {
.then(() => {
success($q, "บันทึกสำเร็จ");
close();
})
@ -246,13 +246,11 @@ function filterOption(val: any, update: Function, refData: string) {
// getAll();
// }
async function getAll() {
await getProfile();
await fetchEvaluation();
await store.checkStep();
await getOrgOp();
function getAll() {
getProfile();
fetchEvaluation();
store.checkStep();
getOrgOp();
}
function sendToEvaluatore(status: string) {
@ -265,7 +263,7 @@ function sendToEvaluatore(status: string) {
.put(config.API.kpiSendToStatus(id.value), {
status: status,
})
.then((res) => {
.then(() => {
success($q, "ส่งข้อตกลงให้ผู้ประเมินอนุมัติสำเร็จ");
close();
})
@ -292,7 +290,7 @@ function requireEdit() {
.put(config.API.kpiReqEdit(id.value), {
status: "EVALUATOR",
})
.then((res) => {
.then(() => {
success($q, "ขอแก้ไขสำเร็จ");
close();
})
@ -309,10 +307,9 @@ function requireEdit() {
);
}
onMounted(async () => {
onMounted(() => {
showLoader();
await getAll();
console.log(store.dataEvaluation.avartar);
getAll();
});
</script>

View file

@ -272,11 +272,11 @@ function onSubmit() {
function getProfile() {
http
.get(config.API.profilePosition())
.then((res) => {
.then(async (res) => {
const data = res.data.result;
store.dataProfile = data;
store.checkCompetency();
store.checkCompetencyDefaultCompetencyLevel();
await store.checkCompetency();
await store.checkCompetencyDefaultCompetencyLevel();
formRound.profileId = data.profileId;
formRound.prefix = data.prefix;