เช็ค ประเมินผล #814

This commit is contained in:
Bright 2024-11-29 09:52:59 +07:00
parent 4721e9aeed
commit 0cfdc07253
2 changed files with 8 additions and 5 deletions

View file

@ -243,8 +243,9 @@ export class kpiPeriodController extends Controller {
year !== 0 && year != null && year != undefined ? "kpiPeriod.year = :year" : "1=1",
{ year: year },
)
.orderBy("kpiPeriod.startDate", "ASC")
.addOrderBy("kpiPeriod.year", "ASC")
.orderBy("kpiPeriod.year", "DESC")
.addOrderBy("kpiPeriod.durationKPI", "DESC")
.addOrderBy("kpiPeriod.startDate", "DESC")
.skip((page - 1) * pageSize)
.take(pageSize)
.getManyAndCount();
@ -296,8 +297,8 @@ export class kpiPeriodController extends Controller {
year !== 0 && year != null && year != undefined ? "kpiPeriod.year = :year" : "1=1",
{ year: year },
)
.orderBy("kpiPeriod.startDate", "ASC")
.addOrderBy("kpiPeriod.year", "ASC")
.orderBy("kpiPeriod.year", "DESC")
.addOrderBy("kpiPeriod.createdAt", "DESC")
.skip((page - 1) * pageSize)
.take(pageSize)
.getManyAndCount();