delete comment
This commit is contained in:
parent
a4f7b021a0
commit
c1f3de5619
1 changed files with 14 additions and 89 deletions
|
|
@ -162,6 +162,13 @@ export class OrganizationDotnetController extends Controller {
|
|||
}),
|
||||
)
|
||||
.andWhere(condition, conditionParams)
|
||||
.select([
|
||||
"profile.id",
|
||||
"profile.citizenId",
|
||||
"profile.prefix",
|
||||
"profile.firstName",
|
||||
"profile.lastName",
|
||||
])
|
||||
.skip((body.page - 1) * body.pageSize)
|
||||
.take(body.pageSize)
|
||||
.getManyAndCount();
|
||||
|
|
@ -276,99 +283,17 @@ export class OrganizationDotnetController extends Controller {
|
|||
)
|
||||
.andWhere(condition, conditionParams)
|
||||
.orderBy("profileSalary.order", "DESC")
|
||||
.select([
|
||||
"profile.id",
|
||||
"profile.citizenId",
|
||||
"profile.prefix",
|
||||
"profile.firstName",
|
||||
"profile.lastName",
|
||||
])
|
||||
.skip((body.page - 1) * body.pageSize)
|
||||
.take(body.pageSize)
|
||||
.getManyAndCount();
|
||||
|
||||
// const profileEmp_ = await Promise.all(
|
||||
// profileEmp.map((item: ProfileEmployee) => {
|
||||
// const rootName =
|
||||
// item.current_holders.length == 0
|
||||
// ? null
|
||||
// : item.current_holders.find((x) => x.orgRevisionId == findRevision?.id)?.orgRoot
|
||||
// ?.orgRootName;
|
||||
// const shortName =
|
||||
// item.current_holders.length == 0
|
||||
// ? null
|
||||
// : item.current_holders.find((x) => x.orgRevisionId == findRevision?.id) != null &&
|
||||
// item.current_holders.find((x) => x.orgRevisionId == findRevision?.id)?.orgChild4 !=
|
||||
// null
|
||||
// ? `${item.current_holders.find((x) => x.orgRevisionId == findRevision?.id)?.orgChild4.orgChild4ShortName} ${item.current_holders.find((x) => x.orgRevisionId == findRevision?.id)?.posMasterNo}`
|
||||
// : item.current_holders.find((x) => x.orgRevisionId == findRevision?.id) != null &&
|
||||
// item.current_holders.find((x) => x.orgRevisionId == findRevision?.id)
|
||||
// ?.orgChild3 != null
|
||||
// ? `${item.current_holders.find((x) => x.orgRevisionId == findRevision?.id)?.orgChild3.orgChild3ShortName} ${item.current_holders.find((x) => x.orgRevisionId == findRevision?.id)?.posMasterNo}`
|
||||
// : item.current_holders.find((x) => x.orgRevisionId == findRevision?.id) != null &&
|
||||
// item.current_holders.find((x) => x.orgRevisionId == findRevision?.id)
|
||||
// ?.orgChild2 != null
|
||||
// ? `${item.current_holders.find((x) => x.orgRevisionId == findRevision?.id)?.orgChild2.orgChild2ShortName} ${item.current_holders.find((x) => x.orgRevisionId == findRevision?.id)?.posMasterNo}`
|
||||
// : item.current_holders.find((x) => x.orgRevisionId == findRevision?.id) != null &&
|
||||
// item.current_holders.find((x) => x.orgRevisionId == findRevision?.id)
|
||||
// ?.orgChild1 != null
|
||||
// ? `${item.current_holders.find((x) => x.orgRevisionId == findRevision?.id)?.orgChild1.orgChild1ShortName} ${item.current_holders.find((x) => x.orgRevisionId == findRevision?.id)?.posMasterNo}`
|
||||
// : item.current_holders.find((x) => x.orgRevisionId == findRevision?.id) !=
|
||||
// null &&
|
||||
// item.current_holders.find((x) => x.orgRevisionId == findRevision?.id)
|
||||
// ?.orgRoot != null
|
||||
// ? `${item.current_holders.find((x) => x.orgRevisionId == findRevision?.id)?.orgRoot.orgRootShortName} ${item.current_holders.find((x) => x.orgRevisionId == findRevision?.id)?.posMasterNo}`
|
||||
// : null;
|
||||
// return {
|
||||
// oc: rootName,
|
||||
// id: item.id,
|
||||
// createdAt: item.createdAt,
|
||||
// createdUserId: item.createdUserId,
|
||||
// lastUpdatedAt: item.lastUpdatedAt,
|
||||
// lastUpdateUserId: item.lastUpdateUserId,
|
||||
// createdFullName: item.createdFullName,
|
||||
// lastUpdateFullName: item.lastUpdateFullName,
|
||||
// avatar: item.avatar,
|
||||
// avatarName: item.avatarName,
|
||||
// rank: item.rank,
|
||||
// prefix: item.prefix,
|
||||
// firstName: item.firstName,
|
||||
// lastName: item.lastName,
|
||||
// citizenId: item.citizenId,
|
||||
// position: item.position,
|
||||
// posLevelId: item.posLevelId,
|
||||
// posTypeId: item.posTypeId,
|
||||
// email: item.email,
|
||||
// phone: item.phone,
|
||||
// keycloak: item.keycloak,
|
||||
// isProbation: item.isProbation,
|
||||
// isLeave: item.isLeave,
|
||||
// leaveReason: item.leaveReason,
|
||||
// dateLeave: item.dateLeave,
|
||||
// dateRetire: item.dateRetire,
|
||||
// dateAppoint: item.dateAppoint,
|
||||
// dateRetireLaw: item.dateRetireLaw,
|
||||
// dateStart: item.dateStart,
|
||||
// govAgeAbsent: item.govAgeAbsent,
|
||||
// govAgePlus: item.govAgePlus,
|
||||
// birthDate: item.birthDate ?? new Date(),
|
||||
// reasonSameDate: item.reasonSameDate,
|
||||
// ethnicity: item.ethnicity,
|
||||
// telephoneNumber: item.phone,
|
||||
// nationality: item.nationality,
|
||||
// gender: item.gender,
|
||||
// relationship: item.relationship,
|
||||
// religion: item.religion,
|
||||
// bloodGroup: item.bloodGroup,
|
||||
// registrationAddress: item.registrationAddress,
|
||||
// registrationProvinceId: item.registrationProvinceId,
|
||||
// registrationDistrictId: item.registrationDistrictId,
|
||||
// registrationSubDistrictId: item.registrationSubDistrictId,
|
||||
// registrationZipCode: item.registrationZipCode,
|
||||
// currentAddress: item.currentAddress,
|
||||
// currentProvinceId: item.currentProvinceId,
|
||||
// currentDistrictId: item.currentDistrictId,
|
||||
// currentSubDistrictId: item.currentSubDistrictId,
|
||||
// currentZipCode: item.currentZipCode,
|
||||
// posLevel: item.posLevel,
|
||||
// posType: item.posType,
|
||||
// posNo: shortName,
|
||||
// };
|
||||
// }),
|
||||
// );
|
||||
return new HttpSuccess({ data: profileEmp, total: total });
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue