แก้รายงาน เปลี่ยน font => THSarabunPSK และแก้การแสดงผลเลขไทย
This commit is contained in:
parent
122fe5be90
commit
3fc878f340
42 changed files with 331 additions and 309 deletions
|
|
@ -47,20 +47,20 @@ namespace BMA.EHR.Domain.Extensions
|
|||
{
|
||||
string arabicNumbers = "0123456789";
|
||||
string thaiNumbers = "๐๑๒๓๔๕๖๗๘๙";
|
||||
StringBuilder ThaiYear = new StringBuilder();
|
||||
StringBuilder result = new StringBuilder();
|
||||
foreach (char digit in value)
|
||||
{
|
||||
int index = arabicNumbers.IndexOf(digit);
|
||||
if (index >= 0)
|
||||
{
|
||||
ThaiYear.Append(thaiNumbers[index]);
|
||||
result.Append(thaiNumbers[index]);
|
||||
}
|
||||
else
|
||||
{
|
||||
ThaiYear.Append(digit);
|
||||
result.Append(digit);
|
||||
}
|
||||
}
|
||||
return ThaiYear.ToString();
|
||||
return result.ToString();
|
||||
}
|
||||
}
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue