updated condition position & salary
This commit is contained in:
parent
3b9002f505
commit
32bb7e3b79
1 changed files with 21 additions and 3 deletions
|
|
@ -19,7 +19,7 @@ import HttpError from "../interfaces/http-error";
|
|||
import { ProfileSalaryHistory } from "../entities/ProfileSalaryHistory";
|
||||
import { RequestWithUser } from "../middlewares/user";
|
||||
import { Profile } from "../entities/Profile";
|
||||
import { LessThan, MoreThan } from "typeorm";
|
||||
import { In, LessThan, MoreThan } from "typeorm";
|
||||
import permission from "../interfaces/permission";
|
||||
import { setLogDataDiff } from "../interfaces/utils";
|
||||
@Route("api/v1/org/profile/salary")
|
||||
|
|
@ -62,7 +62,7 @@ export class ProfileSalaryController extends Controller {
|
|||
if (_workflow == false)
|
||||
await new permission().PermissionOrgUserGet(req, "SYS_REGISTRY_OFFICER", profileId);
|
||||
const record = await this.salaryRepo.find({
|
||||
where: { profileId: profileId },
|
||||
where: { profileId: profileId, commandCode: In(["5", "6", "7"]) },
|
||||
order: { order: "ASC" },
|
||||
});
|
||||
return new HttpSuccess(record);
|
||||
|
|
@ -74,7 +74,25 @@ export class ProfileSalaryController extends Controller {
|
|||
if (_workflow == false)
|
||||
await new permission().PermissionOrgUserGet(req, "SYS_REGISTRY_OFFICER", profileId);
|
||||
const record = await this.salaryRepo.find({
|
||||
where: { profileId: profileId },
|
||||
where: {
|
||||
profileId: profileId,
|
||||
commandCode: In([
|
||||
"0",
|
||||
"9",
|
||||
"1",
|
||||
"2",
|
||||
"3",
|
||||
"4",
|
||||
"8",
|
||||
"10",
|
||||
"11",
|
||||
"12",
|
||||
"13",
|
||||
"14",
|
||||
"15",
|
||||
"16",
|
||||
]),
|
||||
},
|
||||
order: { order: "ASC" },
|
||||
});
|
||||
return new HttpSuccess(record);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue