list command
This commit is contained in:
parent
e43c29dbc4
commit
0119ff5722
4 changed files with 350 additions and 64 deletions
|
|
@ -65,11 +65,10 @@ export class PermissionOrgController extends Controller {
|
|||
if (!orgRevisionActive) {
|
||||
return new HttpSuccess([]);
|
||||
}
|
||||
let _data: any = [null];
|
||||
let _data: any = null;
|
||||
if (!request.user.role.includes("SUPER_ADMIN")) {
|
||||
_data = await this.listAuthSysOrgFuncByRevisionId(request, "SYS_ORG", orgRevisionActive.id);
|
||||
}
|
||||
console.log(_data);
|
||||
const data = await AppDataSource.getRepository(OrgRoot)
|
||||
.createQueryBuilder("orgRoot")
|
||||
.where("orgRoot.orgRevisionId = :id", { id: orgRevisionActive.id })
|
||||
|
|
@ -529,13 +528,9 @@ export class PermissionOrgController extends Controller {
|
|||
let profile = await this.profileRepo.findOne({
|
||||
where: {
|
||||
keycloak: request.user.sub,
|
||||
// current_holders: { orgRevisionId: revisionId },
|
||||
},
|
||||
relations: ["next_holders", "next_holders.authRole", "next_holders.authRole.authRoles"],
|
||||
});
|
||||
console.log(request.user.sub);
|
||||
console.log(revisionId);
|
||||
console.log(profile);
|
||||
if (!profile) {
|
||||
return [null];
|
||||
}
|
||||
|
|
@ -551,8 +546,6 @@ export class PermissionOrgController extends Controller {
|
|||
orgRevisionId: revisionId,
|
||||
},
|
||||
});
|
||||
console.log(posMaster);
|
||||
console.log(attrOwnership);
|
||||
if (!posMaster) {
|
||||
return [null];
|
||||
} else if (attrOwnership == "OWNER") {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue