mirror of
https://github.com/andwati/zitadel.git
synced 2026-11-08 23:25:12 +00:00
fix(console): use authService for auth user page (#5233)
* auth grant * fix: add missing attributes to ListMyUserGrantsResponse * user grants typing * typing * auth grant link * disable without role * edit with auth grant * chore(console): auto organize imports (#5293) fix(console): auto organize imports * Update console/src/app/modules/user-grants/user-grants-datasource.ts Co-authored-by: Elio Bischof <[email protected]> * Update console/src/app/modules/user-grants/user-grants-datasource.ts Co-authored-by: Elio Bischof <[email protected]> * Update console/src/app/modules/user-grants/user-grants-datasource.ts Co-authored-by: Elio Bischof <[email protected]> * linter, rm unused import * add examples again * lint --------- Co-authored-by: Livio Spring <[email protected]> Co-authored-by: Elio Bischof <[email protected]>
This commit is contained in:
co-authored by
Elio Bischof
Livio Spring
parent
c4ca72fe68
commit
9396e8b2f5
@@ -1,7 +1,6 @@
|
||||
import { Injectable } from '@angular/core';
|
||||
import { AuthConfig, OAuthService } from 'angular-oauth2-oidc';
|
||||
import { BehaviorSubject, from, lastValueFrom, Observable } from 'rxjs';
|
||||
import { GrpcAuthService } from './grpc-auth.service';
|
||||
|
||||
import { StatehandlerService } from './statehandler/statehandler.service';
|
||||
|
||||
|
||||
@@ -9,10 +9,8 @@ import {
|
||||
finalize,
|
||||
map,
|
||||
mergeMap,
|
||||
pairwise,
|
||||
switchMap,
|
||||
take,
|
||||
tap,
|
||||
timeout,
|
||||
withLatestFrom,
|
||||
} from 'rxjs/operators';
|
||||
@@ -29,7 +27,6 @@ import {
|
||||
GetMyEmailRequest,
|
||||
GetMyEmailResponse,
|
||||
GetMyLabelPolicyRequest,
|
||||
GetMyLabelPolicyResponse,
|
||||
GetMyLoginPolicyRequest,
|
||||
GetMyLoginPolicyResponse,
|
||||
GetMyPasswordComplexityPolicyRequest,
|
||||
@@ -426,11 +423,7 @@ export class GrpcAuthService {
|
||||
return this.grpcService.auth.listMyUserSessions(req, null).then((resp) => resp.toObject());
|
||||
}
|
||||
|
||||
public listMyUserGrants(
|
||||
limit?: number,
|
||||
offset?: number,
|
||||
queryList?: ListQuery[],
|
||||
): Promise<ListMyUserGrantsResponse.AsObject> {
|
||||
public listMyUserGrants(limit?: number, offset?: number, asc?: boolean): Promise<ListMyUserGrantsResponse.AsObject> {
|
||||
const req = new ListMyUserGrantsRequest();
|
||||
const query = new ListQuery();
|
||||
if (limit) {
|
||||
@@ -439,6 +432,9 @@ export class GrpcAuthService {
|
||||
if (offset) {
|
||||
query.setOffset(offset);
|
||||
}
|
||||
if (asc !== undefined) {
|
||||
query.setAsc(asc);
|
||||
}
|
||||
req.setQuery(query);
|
||||
return this.grpcService.auth.listMyUserGrants(req, null).then((resp) => resp.toObject());
|
||||
}
|
||||
|
||||
@@ -4,8 +4,6 @@ import { Empty } from 'google-protobuf/google/protobuf/empty_pb';
|
||||
import { Timestamp } from 'google-protobuf/google/protobuf/timestamp_pb';
|
||||
import { BehaviorSubject } from 'rxjs';
|
||||
|
||||
import { FlowType, TriggerType } from '../proto/generated/zitadel/action_pb';
|
||||
import { RemoveLabelPolicyLogoDarkRequest } from '../proto/generated/zitadel/admin_pb';
|
||||
import { AppQuery } from '../proto/generated/zitadel/app_pb';
|
||||
import { KeyType } from '../proto/generated/zitadel/auth_n_key_pb';
|
||||
import { ChangeQuery } from '../proto/generated/zitadel/change_pb';
|
||||
|
||||
@@ -2,8 +2,6 @@ import { Injectable } from '@angular/core';
|
||||
import { BehaviorSubject, Observable } from 'rxjs';
|
||||
import { LabelPolicy } from '../proto/generated/zitadel/policy_pb';
|
||||
|
||||
import { GrpcAuthService } from './grpc-auth.service';
|
||||
|
||||
declare const tinycolor: any;
|
||||
|
||||
export interface Color {
|
||||
|
||||
Reference in New Issue
Block a user