mirror of
https://github.com/zitadel/zitadel.git
synced 2025-12-05 09:02:04 +00:00
feat(console): allow filter org by primary domain on instance (#7283)
* feat: i18n translations * feat: add primary domain to filter-org component * fix: add listOrgs service to admin and use it for org-table component --------- Co-authored-by: Max Peintner <max@caos.ch>
This commit is contained in:
@@ -159,6 +159,8 @@ import {
|
||||
ListLoginPolicySecondFactorsResponse,
|
||||
ListMilestonesRequest,
|
||||
ListMilestonesResponse,
|
||||
ListOrgsRequest,
|
||||
ListOrgsResponse,
|
||||
ListProvidersRequest,
|
||||
ListProvidersResponse,
|
||||
ListSecretGeneratorsRequest,
|
||||
@@ -314,6 +316,8 @@ import {
|
||||
MilestoneQuery,
|
||||
MilestoneType,
|
||||
} from '../proto/generated/zitadel/milestone/v1/milestone_pb';
|
||||
import { OrgFieldName, OrgQuery } from '../proto/generated/zitadel/org_pb';
|
||||
import { SortDirection } from '@angular/material/sort';
|
||||
|
||||
export interface OnboardingActions {
|
||||
order: number;
|
||||
@@ -1303,4 +1307,33 @@ export class AdminService {
|
||||
public listMilestones(req: ListMilestonesRequest): Promise<ListMilestonesResponse.AsObject> {
|
||||
return this.grpcService.admin.listMilestones(req, null).then((resp) => resp.toObject());
|
||||
}
|
||||
|
||||
public listOrgs(
|
||||
limit: number,
|
||||
offset: number,
|
||||
queriesList?: OrgQuery[],
|
||||
sortingColumn?: OrgFieldName,
|
||||
sortingDirection?: SortDirection,
|
||||
): Promise<ListOrgsResponse.AsObject> {
|
||||
const req = new ListOrgsRequest();
|
||||
const query = new ListQuery();
|
||||
if (limit) {
|
||||
query.setLimit(limit);
|
||||
}
|
||||
if (offset) {
|
||||
query.setOffset(offset);
|
||||
}
|
||||
if (sortingDirection) {
|
||||
query.setAsc(sortingDirection === 'asc');
|
||||
}
|
||||
req.setQuery(query);
|
||||
if (sortingColumn) {
|
||||
req.setSortingColumn(sortingColumn);
|
||||
}
|
||||
|
||||
if (queriesList) {
|
||||
req.setQueriesList(queriesList);
|
||||
}
|
||||
return this.grpcService.admin.listOrgs(req, null).then((resp) => resp.toObject());
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user