This commit is contained in:
AdisakKanthawilang 2025-08-20 12:14:01 +07:00
parent ee5451566d
commit 7bdecb7205

View file

@ -1158,6 +1158,24 @@ export class KpiUserEvaluationController extends Controller {
})
.then(() => {})
.catch(() => {});
} else if (requestBody.status.trim().toUpperCase() == "APPROVE") { // ทุกขั้นอนุมัติแล้วส่งกลับไปหาผู้ขอประเมินเพื่อส่งขอทำการประเมินต่อ
await new CallAPI()
.PostData(request, "/placement/noti/profiles", {
subject: `ผู้ประเมินและผู้บังคับบัญชาอนุมัติข้อตกลงการประเมินผลฯ สามารถดำเนินการขั้นตอนต่อไปได้`,
body: `ผู้ประเมินและผู้บังคับบัญชาอนุมัติข้อตกลงการประเมินผลฯ สามารถดำเนินการขั้นตอนต่อไปได้`,
receiverUserIds: [
{
receiverUserId: kpiUserEvaluation.evaluatorId,
notiLink: `${process.env.USER_NOTI_URL}/KPI-evaluator/${kpiUserEvaluation.id}`,
},
],
payload: "",
isSendMail: true,
isSendInbox: true,
isSendNotification: true,
})
.then(() => {})
.catch(() => {});
}
const before = structuredClone(kpiUserEvaluation);
let _null: any = null;