เพิ่มชื่อจังหวัด
This commit is contained in:
parent
27fe258408
commit
1e33f6d4ea
2 changed files with 47 additions and 12 deletions
|
|
@ -7560,13 +7560,24 @@ export class OrganizationController extends Controller {
|
|||
*/
|
||||
@Get("root/search/sort")
|
||||
async searchSortRootLevelType(@Request() request: RequestWithUser) {
|
||||
const root = await this.orgRootRepository.find({
|
||||
const root1 = await this.orgRootRepository.find({
|
||||
where: {
|
||||
orgRevision: { orgRevisionIsDraft: false, orgRevisionIsCurrent: true },
|
||||
DEPARTMENT_CODE: Not("50"),
|
||||
},
|
||||
order: { isDeputy: "DESC", DEPARTMENT_CODE: "ASC", orgRootName: "ASC" },
|
||||
order: { isDeputy: "DESC", orgRootOrder: "ASC" },
|
||||
select: ["orgRootName"],
|
||||
});
|
||||
const root2 = await this.orgRootRepository.find({
|
||||
where: {
|
||||
orgRevision: { orgRevisionIsDraft: false, orgRevisionIsCurrent: true },
|
||||
DEPARTMENT_CODE: "50",
|
||||
},
|
||||
order: { orgRootName: "ASC" },
|
||||
select: ["orgRootName"],
|
||||
});
|
||||
const root = [root1, root2];
|
||||
|
||||
const child1 = await this.child1Repository.find({
|
||||
where: {
|
||||
orgRevision: { orgRevisionIsDraft: false, orgRevisionIsCurrent: true },
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue