From b1d6888f584e78c3a126470e7a252a5dc07dc5e1 Mon Sep 17 00:00:00 2001 From: AnandaTon Date: Tue, 28 May 2024 12:52:08 +0700 Subject: [PATCH] =?UTF-8?q?=E0=B9=81=E0=B8=81=E0=B9=89=E0=B9=84=E0=B8=82?= =?UTF-8?q?=E0=B9=80=E0=B8=9E=E0=B8=B4=E0=B9=88=E0=B8=A1=E0=B9=80=E0=B8=95?= =?UTF-8?q?=E0=B8=B4=E0=B8=A1=20kk1?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/controllers/ProfileController.ts | 6 +++--- src/controllers/ProfileEmployeeController.ts | 6 +++--- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/src/controllers/ProfileController.ts b/src/controllers/ProfileController.ts index 16f64aaf..aec3db55 100644 --- a/src/controllers/ProfileController.ts +++ b/src/controllers/ProfileController.ts @@ -310,13 +310,13 @@ export class ProfileController extends Controller { BirthDay: profiles?.birthDate ? new Date(profiles.birthDate).getDate() : null, BirthDayText: profiles.birthDate != null - ? Extension.ToThaiNumber(Extension.ToThaiFullDate(profiles.birthDate)) + ? Extension.ToThaiNumber(Extension.ToThaiShortDate(profiles.birthDate)) : "", BirthMonth: profiles?.birthDate ? new Date(profiles.birthDate).getMonth() + 1 : null, // Months are zero-based BirthYear: profiles?.birthDate ? new Date(profiles.birthDate).getFullYear() : null, BirthYearText: profiles.birthDate != null - ? Extension.ToThaiNumber(Extension.ToThaiFullDate(profiles.birthDate)) + ? Extension.ToThaiNumber(Extension.ToThaiShortDate(profiles.birthDate)) : "", Address: "", District: "", @@ -417,7 +417,7 @@ export class ProfileController extends Controller { }); const salary = salarys.map((item) => ({ - SalaryDate: item.date ?? null, + SalaryDate: Extension.ToThaiShortDate(item.date) ?? null, Position: item.position ?? null, PosNo: item.posNo ?? null, Salary: "", diff --git a/src/controllers/ProfileEmployeeController.ts b/src/controllers/ProfileEmployeeController.ts index cec130a3..dbee92c5 100644 --- a/src/controllers/ProfileEmployeeController.ts +++ b/src/controllers/ProfileEmployeeController.ts @@ -323,13 +323,13 @@ export class ProfileEmployeeController extends Controller { BirthDay: profiles?.birthDate ? new Date(profiles.birthDate).getDate() : null, BirthDayText: profiles.birthDate != null - ? Extension.ToThaiNumber(Extension.ToThaiFullDate(profiles.birthDate)) + ? Extension.ToThaiNumber(Extension.ToThaiShortDate(profiles.birthDate)) : "", BirthMonth: profiles?.birthDate ? new Date(profiles.birthDate).getMonth() + 1 : null, // Months are zero-based BirthYear: profiles?.birthDate ? new Date(profiles.birthDate).getFullYear() : null, BirthYearText: profiles.birthDate != null - ? Extension.ToThaiNumber(Extension.ToThaiFullDate(profiles.birthDate)) + ? Extension.ToThaiNumber(Extension.ToThaiShortDate(profiles.birthDate)) : "", Address: "", District: "", @@ -430,7 +430,7 @@ export class ProfileEmployeeController extends Controller { }); const salary = salarys.map((item) => ({ - SalaryDate: item.date ?? null, + SalaryDate: Extension.ToThaiShortDate(item.date) ?? null, Position: item.position ?? null, PosNo: item.posNo ?? null, Salary: "",