Merge Angular 16 Irish Monitor to develop #33

Merged
k.triantafyllou merged 151 commits from angular-16-irish-monitor into develop 2024-02-13 09:32:41 +01:00
2 changed files with 8 additions and 5 deletions
Showing only changes of commit 3c7b330167 - Show all commits

View File

@ -206,8 +206,8 @@ export class RoleUsersComponent implements OnInit, OnDestroy, OnChanges {
this.createRoleModal.okButtonLeft = false;
this.createRoleModal.okButtonText = 'Create';
this.roleFb = this.fb.group({
name: this.fb.control(Role.mapType(this.type) + '.' + this.id, Validators.required),
description: this.fb.control(Role.mapType(this.type) + ' ' + this.id, Validators.required)
name: this.fb.control(Role.roleName(this.type, this.id), Validators.required),
description: this.fb.control(Role.roleName(this.type, this.id), Validators.required)
});
setTimeout(() => {
this.roleFb.get('name').disable();

View File

@ -218,6 +218,9 @@ export class Role {
public static USER_MANAGER = 'USER_MANAGER';
public static CURATOR_CLAIM = 'CURATOR_CLAIM';
public static roleName(type: string, id: string) {
return this.GROUP + this.mapType(type) + '.' + id;
}
public static mapType(type: string, communityMap: boolean = true): string {
if (type == "ri" && communityMap) {
@ -225,7 +228,7 @@ export class Role {
} else if (type == "organization") {
type = "institution";
}
return Role.GROUP + type;
return type;
}
/**