แก้ระบบบรรจุผูกโครงสร้างใหม่
This commit is contained in:
parent
57164f5d45
commit
18d75f4b04
37 changed files with 79295 additions and 3904 deletions
|
|
@ -304,21 +304,21 @@ namespace BMA.EHR.Application.Repositories.Commands
|
|||
|
||||
var report_data = (from r in raw_data
|
||||
join p in _dbContext.Set<PlacementAppointment>()
|
||||
.Include(x => x.OrganizationPosition)
|
||||
.ThenInclude(x => x.Organization)
|
||||
.Include(x => x.PositionPath)
|
||||
.Include(x => x.PositionLevel)
|
||||
.Include(x => x.PositionNumber)
|
||||
.Include(x => x.PositionType)
|
||||
// .Include(x => x.OrganizationPosition)
|
||||
// .ThenInclude(x => x.Organization)
|
||||
// .Include(x => x.PositionPath)
|
||||
// .Include(x => x.PositionLevel)
|
||||
// .Include(x => x.PositionNumber)
|
||||
// .Include(x => x.PositionType)
|
||||
on r.RefPlacementProfileId equals p.Id
|
||||
join pf in _dbContext.Set<Profile>()
|
||||
.Include(x => x.Position)
|
||||
.Include(x => x.PositionLevel)
|
||||
.Include(x => x.PositionType)
|
||||
.Include(x => x.PosNo)
|
||||
.Include(x => x.Salaries)
|
||||
.Include(x => x.Educations)
|
||||
on r.CitizenId equals pf.CitizenId
|
||||
// join pf in _dbContext.Set<Profile>()
|
||||
// .Include(x => x.Position)
|
||||
// .Include(x => x.PositionLevel)
|
||||
// .Include(x => x.PositionType)
|
||||
// .Include(x => x.PosNo)
|
||||
// .Include(x => x.Salaries)
|
||||
// .Include(x => x.Educations)
|
||||
// on r.CitizenId equals pf.CitizenId
|
||||
orderby r.Sequence
|
||||
select new CommandType03Response
|
||||
{
|
||||
|
|
@ -328,19 +328,19 @@ namespace BMA.EHR.Application.Repositories.Commands
|
|||
Seq = r.Sequence.ToString().ToThaiNumber(),
|
||||
CitizenId = r.CitizenId,
|
||||
FullName = $"{r.Prefix}{r.FirstName} {r.LastName}",
|
||||
OldOc = pf.Oc == null ? "" : pf.Oc.Replace("/", " "),
|
||||
OldPositionName = pf.Position == null ? "" : pf.Position.Name,
|
||||
OldPositionLevel = pf.PositionLevel == null ? "" : pf.PositionLevel.Name,
|
||||
OldPositionType = pf.PositionType == null ? "" : pf.PositionType.Name,
|
||||
OldPositionNumber = pf.PosNo == null ? "" : pf.PosNo.Name.ToThaiNumber(),
|
||||
// OldOc = pf.Oc == null ? "" : pf.Oc.Replace("/", " "),
|
||||
// OldPositionName = pf.Position == null ? "" : pf.Position.Name,
|
||||
// OldPositionLevel = pf.PositionLevel == null ? "" : pf.PositionLevel.Name,
|
||||
// OldPositionType = pf.PositionType == null ? "" : pf.PositionType.Name,
|
||||
// OldPositionNumber = pf.PosNo == null ? "" : pf.PosNo.Name.ToThaiNumber(),
|
||||
// OldSalary = pf.Salaries == null || pf.Salaries.Count == 0 ? "" : pf.Salaries.OrderByDescending(x => x.Order).FirstOrDefault().Amount.Value.ToNumericNoDecimalText().ToThaiNumber(),
|
||||
OldSalary = p.AmountOld == null ? "" : p.AmountOld.Value.ToNumericNoDecimalText().ToThaiNumber(),
|
||||
OldSalaryDate = pf.Salaries == null || pf.Salaries.Count == 0 ? "" : pf.Salaries.OrderByDescending(x => x.Order).FirstOrDefault().Date.Value.ToThaiShortDate2().ToThaiNumber(),
|
||||
NewOc = p.OrganizationPosition == null || p.OrganizationPosition!.Organization == null ? "" : _organizationCommonRepository.GetOrganizationNameFullPath(p.OrganizationPosition!.Organization!.Id, false, false, "/"),
|
||||
NewPositionName = p.PositionPath == null ? "" : p.PositionPath!.Name,
|
||||
NewPositionLevel = p.PositionLevel == null ? "" : p.PositionLevel.Name,
|
||||
NewPositionType = p.PositionType == null ? "" : p.PositionType.Name,
|
||||
NewPositionNumber = p.PositionNumber == null ? "" : p.PositionNumber.Name.ToThaiNumber(),
|
||||
// OldSalaryDate = pf.Salaries == null || pf.Salaries.Count == 0 ? "" : pf.Salaries.OrderByDescending(x => x.Order).FirstOrDefault().Date.Value.ToThaiShortDate2().ToThaiNumber(),
|
||||
// NewOc = p.OrganizationPosition == null || p.OrganizationPosition!.Organization == null ? "" : _organizationCommonRepository.GetOrganizationNameFullPath(p.OrganizationPosition!.Organization!.Id, false, false, "/"),
|
||||
// NewPositionName = p.PositionPath == null ? "" : p.PositionPath!.Name,
|
||||
// NewPositionLevel = p.PositionLevel == null ? "" : p.PositionLevel.Name,
|
||||
// NewPositionType = p.PositionType == null ? "" : p.PositionType.Name,
|
||||
// NewPositionNumber = p.PositionNumber == null ? "" : p.PositionNumber.Name.ToThaiNumber(),
|
||||
NewSalary = r.Amount == null ? "" : r.Amount.Value.ToNumericNoDecimalText().ToThaiNumber(),
|
||||
AppointDate = p.RecruitDate == null ? "" : p.RecruitDate.Value.ToThaiShortDate2().ToThaiNumber(),
|
||||
Reason = p.Reason == null ? "-" : p.Reason,
|
||||
|
|
@ -370,21 +370,21 @@ namespace BMA.EHR.Application.Repositories.Commands
|
|||
|
||||
var report_data = (from r in raw_data
|
||||
join p in _dbContext.Set<PlacementAppointment>()
|
||||
.Include(x => x.OrganizationPosition)
|
||||
.ThenInclude(x => x.Organization)
|
||||
.Include(x => x.PositionPath)
|
||||
.Include(x => x.PositionLevel)
|
||||
.Include(x => x.PositionNumber)
|
||||
.Include(x => x.PositionType)
|
||||
// .Include(x => x.OrganizationPosition)
|
||||
// .ThenInclude(x => x.Organization)
|
||||
// .Include(x => x.PositionPath)
|
||||
// .Include(x => x.PositionLevel)
|
||||
// .Include(x => x.PositionNumber)
|
||||
// .Include(x => x.PositionType)
|
||||
on r.RefPlacementProfileId equals p.Id
|
||||
join pf in _dbContext.Set<Profile>()
|
||||
.Include(x => x.Position)
|
||||
.Include(x => x.PositionLevel)
|
||||
.Include(x => x.PositionType)
|
||||
.Include(x => x.PosNo)
|
||||
.Include(x => x.Salaries)
|
||||
.Include(x => x.Educations)
|
||||
on r.CitizenId equals pf.CitizenId
|
||||
// join pf in _dbContext.Set<Profile>()
|
||||
// .Include(x => x.Position)
|
||||
// .Include(x => x.PositionLevel)
|
||||
// .Include(x => x.PositionType)
|
||||
// .Include(x => x.PosNo)
|
||||
// .Include(x => x.Salaries)
|
||||
// .Include(x => x.Educations)
|
||||
// on r.CitizenId equals pf.CitizenId
|
||||
orderby r.Sequence
|
||||
select new CommandType03Response
|
||||
{
|
||||
|
|
@ -394,18 +394,18 @@ namespace BMA.EHR.Application.Repositories.Commands
|
|||
Seq = r.Sequence.ToString().ToThaiNumber(),
|
||||
CitizenId = r.CitizenId,
|
||||
FullName = $"{r.Prefix}{r.FirstName} {r.LastName}",
|
||||
OldOc = pf.Oc == null ? "" : pf.Oc.Replace("/", " "),
|
||||
OldPositionName = pf.Position == null ? "" : pf.Position.Name,
|
||||
OldPositionLevel = pf.PositionLevel == null ? "" : pf.PositionLevel.Name,
|
||||
OldPositionType = pf.PositionType == null ? "" : pf.PositionType.Name,
|
||||
OldPositionNumber = pf.PosNo == null ? "" : pf.PosNo.Name.ToThaiNumber(),
|
||||
// OldOc = pf.Oc == null ? "" : pf.Oc.Replace("/", " "),
|
||||
// OldPositionName = pf.Position == null ? "" : pf.Position.Name,
|
||||
// OldPositionLevel = pf.PositionLevel == null ? "" : pf.PositionLevel.Name,
|
||||
// OldPositionType = pf.PositionType == null ? "" : pf.PositionType.Name,
|
||||
// OldPositionNumber = pf.PosNo == null ? "" : pf.PosNo.Name.ToThaiNumber(),
|
||||
// OldSalary = pf.Salaries == null || pf.Salaries.Count == 0 ? "" : pf.Salaries.OrderByDescending(x => x.Order).FirstOrDefault().Amount.Value.ToNumericNoDecimalText().ToThaiNumber(),
|
||||
OldSalary = p.AmountOld == null ? "" : p.AmountOld.Value.ToNumericNoDecimalText().ToThaiNumber(),
|
||||
NewOc = p.OrganizationPosition == null || p.OrganizationPosition!.Organization == null ? "" : _organizationCommonRepository.GetOrganizationNameFullPath(p.OrganizationPosition!.Organization!.Id, false, false, "/"),
|
||||
NewPositionName = p.PositionPath == null ? "" : p.PositionPath!.Name,
|
||||
NewPositionLevel = p.PositionLevel == null ? "" : p.PositionLevel.Name,
|
||||
NewPositionType = p.PositionType == null ? "" : p.PositionType.Name,
|
||||
NewPositionNumber = p.PositionNumber == null ? "" : p.PositionNumber.Name.ToThaiNumber(),
|
||||
// NewOc = p.OrganizationPosition == null || p.OrganizationPosition!.Organization == null ? "" : _organizationCommonRepository.GetOrganizationNameFullPath(p.OrganizationPosition!.Organization!.Id, false, false, "/"),
|
||||
// NewPositionName = p.PositionPath == null ? "" : p.PositionPath!.Name,
|
||||
// NewPositionLevel = p.PositionLevel == null ? "" : p.PositionLevel.Name,
|
||||
// NewPositionType = p.PositionType == null ? "" : p.PositionType.Name,
|
||||
// NewPositionNumber = p.PositionNumber == null ? "" : p.PositionNumber.Name.ToThaiNumber(),
|
||||
NewSalary = r.Amount == null ? "" : r.Amount.Value.ToNumericNoDecimalText().ToThaiNumber(),
|
||||
AppointDate = p.RecruitDate == null ? "" : p.RecruitDate.Value.ToThaiShortDate2().ToThaiNumber(),
|
||||
Reason = p.Reason == null ? "-" : p.Reason,
|
||||
|
|
@ -435,24 +435,24 @@ namespace BMA.EHR.Application.Repositories.Commands
|
|||
|
||||
var report_data = (from r in raw_data
|
||||
join p in _dbContext.Set<RetirementOther>()
|
||||
.Include(x => x.Profile)
|
||||
.ThenInclude(x => x.Salaries)
|
||||
.Include(x => x.Profile)
|
||||
.ThenInclude(x => x.Position)
|
||||
.Include(x => x.Profile)
|
||||
.ThenInclude(x => x.PositionLevel)
|
||||
.Include(x => x.Profile)
|
||||
.ThenInclude(x => x.PositionType)
|
||||
.Include(x => x.Profile)
|
||||
.ThenInclude(x => x.PosNo)
|
||||
.Include(x => x.Profile)
|
||||
.ThenInclude(x => x.Educations)
|
||||
.Include(x => x.OrganizationPosition)
|
||||
.ThenInclude(x => x.Organization)
|
||||
.Include(x => x.PositionPath)
|
||||
.Include(x => x.PositionLevel)
|
||||
.Include(x => x.PositionNumber)
|
||||
.Include(x => x.PositionType)
|
||||
// .Include(x => x.Profile)
|
||||
// .ThenInclude(x => x.Salaries)
|
||||
// .Include(x => x.Profile)
|
||||
// .ThenInclude(x => x.Position)
|
||||
// .Include(x => x.Profile)
|
||||
// .ThenInclude(x => x.PositionLevel)
|
||||
// .Include(x => x.Profile)
|
||||
// .ThenInclude(x => x.PositionType)
|
||||
// .Include(x => x.Profile)
|
||||
// .ThenInclude(x => x.PosNo)
|
||||
// .Include(x => x.Profile)
|
||||
// .ThenInclude(x => x.Educations)
|
||||
// .Include(x => x.OrganizationPosition)
|
||||
// .ThenInclude(x => x.Organization)
|
||||
// .Include(x => x.PositionPath)
|
||||
// .Include(x => x.PositionLevel)
|
||||
// .Include(x => x.PositionNumber)
|
||||
// .Include(x => x.PositionType)
|
||||
on r.RefPlacementProfileId equals p.Id
|
||||
orderby r.Sequence
|
||||
select new CommandType03Response
|
||||
|
|
@ -463,21 +463,21 @@ namespace BMA.EHR.Application.Repositories.Commands
|
|||
Seq = r.Sequence.ToString().ToThaiNumber(),
|
||||
CitizenId = r.CitizenId,
|
||||
FullName = $"{r.Prefix}{r.FirstName} {r.LastName}",
|
||||
OldOc = p.Profile.Oc == null ? "" : p.Profile.Oc.Replace("/", " "),
|
||||
OldPositionName = p.Profile.Position == null ? "" : p.Profile.Position.Name,
|
||||
OldPositionLevel = p.Profile.PositionLevel == null ? "" : p.Profile.PositionLevel.Name,
|
||||
OldPositionType = p.Profile.PositionType == null ? "" : p.Profile.PositionType.Name,
|
||||
OldPositionNumber = p.Profile.PosNo == null ? "" : p.Profile.PosNo.Name.ToThaiNumber(),
|
||||
// OldOc = p.Profile.Oc == null ? "" : p.Profile.Oc.Replace("/", " "),
|
||||
// OldPositionName = p.Profile.Position == null ? "" : p.Profile.Position.Name,
|
||||
// OldPositionLevel = p.Profile.PositionLevel == null ? "" : p.Profile.PositionLevel.Name,
|
||||
// OldPositionType = p.Profile.PositionType == null ? "" : p.Profile.PositionType.Name,
|
||||
// OldPositionNumber = p.Profile.PosNo == null ? "" : p.Profile.PosNo.Name.ToThaiNumber(),
|
||||
// OldSalary = p.Profile.Salaries == null || p.Profile.Salaries.Count == 0 ? "" : p.Profile.Salaries.OrderByDescending(x => x.Order).FirstOrDefault().Amount.Value.ToNumericNoDecimalText().ToThaiNumber(),
|
||||
OldSalary = p.AmountOld == null ? "" : p.AmountOld.Value.ToNumericNoDecimalText().ToThaiNumber(),
|
||||
NewOc = p.OrganizationPosition == null || p.OrganizationPosition!.Organization == null ? "" : _organizationCommonRepository.GetOrganizationNameFullPath(p.OrganizationPosition!.Organization!.Id, false, false, "/"),
|
||||
NewPositionName = p.PositionPath == null ? "" : p.PositionPath!.Name,
|
||||
NewPositionLevel = p.PositionLevel == null ? "" : p.PositionLevel.Name,
|
||||
NewPositionType = p.PositionType == null ? "" : p.PositionType.Name,
|
||||
NewPositionNumber = p.PositionNumber == null ? "" : p.PositionNumber.Name.ToThaiNumber(),
|
||||
// NewOc = p.OrganizationPosition == null || p.OrganizationPosition!.Organization == null ? "" : _organizationCommonRepository.GetOrganizationNameFullPath(p.OrganizationPosition!.Organization!.Id, false, false, "/"),
|
||||
// NewPositionName = p.PositionPath == null ? "" : p.PositionPath!.Name,
|
||||
// NewPositionLevel = p.PositionLevel == null ? "" : p.PositionLevel.Name,
|
||||
// NewPositionType = p.PositionType == null ? "" : p.PositionType.Name,
|
||||
// NewPositionNumber = p.PositionNumber == null ? "" : p.PositionNumber.Name.ToThaiNumber(),
|
||||
NewSalary = r.Amount == null ? "" : r.Amount.Value.ToNumericNoDecimalText().ToThaiNumber(),
|
||||
AppointDate = p.PositionDate == null ? "" : p.PositionDate.Value.ToThaiShortDate2().ToThaiNumber(),
|
||||
LeaveDate = p.Profile.LeaveDate == null ? "" : p.Profile.LeaveDate.Value.ToThaiShortDate2().ToThaiNumber(),
|
||||
// LeaveDate = p.Profile.LeaveDate == null ? "" : p.Profile.LeaveDate.Value.ToThaiShortDate2().ToThaiNumber(),
|
||||
Reason = p.Reason == null ? "-" : p.Reason,
|
||||
})
|
||||
.ToList();
|
||||
|
|
@ -505,24 +505,24 @@ namespace BMA.EHR.Application.Repositories.Commands
|
|||
|
||||
var report_data = (from r in raw_data
|
||||
join p in _dbContext.Set<RetirementOther>()
|
||||
.Include(x => x.Profile)
|
||||
.ThenInclude(x => x.Salaries)
|
||||
.Include(x => x.Profile)
|
||||
.ThenInclude(x => x.Position)
|
||||
.Include(x => x.Profile)
|
||||
.ThenInclude(x => x.PositionLevel)
|
||||
.Include(x => x.Profile)
|
||||
.ThenInclude(x => x.PositionType)
|
||||
.Include(x => x.Profile)
|
||||
.ThenInclude(x => x.PosNo)
|
||||
.Include(x => x.Profile)
|
||||
.ThenInclude(x => x.Educations)
|
||||
.Include(x => x.OrganizationPosition)
|
||||
.ThenInclude(x => x.Organization)
|
||||
.Include(x => x.PositionPath)
|
||||
.Include(x => x.PositionLevel)
|
||||
.Include(x => x.PositionNumber)
|
||||
.Include(x => x.PositionType)
|
||||
// .Include(x => x.Profile)
|
||||
// .ThenInclude(x => x.Salaries)
|
||||
// .Include(x => x.Profile)
|
||||
// .ThenInclude(x => x.Position)
|
||||
// .Include(x => x.Profile)
|
||||
// .ThenInclude(x => x.PositionLevel)
|
||||
// .Include(x => x.Profile)
|
||||
// .ThenInclude(x => x.PositionType)
|
||||
// .Include(x => x.Profile)
|
||||
// .ThenInclude(x => x.PosNo)
|
||||
// .Include(x => x.Profile)
|
||||
// .ThenInclude(x => x.Educations)
|
||||
// .Include(x => x.OrganizationPosition)
|
||||
// .ThenInclude(x => x.Organization)
|
||||
// .Include(x => x.PositionPath)
|
||||
// .Include(x => x.PositionLevel)
|
||||
// .Include(x => x.PositionNumber)
|
||||
// .Include(x => x.PositionType)
|
||||
on r.RefPlacementProfileId equals p.Id
|
||||
orderby r.Sequence
|
||||
select new CommandType03Response
|
||||
|
|
@ -533,21 +533,21 @@ namespace BMA.EHR.Application.Repositories.Commands
|
|||
Seq = r.Sequence.ToString().ToThaiNumber(),
|
||||
CitizenId = r.CitizenId,
|
||||
FullName = $"{r.Prefix}{r.FirstName} {r.LastName}",
|
||||
OldOc = p.Profile.Oc == null ? "" : p.Profile.Oc.Replace("/", " "),
|
||||
OldPositionName = p.Profile.Position == null ? "" : p.Profile.Position.Name,
|
||||
OldPositionLevel = p.Profile.PositionLevel == null ? "" : p.Profile.PositionLevel.Name,
|
||||
OldPositionType = p.Profile.PositionType == null ? "" : p.Profile.PositionType.Name,
|
||||
OldPositionNumber = p.Profile.PosNo == null ? "" : p.Profile.PosNo.Name.ToThaiNumber(),
|
||||
// OldOc = p.Profile.Oc == null ? "" : p.Profile.Oc.Replace("/", " "),
|
||||
// OldPositionName = p.Profile.Position == null ? "" : p.Profile.Position.Name,
|
||||
// OldPositionLevel = p.Profile.PositionLevel == null ? "" : p.Profile.PositionLevel.Name,
|
||||
// OldPositionType = p.Profile.PositionType == null ? "" : p.Profile.PositionType.Name,
|
||||
// OldPositionNumber = p.Profile.PosNo == null ? "" : p.Profile.PosNo.Name.ToThaiNumber(),
|
||||
// OldSalary = p.Profile.Salaries == null || p.Profile.Salaries.Count == 0 ? "" : p.Profile.Salaries.OrderByDescending(x => x.Order).FirstOrDefault().Amount.Value.ToNumericNoDecimalText().ToThaiNumber(),
|
||||
OldSalary = p.AmountOld == null ? "" : p.AmountOld.Value.ToNumericNoDecimalText().ToThaiNumber(),
|
||||
NewOc = p.OrganizationPosition == null || p.OrganizationPosition!.Organization == null ? "" : _organizationCommonRepository.GetOrganizationNameFullPath(p.OrganizationPosition!.Organization!.Id, false, false, "/"),
|
||||
NewPositionName = p.PositionPath == null ? "" : p.PositionPath!.Name,
|
||||
NewPositionLevel = p.PositionLevel == null ? "" : p.PositionLevel.Name,
|
||||
NewPositionType = p.PositionType == null ? "" : p.PositionType.Name,
|
||||
NewPositionNumber = p.PositionNumber == null ? "" : p.PositionNumber.Name.ToThaiNumber(),
|
||||
// NewOc = p.OrganizationPosition == null || p.OrganizationPosition!.Organization == null ? "" : _organizationCommonRepository.GetOrganizationNameFullPath(p.OrganizationPosition!.Organization!.Id, false, false, "/"),
|
||||
// NewPositionName = p.PositionPath == null ? "" : p.PositionPath!.Name,
|
||||
// NewPositionLevel = p.PositionLevel == null ? "" : p.PositionLevel.Name,
|
||||
// NewPositionType = p.PositionType == null ? "" : p.PositionType.Name,
|
||||
// NewPositionNumber = p.PositionNumber == null ? "" : p.PositionNumber.Name.ToThaiNumber(),
|
||||
NewSalary = r.Amount == null ? "" : r.Amount.Value.ToNumericNoDecimalText().ToThaiNumber(),
|
||||
AppointDate = p.PositionDate == null ? "" : p.PositionDate.Value.ToThaiShortDate2().ToThaiNumber(),
|
||||
LeaveDate = p.Profile.LeaveDate == null ? "" : p.Profile.LeaveDate.Value.ToThaiShortDate2().ToThaiNumber(),
|
||||
// LeaveDate = p.Profile.LeaveDate == null ? "" : p.Profile.LeaveDate.Value.ToThaiShortDate2().ToThaiNumber(),
|
||||
MilitaryDate = p.MilitaryDate == null ? "" : p.MilitaryDate.Value.ToThaiShortDate2().ToThaiNumber(),
|
||||
Reason = p.Reason == null ? "-" : p.Reason,
|
||||
})
|
||||
|
|
@ -696,12 +696,12 @@ namespace BMA.EHR.Application.Repositories.Commands
|
|||
|
||||
var report_data = (from r in raw_data
|
||||
join p in _dbContext.Set<PlacementReceive>()
|
||||
.Include(x => x.OrganizationPosition)
|
||||
.ThenInclude(x => x.Organization)
|
||||
.Include(x => x.PositionPath)
|
||||
.Include(x => x.PositionLevel)
|
||||
.Include(x => x.PositionNumber)
|
||||
.Include(x => x.PositionType)
|
||||
// .Include(x => x.OrganizationPosition)
|
||||
// .ThenInclude(x => x.Organization)
|
||||
// .Include(x => x.PositionPath)
|
||||
// .Include(x => x.PositionLevel)
|
||||
// .Include(x => x.PositionNumber)
|
||||
// .Include(x => x.PositionType)
|
||||
on r.RefPlacementProfileId equals p.Id
|
||||
orderby r.Sequence
|
||||
select new CommandType03Response
|
||||
|
|
@ -716,11 +716,11 @@ namespace BMA.EHR.Application.Repositories.Commands
|
|||
OldPositionType = p.PositionTypeOld ?? "",
|
||||
OldPositionNumber = p.PositionNumberOld == null ? "" : p.PositionNumberOld.ToThaiNumber(),
|
||||
OldSalary = p.AmountOld == null ? "" : p.AmountOld.Value.ToNumericNoDecimalText().ToThaiNumber(),
|
||||
NewOc = p.OrganizationPosition == null || p.OrganizationPosition!.Organization == null ? "" : _organizationCommonRepository.GetOrganizationNameFullPath(p.OrganizationPosition!.Organization!.Id, false, false, "/"),
|
||||
NewPositionName = p.PositionPath == null ? "" : p.PositionPath!.Name,
|
||||
NewPositionLevel = p.PositionLevel == null ? "" : p.PositionLevel.Name,
|
||||
NewPositionType = p.PositionType == null ? "" : p.PositionType.Name,
|
||||
NewPositionNumber = p.PositionNumber == null ? "" : p.PositionNumber.Name.ToThaiNumber(),
|
||||
// NewOc = p.OrganizationPosition == null || p.OrganizationPosition!.Organization == null ? "" : _organizationCommonRepository.GetOrganizationNameFullPath(p.OrganizationPosition!.Organization!.Id, false, false, "/"),
|
||||
// NewPositionName = p.PositionPath == null ? "" : p.PositionPath!.Name,
|
||||
// NewPositionLevel = p.PositionLevel == null ? "" : p.PositionLevel.Name,
|
||||
// NewPositionType = p.PositionType == null ? "" : p.PositionType.Name,
|
||||
// NewPositionNumber = p.PositionNumber == null ? "" : p.PositionNumber.Name.ToThaiNumber(),
|
||||
NewSalary = r.Amount == null ? "" : r.Amount.Value.ToNumericNoDecimalText().ToThaiNumber(),
|
||||
AppointDate = p.RecruitDate == null ? "" : p.RecruitDate.Value.ToThaiShortDate2().ToThaiNumber(),
|
||||
Reason = p.Reason == null ? "-" : p.Reason,
|
||||
|
|
@ -745,8 +745,8 @@ namespace BMA.EHR.Application.Repositories.Commands
|
|||
|
||||
var report_data = (from r in raw_data
|
||||
join p in _dbContext.Set<PlacementOfficer>()
|
||||
.Include(p => p.Profile)
|
||||
.ThenInclude(p => p.Position)
|
||||
//.Include(p => p.Profile)
|
||||
//.ThenInclude(p => p.Position)
|
||||
on r.RefPlacementProfileId equals p.Id
|
||||
orderby r.Sequence
|
||||
select new CommandType15Response
|
||||
|
|
@ -786,12 +786,12 @@ namespace BMA.EHR.Application.Repositories.Commands
|
|||
|
||||
var report_data = (from r in raw_data
|
||||
join p in _dbContext.Set<PlacementRepatriation>()
|
||||
.Include(p => p.Profile)
|
||||
.ThenInclude(p => p.Position)
|
||||
.Include(p => p.Profile)
|
||||
.ThenInclude(p => p.Salaries)
|
||||
.Include(p => p.Profile)
|
||||
.ThenInclude(p => p.Prefix)
|
||||
//.Include(p => p.Profile)
|
||||
//.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
|
||||
|
|
@ -807,7 +807,7 @@ namespace BMA.EHR.Application.Repositories.Commands
|
|||
r.Command.GovAidCommandDate.Value.ToThaiFullDate3().ToThaiNumber(),
|
||||
StartDate = p.Date == null ? "" : p.Date.Value.ToThaiFullDate3().ToThaiNumber(),
|
||||
ActiveDate = p.DateRepatriation == null ? "" : p.DateRepatriation.Value.ToThaiFullDate3().ToThaiNumber(),
|
||||
FullName = $"{p.Profile.Prefix!.Name}{p.Profile.FirstName!} {p.Profile.LastName!}",
|
||||
FullName = $"{p.prefix}{p.firstName!} {p.lastName!}",
|
||||
Subject = $"เรื่อง {r.Command.CommandSubject}",
|
||||
})
|
||||
.ToList();
|
||||
|
|
@ -882,10 +882,10 @@ namespace BMA.EHR.Application.Repositories.Commands
|
|||
|
||||
var report_data = (from r in raw_data
|
||||
join p in _dbContext.Set<RetirementOut>()
|
||||
.Include(p => p.Profile)
|
||||
.ThenInclude(p => p.Position)
|
||||
.Include(p => p.Profile)
|
||||
.ThenInclude(p => p.Salaries)
|
||||
// .Include(p => p.Profile)
|
||||
// .ThenInclude(p => p.Position)
|
||||
// .Include(p => p.Profile)
|
||||
// .ThenInclude(p => p.Salaries)
|
||||
on r.RefPlacementProfileId equals p.Id
|
||||
orderby r.Sequence
|
||||
select new CommandType18Response
|
||||
|
|
@ -898,7 +898,7 @@ namespace BMA.EHR.Application.Repositories.Commands
|
|||
AuthorizedPosition = r.Command.AuthorizedPosition,
|
||||
CitizenId = r.CitizenId,
|
||||
FullName = $"{r.Prefix}{r.FirstName} {r.LastName}",
|
||||
PositionName = p.Profile.Position == null ? "" : p.Profile.Position.Name,
|
||||
// PositionName = p.Profile.Position == null ? "" : p.Profile.Position.Name,
|
||||
Organization = p.OrganizationPositionOld == null ? "" : p.OrganizationPositionOld,
|
||||
PositionLevel = p.PositionLevelOld == null ? "" : p.PositionLevelOld,
|
||||
PositionType = p.PositionTypeOld == null ? "" : p.PositionTypeOld,
|
||||
|
|
@ -1104,24 +1104,24 @@ namespace BMA.EHR.Application.Repositories.Commands
|
|||
|
||||
var report_data = (from r in raw_data
|
||||
join p in _dbContext.Set<PlacementAppointment>()
|
||||
.Include(x => x.Profile)
|
||||
.ThenInclude(x => x.Position)
|
||||
.Include(x => x.Profile)
|
||||
.ThenInclude(x => x.PositionLevel)
|
||||
.Include(x => x.Profile)
|
||||
.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)
|
||||
// .Include(x => x.Profile)
|
||||
// .ThenInclude(x => x.Position)
|
||||
// .Include(x => x.Profile)
|
||||
// .ThenInclude(x => x.PositionLevel)
|
||||
// .Include(x => x.Profile)
|
||||
// .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 CommandType22Response
|
||||
|
|
@ -1134,9 +1134,9 @@ namespace BMA.EHR.Application.Repositories.Commands
|
|||
OldPositionNumber = p.PositionNumberOld == null ? null : p.PositionNumberOld.ToThaiNumber(),
|
||||
OldSalary = p.AmountOld == null ? "" : p.AmountOld.Value.ToNumericNoDecimalText().ToThaiNumber(),
|
||||
// NewOc = p.OrganizationPosition == null || p.OrganizationPosition!.Organization == null ? "" : _organizationCommonRepository.GetOrganizationNameFullPath(p.OrganizationPosition!.Organization!.Id, false, false, "/"),
|
||||
NewPositionName = p.OrgEmployee == null || p.OrgEmployee.PositionEmployeePosition == null ? "" : p.OrgEmployee.PositionEmployeePosition.Name,
|
||||
NewPositionLevel = p.OrgEmployee == null || p.OrgEmployee.OrganizationPositionEmployeeLevels == null || p.OrgEmployee.OrganizationPositionEmployeeLevels.Count() == 0 ? "" : p.OrgEmployee.OrganizationPositionEmployeeLevels.FirstOrDefault().PositionEmployeeLevel.Name,
|
||||
NewPositionNumber = p.OrgEmployee == null || p.OrgEmployee.PosNo == null ? "" : p.OrgEmployee.PosNo.ToThaiNumber(),
|
||||
// NewPositionName = p.OrgEmployee == null || p.OrgEmployee.PositionEmployeePosition == null ? "" : p.OrgEmployee.PositionEmployeePosition.Name,
|
||||
// NewPositionLevel = p.OrgEmployee == null || p.OrgEmployee.OrganizationPositionEmployeeLevels == null || p.OrgEmployee.OrganizationPositionEmployeeLevels.Count() == 0 ? "" : p.OrgEmployee.OrganizationPositionEmployeeLevels.FirstOrDefault().PositionEmployeeLevel.Name,
|
||||
// NewPositionNumber = p.OrgEmployee == null || p.OrgEmployee.PosNo == null ? "" : p.OrgEmployee.PosNo.ToThaiNumber(),
|
||||
NewSalary = r.Amount == null ? "" : r.Amount.Value.ToNumericNoDecimalText().ToThaiNumber(),
|
||||
Reason = p.Reason == null ? "-" : p.Reason,
|
||||
})
|
||||
|
|
@ -1231,24 +1231,24 @@ namespace BMA.EHR.Application.Repositories.Commands
|
|||
|
||||
var report_data = (from r in raw_data
|
||||
join p in _dbContext.Set<PlacementAppointment>()
|
||||
.Include(x => x.Profile)
|
||||
.ThenInclude(x => x.Position)
|
||||
.Include(x => x.Profile)
|
||||
.ThenInclude(x => x.PositionLevel)
|
||||
.Include(x => x.Profile)
|
||||
.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)
|
||||
// .Include(x => x.Profile)
|
||||
// .ThenInclude(x => x.Position)
|
||||
// .Include(x => x.Profile)
|
||||
// .ThenInclude(x => x.PositionLevel)
|
||||
// .Include(x => x.Profile)
|
||||
// .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 CommandType22Response
|
||||
|
|
@ -1261,9 +1261,9 @@ namespace BMA.EHR.Application.Repositories.Commands
|
|||
OldPositionNumber = p.PositionNumberOld == null ? null : p.PositionNumberOld.ToThaiNumber(),
|
||||
OldSalary = p.AmountOld == null ? "" : p.AmountOld.Value.ToNumericNoDecimalText().ToThaiNumber(),
|
||||
// NewOc = p.OrganizationPosition == null || p.OrganizationPosition!.Organization == null ? "" : _organizationCommonRepository.GetOrganizationNameFullPath(p.OrganizationPosition!.Organization!.Id, false, false, "/"),
|
||||
NewPositionName = p.OrgEmployee == null || p.OrgEmployee.PositionEmployeePosition == null ? "" : p.OrgEmployee.PositionEmployeePosition.Name,
|
||||
NewPositionLevel = p.OrgEmployee == null || p.OrgEmployee.OrganizationPositionEmployeeLevels == null || p.OrgEmployee.OrganizationPositionEmployeeLevels.Count() == 0 ? "" : p.OrgEmployee.OrganizationPositionEmployeeLevels.FirstOrDefault().PositionEmployeeLevel.Name,
|
||||
NewPositionNumber = p.OrgEmployee == null || p.OrgEmployee.PosNo == null ? "" : p.OrgEmployee.PosNo.ToThaiNumber(),
|
||||
// NewPositionName = p.OrgEmployee == null || p.OrgEmployee.PositionEmployeePosition == null ? "" : p.OrgEmployee.PositionEmployeePosition.Name,
|
||||
// NewPositionLevel = p.OrgEmployee == null || p.OrgEmployee.OrganizationPositionEmployeeLevels == null || p.OrgEmployee.OrganizationPositionEmployeeLevels.Count() == 0 ? "" : p.OrgEmployee.OrganizationPositionEmployeeLevels.FirstOrDefault().PositionEmployeeLevel.Name,
|
||||
// NewPositionNumber = p.OrgEmployee == null || p.OrgEmployee.PosNo == null ? "" : p.OrgEmployee.PosNo.ToThaiNumber(),
|
||||
NewSalary = r.Amount == null ? "" : r.Amount.Value.ToNumericNoDecimalText().ToThaiNumber(),
|
||||
Reason = p.Reason == null ? "-" : p.Reason,
|
||||
})
|
||||
|
|
|
|||
File diff suppressed because it is too large
Load diff
Loading…
Add table
Add a link
Reference in a new issue