From 410a92820d9e94fc23e0c5b9779502ec7a744aad Mon Sep 17 00:00:00 2001 From: "DESKTOP-2S5P7D1\\Windows 10" Date: Tue, 5 Sep 2023 10:57:26 +0700 Subject: [PATCH] =?UTF-8?q?=E0=B8=A7=E0=B8=B1=E0=B8=99=E0=B8=97=E0=B8=B5?= =?UTF-8?q?=E0=B9=88=E0=B8=A3=E0=B8=AD=E0=B8=9A=E0=B9=80=E0=B8=84=E0=B8=A3?= =?UTF-8?q?=E0=B8=B7=E0=B9=88=E0=B8=AD=E0=B8=87=E0=B8=A3=E0=B8=B2=E0=B8=8A?= =?UTF-8?q?=E0=B8=A3=E0=B8=B2=E0=B8=A2=E0=B8=87=E0=B8=B2=E0=B8=99?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../Reports/InsigniaReportRepository.cs | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/BMA.EHR.Application/Repositories/Reports/InsigniaReportRepository.cs b/BMA.EHR.Application/Repositories/Reports/InsigniaReportRepository.cs index 8489d506..e1f0e6cd 100644 --- a/BMA.EHR.Application/Repositories/Reports/InsigniaReportRepository.cs +++ b/BMA.EHR.Application/Repositories/Reports/InsigniaReportRepository.cs @@ -65,6 +65,19 @@ namespace BMA.EHR.Application.Repositories.Reports return period; } + public async Task GetDateInsigniaPeriod(Guid id) + { + var period = await _dbContext.Set() + .FirstOrDefaultAsync(x => x.Id == id); + if (period == null) + throw new Exception(GlobalMessages.InsigniaPeriodNotFound); + return new + { + StartDater = period.StartDate.ToThaiFullDate().ToString().ToThaiNumber(), + EndDate = period.EndDate.ToThaiFullDate().ToString().ToThaiNumber(), + }; + } + public async Task GetKhr1Report(Guid id) { var period = await _dbContext.Set()