ปรับให้เรียงข้าราชการก่อนลูกจ้างประจำ

This commit is contained in:
Bright 2024-12-18 18:39:05 +07:00
parent b042f471b4
commit e409277518
5 changed files with 10 additions and 5 deletions

View file

@ -131,7 +131,8 @@ namespace BMA.EHR.DisciplineSuspend.Service.Controllers
profileType = x.profileType,
CreatedAt = x.CreatedAt,
})
.OrderByDescending(x => x.CreatedAt)
.OrderByDescending(x => x.profileType == "OFFICER")
.ThenByDescending(x => x.CreatedAt)
.ThenByDescending(x => x.CitizenId)
.Skip((page - 1) * pageSize)
.Take(pageSize)