}
get inheritedPermissions(): string[] {
- const groupsVal = this.objectForm.get('groups').value
- return groupsVal !== null
- ? this.groups.find((g) => g.id == groupsVal)?.permissions
- : []
+ const groupsVal: Array<number> = this.objectForm.get('groups').value
+
+ if (!groupsVal) return []
+ else
+ return groupsVal.flatMap(
+ (id) => this.groups.find((g) => g.id == id)?.permissions
+ )
}
}
})
this.typesWithAllActions.add(type)
} else {
+ Object.keys(PermissionAction).forEach((action) => {
+ typeGroup.get(action).patchValue(false)
+ })
this.typesWithAllActions.delete(type)
}
}
background-color: var(--bs-light);
}
+ .ng-select-multiple .ng-select-container .ng-value-container .ng-value {
+ background-color: var(--pngx-bg-alt);
+ color: var(--bs-body-color);
+
+ .ng-value-icon.left {
+ border-color: var(--pngx-bg-alt);
+
+ &:hover {
+ background-color: var(--pngx-primary-lighten-30);
+ }
+ }
+ }
+
table {
.des,
.asc {