no message

This commit is contained in:
Kittapath 2024-02-20 17:50:02 +07:00
parent 24f2adbb22
commit 6e84a46ac3

View file

@ -1001,10 +1001,10 @@ export class PositionController extends Controller {
.leftJoinAndSelect("posMaster.current_holder", "current_holder")
.leftJoinAndSelect("posMaster.next_holder", "next_holder")
.where(conditions)
// .where("posMaster.orgRevisionId = :revisionId", { revisionId: body.revisionId })
// // .where("posMaster.orgRevisionId = :revisionId", { revisionId: body.revisionId })
.orWhere(
new Brackets((qb) => {
qb.where(searchShortName)
qb.andWhere(body.keyword != null && body.keyword != "" ? searchShortName : "1=1")
.andWhere(checkChildConditions)
.andWhere(typeCondition)
.andWhere(revisionCondition);
@ -1012,7 +1012,7 @@ export class PositionController extends Controller {
)
.orWhere(
new Brackets((qb) => {
qb.where(
qb.andWhere(
body.keyword != null && body.keyword != ""
? "CONCAT(current_holder.prefix, current_holder.firstName, current_holder.lastName) LIKE :keyword OR :keyword LIKE current_holder.prefix OR :keyword LIKE current_holder.firstName OR :keyword LIKE current_holder.lastName "
: "1=1",