feat(console): grpc web interceptors, cleanup services (#631)

* managementservice, authservice, change all refs

* refactor grpc auth

* fix references

* interceptor logic

* new interceptor

* appinitializers, environment loader, interceptors

* remove circular dep

* init authconfig in grpc service

* authconfig

* lint

* update mgmt service

* fix references

* update clientid, fix interceptor

* rm unused authconfig

* todo auth interceptor
This commit is contained in:
Max Peintner
2020-08-29 10:43:35 +02:00
committed by GitHub
parent 40b8faaddd
commit eeea1f1c4b
81 changed files with 1877 additions and 2639 deletions
@@ -12,8 +12,7 @@ import {
UserGrantSearchQuery,
UserGrantView,
} from 'src/app/proto/generated/management_pb';
import { MgmtUserService } from 'src/app/services/mgmt-user.service';
import { ProjectService } from 'src/app/services/project.service';
import { ManagementService } from 'src/app/services/mgmt.service';
import { ToastService } from 'src/app/services/toast.service';
import { UserGrantContext, UserGrantsDataSource } from './user-grants-datasource';
@@ -51,8 +50,8 @@ export class UserGrantsComponent implements OnInit, AfterViewInit {
public UserGrantContext: any = UserGrantContext;
constructor(
private userService: MgmtUserService,
private projectService: ProjectService,
private userService: ManagementService,
private mgmtService: ManagementService,
private toast: ToastService,
) { }
@@ -125,7 +124,7 @@ export class UserGrantsComponent implements OnInit, AfterViewInit {
}
public getGrantRoleOptions(grantId: string, projectId: string): void {
this.projectService.GetGrantedProjectByID(projectId, grantId).then(resp => {
this.mgmtService.GetGrantedProjectByID(projectId, grantId).then(resp => {
this.loadedGrantId = projectId;
this.grantRoleOptions = resp.toObject().roleKeysList;
}).catch(error => {
@@ -134,7 +133,7 @@ export class UserGrantsComponent implements OnInit, AfterViewInit {
}
public getProjectRoleOptions(projectId: string): void {
this.projectService.SearchProjectRoles(projectId, 100, 0).then(resp => {
this.mgmtService.SearchProjectRoles(projectId, 100, 0).then(resp => {
this.loadedProjectId = projectId;
this.projectRoleOptions = resp.toObject().resultList;
});