From 0fbb5b928ee70fe3b8ff9f7c1cb5bcdadb29e240 Mon Sep 17 00:00:00 2001 From: AdisakKanthawilang Date: Tue, 5 Aug 2025 14:52:19 +0700 Subject: [PATCH] fix #1305 --- src/controllers/CommandController.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/controllers/CommandController.ts b/src/controllers/CommandController.ts index e0b3240b..6724eabb 100644 --- a/src/controllers/CommandController.ts +++ b/src/controllers/CommandController.ts @@ -6658,8 +6658,8 @@ export class CommandController extends Controller { createdAt: new Date(), lastUpdatedAt: new Date(), commandNo: firstRef.commandNo ?? null, - refCommandNo: `${firstRef.commandNo ?? ""}/${firstRef.commandYear ?? ""}`, - commandYear: firstRef.commandYear ?? null, + refCommandNo: `${firstRef.commandNo ?? ""}/${firstRef.commandYear ? Extension.ToThaiYear(firstRef.commandYear) : ""}`, + commandYear: firstRef.commandYear ? Extension.ToThaiYear(firstRef.commandYear) : null, posNo: orgShortName && item.posMaster?.posMasterNo ? `${orgShortName} ${item.posMaster.posMasterNo}`