issue แปลงเอาเลขไทย #1249 && เอาเดือนออก #1248

This commit is contained in:
Bright 2025-03-17 13:43:54 +07:00
parent a03ce9d55a
commit b0358de9cb
4 changed files with 43 additions and 36 deletions

View file

@ -228,6 +228,13 @@ class Extension {
);
}
public static ToThaiShortDate_monthYear2(value: Date) {
let yy = value.getFullYear() < 2400 ? value.getFullYear() + 543 : value.getFullYear();
return (
value.getDate() + " " + Extension.ToThaiMonth(value.getMonth() + 1) + " พ.ศ. " + yy
);
}
public static ToThaiShortYear(value: Date) {
let yy = value.getFullYear() < 2400 ? value.getFullYear() + 543 : value.getFullYear();
return yy.toString();