Merge pull request #5683 from jwinzer/bug-fix-perms
Fix unresolved permissions
This commit is contained in:
commit
78cfa4875e
@ -263,7 +263,7 @@
|
|||||||
|
|
||||||
<mat-divider
|
<mat-divider
|
||||||
*ngIf="(categories.length || motionBlocks.length || hasAmendments() || perms.isAllowed('manage'))
|
*ngIf="(categories.length || motionBlocks.length || hasAmendments() || perms.isAllowed('manage'))
|
||||||
&& (perms.isAllowed('manage') || selectedView === 'list' || operator.hasPerms('core.can_manage_config'))"
|
&& (perms.isAllowed('manage') || selectedView === 'list' || perms.isAllowed('can_manage_config'))"
|
||||||
></mat-divider>
|
></mat-divider>
|
||||||
|
|
||||||
<div *ngIf="perms.isAllowed('manage')">
|
<div *ngIf="perms.isAllowed('manage')">
|
||||||
|
@ -166,6 +166,9 @@ export class LocalPermissionsService {
|
|||||||
this.operator.hasPerms(Permission.motionsCanManageMetadata)
|
this.operator.hasPerms(Permission.motionsCanManageMetadata)
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
case 'can_manage_config': {
|
||||||
|
return this.operator.hasPerms(Permission.coreCanManageConfig);
|
||||||
|
}
|
||||||
case 'manage': {
|
case 'manage': {
|
||||||
return this.operator.hasPerms(Permission.motionsCanManage);
|
return this.operator.hasPerms(Permission.motionsCanManage);
|
||||||
}
|
}
|
||||||
|
@ -50,7 +50,7 @@
|
|||||||
</mat-icon>
|
</mat-icon>
|
||||||
<mat-icon
|
<mat-icon
|
||||||
matTooltip="{{ 'Inactive' | translate }}"
|
matTooltip="{{ 'Inactive' | translate }}"
|
||||||
*ngIf="!user.is_active && this.operator.hasPerms('users.see_extra')"
|
*ngIf="!user.is_active && canSeeExtra"
|
||||||
>
|
>
|
||||||
block
|
block
|
||||||
</mat-icon>
|
</mat-icon>
|
||||||
|
@ -118,6 +118,10 @@ export class UserListComponent extends BaseListViewComponent<ViewUser> implement
|
|||||||
return this.operator.hasPerms(Permission.usersCanManage);
|
return this.operator.hasPerms(Permission.usersCanManage);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public get canSeeExtra(): boolean {
|
||||||
|
return this.operator.hasPerms(Permission.usersCanSeeExtraData);
|
||||||
|
}
|
||||||
|
|
||||||
public get showVoteWeight(): boolean {
|
public get showVoteWeight(): boolean {
|
||||||
return this.pollService.isElectronicVotingEnabled && this.isVoteWeightActive;
|
return this.pollService.isElectronicVotingEnabled && this.isVoteWeightActive;
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user