From 549bbfcf524b06ae6a3d313638648b1dbbb68a3a Mon Sep 17 00:00:00 2001 From: kittapath Date: Mon, 13 Jan 2025 15:12:44 +0700 Subject: [PATCH] report 13 --- .../Repositories/Reports/ProbationReportRepository.cs | 10 ++++++++++ .../Responses/ProbationAssignResponse.cs | 1 + 2 files changed, 11 insertions(+) diff --git a/BMA.EHR.Application/Repositories/Reports/ProbationReportRepository.cs b/BMA.EHR.Application/Repositories/Reports/ProbationReportRepository.cs index acf4aa37..9c99690c 100644 --- a/BMA.EHR.Application/Repositories/Reports/ProbationReportRepository.cs +++ b/BMA.EHR.Application/Repositories/Reports/ProbationReportRepository.cs @@ -82,6 +82,15 @@ namespace BMA.EHR.Application.Repositories.Reports : (Regex.Replace(x.description, "<.*?>", string.Empty)).Replace(" ", " ").ToString().ToThaiNumber(), }).ToList(); + var competencyGroups = probation_assign.result.competency_groups.Select(x => new + { + name = string.IsNullOrEmpty(x.name) ? string.Empty : x.name.ToThaiNumber(), + level = string.IsNullOrEmpty(x.level) ? string.Empty : x.level.ToThaiNumber(), + description = string.IsNullOrEmpty(x.description) + ? string.Empty + : (Regex.Replace(x.description, "<.*?>", string.Empty)).Replace(" ", " ").ToString().ToThaiNumber(), + }).ToList(); + var outputs = probation_assign.result.outputs.Select(x => new { id = string.IsNullOrEmpty(x.id.ToString()) ? string.Empty : x.id.ToString().ToThaiNumber(), @@ -126,6 +135,7 @@ namespace BMA.EHR.Application.Repositories.Reports Jobs = jobs, Knowledges = knowledges, Competencys = competencys, + CompetencyGroups = competencyGroups, Outputs = outputs, Skills = skills, Laws = laws, diff --git a/BMA.EHR.Application/Responses/ProbationAssignResponse.cs b/BMA.EHR.Application/Responses/ProbationAssignResponse.cs index 6497aa7a..52f21da0 100644 --- a/BMA.EHR.Application/Responses/ProbationAssignResponse.cs +++ b/BMA.EHR.Application/Responses/ProbationAssignResponse.cs @@ -14,6 +14,7 @@ public List jobs { get; set; } public List knowledges { get; set; } public List competencys { get; set; } + public List competency_groups { get; set; } public List outputs { get; set; } public List laws { get; set; } public List skills { get; set; }