sort child1
This commit is contained in:
parent
8d41347670
commit
0589313d71
1 changed files with 32 additions and 0 deletions
|
|
@ -7567,6 +7567,34 @@ export class OrganizationController extends Controller {
|
|||
order: { isDeputy: "DESC", DEPARTMENT_CODE: "ASC", orgRootName: "ASC" },
|
||||
select: ["orgRootName"],
|
||||
});
|
||||
const child1 = await this.child1Repository.find({
|
||||
where: {
|
||||
orgRevision: { orgRevisionIsDraft: false, orgRevisionIsCurrent: true },
|
||||
},
|
||||
order: { orgChild1Order: "ASC" },
|
||||
select: ["orgChild1Name"],
|
||||
});
|
||||
const child2 = await this.child2Repository.find({
|
||||
where: {
|
||||
orgRevision: { orgRevisionIsDraft: false, orgRevisionIsCurrent: true },
|
||||
},
|
||||
order: { orgChild2Order: "ASC" },
|
||||
select: ["orgChild2Name"],
|
||||
});
|
||||
const child3 = await this.child3Repository.find({
|
||||
where: {
|
||||
orgRevision: { orgRevisionIsDraft: false, orgRevisionIsCurrent: true },
|
||||
},
|
||||
order: { orgChild3Order: "ASC" },
|
||||
select: ["orgChild3Name"],
|
||||
});
|
||||
const child4 = await this.child4Repository.find({
|
||||
where: {
|
||||
orgRevision: { orgRevisionIsDraft: false, orgRevisionIsCurrent: true },
|
||||
},
|
||||
order: { orgChild4Order: "ASC" },
|
||||
select: ["orgChild4Name"],
|
||||
});
|
||||
const hospital = await this.child1Repository.find({
|
||||
where: [
|
||||
{
|
||||
|
|
@ -7590,6 +7618,10 @@ export class OrganizationController extends Controller {
|
|||
});
|
||||
return new HttpSuccess({
|
||||
root: root.map((x) => x.orgRootName),
|
||||
child1: child1.map((x) => x.orgChild1Name),
|
||||
child2: child2.map((x) => x.orgChild2Name),
|
||||
child3: child3.map((x) => x.orgChild3Name),
|
||||
child4: child4.map((x) => x.orgChild4Name),
|
||||
hospital: hospital.map((x) => x.orgChild1Name),
|
||||
posTypeNameOrder: posType.map((x) => x.posTypeName),
|
||||
posLevelNameOrder: posLevel.map((x) => x.posLevelName),
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue