แก้ค้นหาคนครอง
This commit is contained in:
parent
6ba3236994
commit
9c7072c128
3 changed files with 9 additions and 4 deletions
|
|
@ -1996,6 +1996,7 @@ export class EmployeePositionController extends Controller {
|
||||||
|
|
||||||
dataMaster.isSit = requestBody.isSit;
|
dataMaster.isSit = requestBody.isSit;
|
||||||
dataMaster.current_holderId = requestBody.profileId;
|
dataMaster.current_holderId = requestBody.profileId;
|
||||||
|
dataMaster.next_holderId = requestBody.profileId;
|
||||||
await this.employeePosMasterRepository.save(dataMaster);
|
await this.employeePosMasterRepository.save(dataMaster);
|
||||||
|
|
||||||
return new HttpSuccess();
|
return new HttpSuccess();
|
||||||
|
|
|
||||||
|
|
@ -384,8 +384,10 @@ export class ProfileController extends Controller {
|
||||||
)
|
)
|
||||||
.andWhere(
|
.andWhere(
|
||||||
new Brackets((qb) => {
|
new Brackets((qb) => {
|
||||||
qb.where("next_holders.id IS NULL").orWhere("next_holders.id NOT IN (:...ids)", {
|
qb.where("profile.id NOT IN (:...ids)", {
|
||||||
ids: orgRevision.posMasters.map((x) => x.next_holderId),
|
ids: orgRevision.posMasters
|
||||||
|
.filter((x) => x.next_holderId != null)
|
||||||
|
.map((x) => x.next_holderId),
|
||||||
});
|
});
|
||||||
}),
|
}),
|
||||||
)
|
)
|
||||||
|
|
|
||||||
|
|
@ -379,8 +379,10 @@ export class ProfileEmployeeController extends Controller {
|
||||||
)
|
)
|
||||||
.andWhere(
|
.andWhere(
|
||||||
new Brackets((qb) => {
|
new Brackets((qb) => {
|
||||||
qb.where("next_holders.id IS NULL").orWhere("next_holders.id NOT IN (:...ids)", {
|
qb.where("profile.id NOT IN (:...ids)", {
|
||||||
ids: orgRevision.posMasters.map((x) => x.next_holderId),
|
ids: orgRevision.posMasters
|
||||||
|
.filter((x) => x.next_holderId != null)
|
||||||
|
.map((x) => x.next_holderId),
|
||||||
});
|
});
|
||||||
}),
|
}),
|
||||||
)
|
)
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue