แก้รายงาน กก1
This commit is contained in:
parent
4fb8439968
commit
3cc2db0d1d
2 changed files with 7 additions and 5 deletions
|
|
@ -519,8 +519,10 @@ namespace BMA.EHR.Report.Service.Controllers
|
|||
OcFullPath = _profileService.GetOrganizationNameFullPath(p.OcId.Value, false, false),
|
||||
}).FirstOrDefault();
|
||||
|
||||
var salary = (from s in _context.ProfileSalaries.Include(x => x.PositionLevel)
|
||||
join pos in _context.PositionPaths on s.PositionId equals pos.Id
|
||||
var salary = (from s in _context.ProfileSalaries
|
||||
.Include(x => x.PositionLevel)
|
||||
join pos in _context.PositionPaths.AsQueryable()
|
||||
on s.PositionId equals pos.Id
|
||||
join pos_no in _context.PositionNumbers on s.PosNoId equals pos_no.Id
|
||||
// join pos_lv in _context.PositionLevels on s.PositionLevelId equals pos_lv.Id
|
||||
join pos_type in _context.PositionTypes on s.PositionTypeId equals pos_type.Id
|
||||
|
|
@ -529,14 +531,14 @@ namespace BMA.EHR.Report.Service.Controllers
|
|||
select new
|
||||
{
|
||||
SalaryDate = s.Date == null ? "" : s.Date == new DateTime(1, 1, 1) ? "" : s.Date.Value.ToThaiShortDate(),
|
||||
Position = s.SalaryClass,
|
||||
Position = $"{pos.Name} ประเภท{pos_type.Name} ระดับ{s.PositionLevel.Name}",
|
||||
PosNo = pos_no.Name,
|
||||
Rank = s.PositionLevel == null ? null : s.PositionLevel.Name,
|
||||
Salary = s.Amount == null ? "" : s.Amount.ToString().ToInteger().ToNumericText(),
|
||||
Salary = s.Amount == null ? "" : s.Amount == 0 ? "-" : s.Amount.ToString().ToInteger().ToNumericText(),
|
||||
RefAll = s.SalaryRef,
|
||||
PositionType = pos_type.Name,
|
||||
PositionLevel = s.PositionLevel == null ? null : s.PositionLevel.Name,
|
||||
PositionAmount = s.PositionSalaryAmount == null ? "" : s.PositionSalaryAmount.Value.ToString().ToInteger().ToNumericText(),
|
||||
PositionAmount = s.PositionSalaryAmount == null ? "" : s.PositionSalaryAmount.Value == 0 ? "-" : s.PositionSalaryAmount.Value.ToString().ToInteger().ToNumericText(),
|
||||
FullName = profile2.FullName,
|
||||
OcFullPath = profile2.OcFullPath
|
||||
}).ToList();
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue