Merge branch 'adiDev' into develop

This commit is contained in:
AdisakKanthawilang 2024-05-21 15:40:46 +07:00
commit 6ba5764fbb
2 changed files with 5 additions and 9 deletions

View file

@ -238,12 +238,7 @@ export class DevelopmentEmployeeHistoryController extends Controller {
: "1=1",
{ year: body.year },
)
.andWhere(
body.root != null && body.root != undefined ? "developmentHistory.root = :root" : "1=1",
{
root: body.root,
},
)
.andWhere(body.root != null ? "developmentHistory.root = :root" : "1=1", { root: body.root })
.andWhere("developmentHistory.type = :type", { type: type })
.andWhere(
new Brackets((qb) => {

View file

@ -230,9 +230,9 @@ export class DevelopmentOfficerHistoryController extends Controller {
: "1=1",
{ year: body.year },
)
.andWhere(body.root != null && body.root != undefined ? "development.root = :root" : "1=1", {
root: body.root,
})
// .andWhere(body.root != null && body.root != undefined ? "development.root = :root" : "1=1", {
// root: body.root,
// })
.andWhere(body.root != null ? "developmentHistory.root = :root" : "1=1", { root: body.root })
.andWhere("developmentHistory.type = :type", { type: type })
.andWhere(
@ -313,6 +313,7 @@ export class DevelopmentOfficerHistoryController extends Controller {
fullName: item.prefix + item.firstName + " " + item.lastName,
position: item.position,
year: item.development.year,
root: item.development.root,//test
posType: item.posType ? item.posType.posTypeName : null,
posLevel: item.posLevel ? item.posLevel.posLevelName : null,
posExecutive: item.posExecutive,