diff --git a/BMA.EHR.Application/Repositories/Commands/CommandReportRepository.cs b/BMA.EHR.Application/Repositories/Commands/CommandReportRepository.cs index aa6f5fbd..309e14a0 100644 --- a/BMA.EHR.Application/Repositories/Commands/CommandReportRepository.cs +++ b/BMA.EHR.Application/Repositories/Commands/CommandReportRepository.cs @@ -763,6 +763,8 @@ namespace BMA.EHR.Application.Repositories.Commands .ThenInclude(p => p.Position) .Include(p => p.Profile) .ThenInclude(p => p.Salaries) + .Include(p => p.Profile) + .ThenInclude(p => p.Prefix) on r.RefPlacementProfileId equals p.Id orderby r.Sequence select new CommandType16Response @@ -777,7 +779,8 @@ namespace BMA.EHR.Application.Repositories.Commands GovAidCommandDate = r.Command.GovAidCommandDate == null ? "" : r.Command.GovAidCommandDate.Value.ToThaiFullDate3().ToThaiNumber(), StartDate = "", // TODO: Frontend ไม่มีการเก็บค่าไว้ หรือไม่มีเก็บไว้จากระบบบรรจุ ทำให้ดึงมาแสดงไม่ได้ - ActiveDate = p.Date == null ? "" : p.Date.Value.ToThaiFullDate3().ToThaiNumber() + ActiveDate = p.Date == null ? "" : p.Date.Value.ToThaiFullDate3().ToThaiNumber(), + FullName = $"{p.Profile.Prefix!.Name}{p.Profile.FirstName!} {p.Profile.LastName!}" }) .ToList(); @@ -1019,20 +1022,31 @@ namespace BMA.EHR.Application.Repositories.Commands .ThenInclude(x => x.PositionType) .Include(x => x.Profile) .ThenInclude(x => x.PosNo) + .Include(x => x.OrgEmployee) + .ThenInclude(x => x.OrganizationAgency) + .ThenInclude(x => x.OrganizationOrganization) + //.Include(x => x.OrgEmployee) + //.ThenInclude(x => x.PosNo) + .Include(x => x.OrgEmployee) + .ThenInclude(x => x.PositionEmployeePosition) + .Include(x => x.OrgEmployee) + .ThenInclude(x => x.OrganizationPositionEmployeeLevels) + .ThenInclude(x => x.PositionEmployeeLevel) on r.RefPlacementProfileId equals p.Id orderby r.Sequence select new CommandType21Response { Seq = r.Sequence.ToString().ToThaiNumber(), - CitizenId = r.CitizenId, + CitizenId = r.CitizenId.ToThaiNumber(), FullName = $"{r.Prefix}{r.FirstName} {r.LastName}", - Organization = p.Profile!.EmployeeOc, - PositionName = p.Profile.Position == null ? "" : p.Profile.Position.Name, - PositionLevel = p.Profile.PositionLevel == null ? "" : p.Profile.PositionLevel.Name, - PositionType = p.Profile.PositionType == null ? "" : p.Profile.PositionType.Name, - PositionNumber = p.Profile.PosNo == null ? "" : p.Profile.PosNo.Name.ToThaiNumber(), + Organization = p.OrgEmployee!.OrganizationAgency!.OrganizationOrganization!.Name, + PositionName = p.OrgEmployee.PositionEmployeePosition == null ? "" : p.OrgEmployee.PositionEmployeePosition.Name.ToThaiNumber(), + PositionLevel = p.OrgEmployee.OrganizationPositionEmployeeLevels == null ? "" : p.OrgEmployee.OrganizationPositionEmployeeLevels.First().PositionEmployeeLevel.Name.ToThaiNumber(), + PositionType = p.Profile.PositionType == null ? "" : p.Profile.PositionType.Name.ToThaiNumber(), + PositionNumber = p.OrgEmployee.PosNo == null ? "" : p.OrgEmployee.PosNo.ToThaiNumber(), Salary = r.Amount == null ? "" : r.Amount.Value.ToNumericNoDecimalText().ToThaiNumber(), - RetireDate = p.Profile.BirthDate.CalculateRetireDate().ToThaiFullDate3().ToThaiNumber() + RetireDate = p.Profile.BirthDate.CalculateRetireDate().ToThaiFullDate3().ToThaiNumber(), + CommandYear = r.Command.CommandYear.ToInteger().ToThaiYear().ToString().ToThaiNumber() }) .ToList(); diff --git a/BMA.EHR.Application/Responses/Reports/CommandType16Response.cs b/BMA.EHR.Application/Responses/Reports/CommandType16Response.cs index 22a10cef..8208cab2 100644 --- a/BMA.EHR.Application/Responses/Reports/CommandType16Response.cs +++ b/BMA.EHR.Application/Responses/Reports/CommandType16Response.cs @@ -27,5 +27,7 @@ namespace BMA.EHR.Application.Responses.Reports public string StartDate { get; set; } = string.Empty; public string ActiveDate { get; set; } = string.Empty; + + public string FullName { get; set;} = string.Empty; } } diff --git a/BMA.EHR.Application/Responses/Reports/CommandType21Response.cs b/BMA.EHR.Application/Responses/Reports/CommandType21Response.cs index 7823d041..51fcfc7e 100644 --- a/BMA.EHR.Application/Responses/Reports/CommandType21Response.cs +++ b/BMA.EHR.Application/Responses/Reports/CommandType21Response.cs @@ -21,5 +21,7 @@ public string Salary { get; set; } = string.Empty; public string RetireDate { get; set;} = string.Empty; + + public string CommandYear { get; set; } = string.Empty; } } diff --git a/BMA.EHR.Report.Service/Reports/20-คำสั่งแต่งตั้งลูกจ้างชั่วคราวเป็นลูกจ้างประจำ-2.trdp b/BMA.EHR.Report.Service/Reports/20-คำสั่งแต่งตั้งลูกจ้างชั่วคราวเป็นลูกจ้างประจำ-2.trdp index 7e411d61..311a2f23 100644 Binary files a/BMA.EHR.Report.Service/Reports/20-คำสั่งแต่งตั้งลูกจ้างชั่วคราวเป็นลูกจ้างประจำ-2.trdp and b/BMA.EHR.Report.Service/Reports/20-คำสั่งแต่งตั้งลูกจ้างชั่วคราวเป็นลูกจ้างประจำ-2.trdp differ diff --git a/BMA.EHR.Report.Service/Reports/30-คำสั่งส่งตัวกลับไปปฏิบัติงานทางต้นสังกัดเดิม.trdp b/BMA.EHR.Report.Service/Reports/30-คำสั่งส่งตัวกลับไปปฏิบัติงานทางต้นสังกัดเดิม.trdp index a3d26f88..c8ec0341 100644 Binary files a/BMA.EHR.Report.Service/Reports/30-คำสั่งส่งตัวกลับไปปฏิบัติงานทางต้นสังกัดเดิม.trdp and b/BMA.EHR.Report.Service/Reports/30-คำสั่งส่งตัวกลับไปปฏิบัติงานทางต้นสังกัดเดิม.trdp differ