API ที่ต้องปรับแก้ไข คำสั่งโปรดเกล้าฯ แต่งตั้งให้ดำรงตำแหน่ง #1780

This commit is contained in:
Bright 2025-08-27 10:38:47 +07:00
parent 6936846a41
commit 8a7417edf9
2 changed files with 63 additions and 20 deletions

View file

@ -2169,7 +2169,16 @@ export class CommandController extends Controller {
command.detailFooter = commandType.detailFooter;
command.isAttachment = commandType.isAttachment;
command.isUploadAttachment = commandType.isUploadAttachment;
command.status = "NEW";
// ถ้าเป็นคำสั่งโปรดเกล้าฯ "C-PM-47" ให้เปิดถึงรออัปโหลดไฟล์ #1780
if (commandCode === "C-PM-47") {
command.isSignature = true;
command.isDraft = true;
command.isSign = true;
command.status = "PENDING";
}
else {
command.status = "NEW";
}
command.issue = commandType.name;
(command.commandAffectDate = requestBody.commandAffectDate
? new Date(requestBody.commandAffectDate)