Skip to content

Commit

Permalink
AAE-15221 Allow multiple roles when fetching deployed applications (#…
Browse files Browse the repository at this point in the history
  • Loading branch information
DavidOlson-Hyland authored Jan 8, 2025
1 parent b7881db commit 65b9916
Showing 1 changed file with 5 additions and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -36,11 +36,11 @@ export class AppsProcessCloudService {
* Gets a list of deployed apps for this user by status.
*
* @param status Required status value
* @param role to filter the apps
* @param roles to filter the apps
* @returns The list of deployed apps
*/
getDeployedApplicationsByStatus(status: string, role?: string): Observable<ApplicationInstanceModel[]> {
return this.hasDeployedApps() ? of(this.deployedApps) : this.getApplicationsByStatus(status, role);
getDeployedApplicationsByStatus(status: string, roles?: string | string[]): Observable<ApplicationInstanceModel[]> {
return this.hasDeployedApps() ? of(this.deployedApps) : this.getApplicationsByStatus(status, roles);
}

hasDeployedApps(): boolean {
Expand All @@ -66,13 +66,13 @@ export class AppsProcessCloudService {
}
}

private getApplicationsByStatus(status: string, role?: string): Observable<ApplicationInstanceModel[]> {
private getApplicationsByStatus(status: string, roles?: string | string[]): Observable<ApplicationInstanceModel[]> {
if (status === '') {
return of([]);
}
const path = this.getApplicationUrl();
const pathParams = {};
const queryParams = { status, roles: role, sort: 'name' };
const queryParams = { status, roles, sort: 'name' };
const httpMethod = 'GET';
const headerParams = {};
const formParams = {};
Expand Down

0 comments on commit 65b9916

Please sign in to comment.