diff --git a/BMA.EHR.Application/Repositories/Reports/ProbationReportRepository.cs b/BMA.EHR.Application/Repositories/Reports/ProbationReportRepository.cs index 29de906b..102c256d 100644 --- a/BMA.EHR.Application/Repositories/Reports/ProbationReportRepository.cs +++ b/BMA.EHR.Application/Repositories/Reports/ProbationReportRepository.cs @@ -89,6 +89,17 @@ namespace BMA.EHR.Application.Repositories.Reports output_desc = string.IsNullOrEmpty(x.output_desc) ? string.Empty : x.output_desc.ToThaiNumber(), }).ToList(); + var skills = probation_assign.result.skills.Select(x => new + { + id = string.IsNullOrEmpty(x.id.ToString()) ? string.Empty : x.id.ToString().ToThaiNumber(), + title = string.IsNullOrEmpty(x.title) ? string.Empty : x.title.ToThaiNumber(), + description = string.IsNullOrEmpty(x.description) ? string.Empty : x.description.ToThaiNumber(), + }).ToList(); + + var laws = probation_assign.result.laws.Where(x => x.selected == true).Select((x, Index) => new + { + title = string.IsNullOrEmpty(x.description) ? string.Empty : $"{Index + 1}. {x.description.ToThaiNumber()}", + }).ToList(); return new { diff --git a/BMA.EHR.Application/Responses/ProbationAssignResponse.cs b/BMA.EHR.Application/Responses/ProbationAssignResponse.cs index a96a9204..1a5a0e15 100644 --- a/BMA.EHR.Application/Responses/ProbationAssignResponse.cs +++ b/BMA.EHR.Application/Responses/ProbationAssignResponse.cs @@ -15,6 +15,8 @@ public List knowledges { get; set; } public List competencys { get; set; } public List outputs { get; set; } + public List laws { get; set; } + public List skills { get; set; } } public class Profile @@ -73,6 +75,20 @@ public string description { get; set; } = string.Empty; } + public class Skill + { + public int id { get; set; } + public string title { get; set; } = string.Empty; + public string description { get; set; } = string.Empty; + } + + public class Law + { + public int id { get; set; } + public string description { get; set; } = string.Empty; + public bool selected { get; set; } + } + public class Competency { public string id { get; set; } = string.Empty;