refactor: Ersetze fetchData-Aufrufe durch fetchByUser- und fetchByGroup-Methoden in UserRepresentationComponent, um Fehler zu vermeiden.

This commit is contained in:
Developer 02
2024-11-06 15:46:27 +01:00
parent 8cf2183cd6
commit fb3dedadc5

View File

@@ -108,10 +108,10 @@ export class UserRepresentationComponent extends BasePageComponent implements Af
this.repUsers.safelyUnselectAll()
this.repGroups.safelyUnselectAll()
if (this.slUserId != undefined)
this.userReps.fetchData(this.slUserId)
if (this.slGroupId != undefined)
this.userReps.fetchData(this.slGroupId)
if (this.slUserId)
this.userReps.fetchByUser(this.slUserId)
if (this.slGroupId)
this.userReps.fetchByGroup(this.slGroupId)
},
error: (error) => {
Swal.fire({
@@ -158,10 +158,10 @@ export class UserRepresentationComponent extends BasePageComponent implements Af
this.slRepGroupId = undefined;
this.repUsers.safelyUnselectAll()
this.groups.safelyUnselectAll()
if (this.slUserId != undefined)
this.userReps.fetchData(this.slUserId)
if (this.slGroupId != undefined)
this.userReps.fetchData(undefined, this.slGroupId)
if (this.slUserId)
this.userReps.fetchByUser(this.slUserId)
if (this.slGroupId)
this.userReps.fetchByGroup(this.slGroupId)
},
error: (error) => {
Swal.fire({