diff --git a/console/src/app/app-routing.module.ts b/console/src/app/app-routing.module.ts index 940f850d3..77b867b51 100644 --- a/console/src/app/app-routing.module.ts +++ b/console/src/app/app-routing.module.ts @@ -55,6 +55,11 @@ const routes: Routes = [ roles: ['org.read'], }, }, + { + path: 'grant-create', + loadChildren: () => import('src/app/pages/user-grant-create/user-grant-create.module') + .then(m => m.UserGrantCreateModule), + }, { path: 'signedout', loadChildren: () => import('./pages/signedout/signedout.module').then(m => m.SignedoutModule), diff --git a/console/src/app/app.component.html b/console/src/app/app.component.html index bc345db41..3d686a1ff 100644 --- a/console/src/app/app.component.html +++ b/console/src/app/app.component.html @@ -23,7 +23,6 @@ diff --git a/console/src/app/app.component.scss b/console/src/app/app.component.scss index 65e8dbe45..9cbfab785 100644 --- a/console/src/app/app.component.scss +++ b/console/src/app/app.component.scss @@ -68,6 +68,7 @@ font-size: 12px; padding: 4px 2rem; position: relative; + overflow: hidden; } .main-container { @@ -107,7 +108,6 @@ text-decoration: none; cursor: pointer; padding: 0.2rem 1rem; - // color: inherit; margin-right: 0.5rem; padding-right: 2rem; @@ -195,23 +195,6 @@ } } -.footer { - padding: 1rem; - a { - cursor: pointer; - text-decoration: none; - color: #81868a; - font-size: .8rem; - display: block; - margin-bottom: 1px; - font-weight: 300; - - &:hover { - text-decoration: underline; - } - } -} - .divider { display: block; background-color: #ffffff10; diff --git a/console/src/app/app.module.ts b/console/src/app/app.module.ts index 70032f44f..1d49a5a55 100644 --- a/console/src/app/app.module.ts +++ b/console/src/app/app.module.ts @@ -57,11 +57,10 @@ const stateHandlerFn = (stateHandler: StatehandlerService) => { }; }; -export const authConfig: AuthConfig = { +export let authConfig = { redirectUri: window.location.origin + '/auth/callback', scope: 'openid profile email', // offline_access responseType: 'code', - // showDebugInformation: true, oidc: true, postLogoutRedirectUri: window.location.origin + '/signedout', }; @@ -152,4 +151,9 @@ export const authConfig: AuthConfig = { ], bootstrap: [AppComponent], }) -export class AppModule { } +export class AppModule { + + constructor() { + console.log(window.location.href); + } +} diff --git a/console/src/app/modules/accounts-card/accounts-card.component.html b/console/src/app/modules/accounts-card/accounts-card.component.html index ce8b18bb9..6d8b93598 100644 --- a/console/src/app/modules/accounts-card/accounts-card.component.html +++ b/console/src/app/modules/accounts-card/accounts-card.component.html @@ -7,11 +7,13 @@ {{profile?.userName}} IAM USER - +
{{ 'PROJECT.MEMBER.DESCRIPTION' | translate }}
-|
- |
- |
{{ 'PROJECT.MEMBER.ROLES' | translate }} | - + {{ 'ROLES.'+role | translate }} |
|---|
|
- |
- |
- |
- |
{{ 'PROJECT.GRANT.USER' | translate }} | ++ {{grant?.firstName}} {{grant?.lastName}} | +{{ 'PROJECT.GRANT.GRANTEDORGDOMAIN' | translate }} | - {{grant.orgDomain}} | + {{grant.orgDomain}} {{grant.orgName}}{{ 'PROJECT.GRANT.ROLENAMESLIST' | translate }} | -- {{role}} | +
+
+ |
|---|
|
- |
- |
|---|
{{ 'PROJECT.PAGES.LISTDESCRIPTION' | translate }}
-|
- |
- |
diff --git a/console/src/app/pages/iam/iam-members/iam-members.component.scss b/console/src/app/pages/iam/iam-members/iam-members.component.scss
index 2d707d205..b66a6f7b3 100644
--- a/console/src/app/pages/iam/iam-members/iam-members.component.scss
+++ b/console/src/app/pages/iam/iam-members/iam-members.component.scss
@@ -20,7 +20,7 @@
width: 100%;
display: block;
font-size: .9rem;
- color: #81868a;
+ color: #8795a1;
}
}
}
@@ -34,7 +34,7 @@
flex-direction: column;
.desc {
font-size: .8rem;
- color: #81868a;
+ color: #8795a1;
}
.count {
font-size: 2rem;
diff --git a/console/src/app/pages/iam/iam.component.scss b/console/src/app/pages/iam/iam.component.scss
index 7164e8d7a..0d6fd6ed2 100644
--- a/console/src/app/pages/iam/iam.component.scss
+++ b/console/src/app/pages/iam/iam.component.scss
@@ -4,13 +4,13 @@ h1 {
}
.sub {
- color: #81868a;
+ color: #8795a1;
margin-bottom: 2rem;
}
.state-label {
font-size: .9rem;
- color: #81868a;
+ color: #8795a1;
margin-bottom: .5rem;
}
@@ -35,7 +35,7 @@ h1 {
flex-direction: column;
.desc {
font-size: .8rem;
- color: #81868a;
+ color: #8795a1;
}
.count {
font-size: 2rem;
@@ -145,7 +145,7 @@ h1 {
}
.side-section {
- color: #81868a;
+ color: #8795a1;
}
}
}
diff --git a/console/src/app/pages/orgs/org-contributors/org-contributors.component.scss b/console/src/app/pages/orgs/org-contributors/org-contributors.component.scss
index 9585a8cd4..1d9b82ea2 100644
--- a/console/src/app/pages/orgs/org-contributors/org-contributors.component.scss
+++ b/console/src/app/pages/orgs/org-contributors/org-contributors.component.scss
@@ -9,7 +9,7 @@
.sub-header {
font-size: .8rem;
- color: #81868a;
+ color: #8795a1;
}
.people {
@@ -35,7 +35,6 @@
height: 32px;
width: 32px;
border-radius: 50%;
- box-shadow: 0 5px 5px rgba(0, 0, 0, 0.5), 0 3px 6px rgba(0, 0, 0, 0.5);
}
.add-img {
diff --git a/console/src/app/pages/orgs/org-create/org-create.component.scss b/console/src/app/pages/orgs/org-create/org-create.component.scss
index 48ae50e75..2ddf729d9 100644
--- a/console/src/app/pages/orgs/org-create/org-create.component.scss
+++ b/console/src/app/pages/orgs/org-create/org-create.component.scss
@@ -35,7 +35,7 @@ h1 {
}
.desc {
- color: #81868a;
+ color: #8795a1;
font-size: .9rem;
margin: 1rem 0;
}
@@ -65,7 +65,7 @@ h1 {
width: 100%;
display: block;
font-size: .9rem;
- color: #81868a;
+ color: #8795a1;
}
}
.form {
@@ -91,7 +91,7 @@ h1 {
.section {
padding: .5rem;
flex-basis: 100%;
- color: #81868a;
+ color: #8795a1;
font-size: .9rem;
}
diff --git a/console/src/app/pages/orgs/org-detail/org-detail.component.scss b/console/src/app/pages/orgs/org-detail/org-detail.component.scss
index c1fc0e0c4..d2b3e5eed 100644
--- a/console/src/app/pages/orgs/org-detail/org-detail.component.scss
+++ b/console/src/app/pages/orgs/org-detail/org-detail.component.scss
@@ -4,13 +4,13 @@ h1 {
}
.sub {
- color: #81868a;
+ color: #8795a1;
margin-bottom: 2rem;
}
.state-label {
font-size: .9rem;
- color: #81868a;
+ color: #8795a1;
margin-bottom: .5rem;
}
@@ -35,7 +35,7 @@ h1 {
flex-direction: column;
.desc {
font-size: .8rem;
- color: #81868a;
+ color: #8795a1;
}
.count {
font-size: 2rem;
@@ -145,7 +145,7 @@ h1 {
}
.side-section {
- color: #81868a;
+ color: #8795a1;
}
}
}
\ No newline at end of file
diff --git a/console/src/app/pages/orgs/org-grid/org-grid.component.scss b/console/src/app/pages/orgs/org-grid/org-grid.component.scss
index 7ef9fc710..8b19a6a58 100644
--- a/console/src/app/pages/orgs/org-grid/org-grid.component.scss
+++ b/console/src/app/pages/orgs/org-grid/org-grid.component.scss
@@ -4,7 +4,7 @@ h1 {
}
.top-desc {
- color: #81868a;
+ color: #8795a1;
}
.view-toggle {
@@ -147,7 +147,7 @@ h1 {
margin-right: 3px;
font-size: 1.3rem;
height: 1.4rem;
- color: #81868a;
+ color: #8795a1;
}
}
}
diff --git a/console/src/app/pages/orgs/org-members/org-members.component.html b/console/src/app/pages/orgs/org-members/org-members.component.html
index 0903459d6..67fe4ade3 100644
--- a/console/src/app/pages/orgs/org-members/org-members.component.html
+++ b/console/src/app/pages/orgs/org-members/org-members.component.html
@@ -46,13 +46,13 @@
[dataSource]="dataSource">
- |
- |
diff --git a/console/src/app/pages/orgs/org-members/org-members.component.scss b/console/src/app/pages/orgs/org-members/org-members.component.scss
index 1bd190f18..281b9526e 100644
--- a/console/src/app/pages/orgs/org-members/org-members.component.scss
+++ b/console/src/app/pages/orgs/org-members/org-members.component.scss
@@ -36,7 +36,7 @@
width: 100%;
display: block;
font-size: .9rem;
- color: #81868a;
+ color: #8795a1;
}
}
}
@@ -51,7 +51,7 @@
flex-direction: column;
.desc {
font-size: .8rem;
- color: #81868a;
+ color: #8795a1;
}
.count {
font-size: 2rem;
diff --git a/console/src/app/pages/orgs/password-policy/password-policy.component.scss b/console/src/app/pages/orgs/password-policy/password-policy.component.scss
index 0af023f5e..12d5cbedd 100644
--- a/console/src/app/pages/orgs/password-policy/password-policy.component.scss
+++ b/console/src/app/pages/orgs/password-policy/password-policy.component.scss
@@ -34,7 +34,7 @@
width: 100%;
display: block;
font-size: .9rem;
- color: #81868a;
+ color: #8795a1;
}
}
@@ -50,7 +50,7 @@
.left-desc {
text-transform: uppercase;
- color: #81868a;
+ color: #8795a1;
font-size: .9rem;
}
diff --git a/console/src/app/pages/orgs/policy-grid/policy-grid.component.scss b/console/src/app/pages/orgs/policy-grid/policy-grid.component.scss
index 0a8d9698b..4662607ab 100644
--- a/console/src/app/pages/orgs/policy-grid/policy-grid.component.scss
+++ b/console/src/app/pages/orgs/policy-grid/policy-grid.component.scss
@@ -3,7 +3,7 @@ h1 {
}
.top-desc {
- color: #81868a;
+ color: #8795a1;
}
.row-lyt {
diff --git a/console/src/app/pages/owned-projects/owned-project-detail/owned-project-detail.component.html b/console/src/app/pages/owned-projects/owned-project-detail/owned-project-detail.component.html
index a3d4cac6b..ed4cfab06 100644
--- a/console/src/app/pages/owned-projects/owned-project-detail/owned-project-detail.component.html
+++ b/console/src/app/pages/owned-projects/owned-project-detail/owned-project-detail.component.html
@@ -74,6 +74,16 @@
+
+
|---|
|
- |
- |
|---|
|
- |
- |
- |
- |
-
-
-
-
-
- Members
-
- 0">
- {{mem.firstName}} {{mem.lastName}}
- {{mem.email}} |
- {{role}}
-
- |
-
|---|
{{org?.name}}
- created: - {{org.creationDate | timestampToDate | date: 'EEE dd. MMM, HH:mm'}} -{{ 'CHANGES.USER.TITLE' | translate }}
+
+ {{'PROJECT.GRANT.CREATE.ORG_DESCRIPTION' | translate: org}}
+
+ {{'PROJECT.GRANT.CREATE.ORG_DESCRIPTION_DESC' | translate}}
+
{{'PROJECT.GRANT.CREATE.ORG_DESCRIPTION' | translate: org}}
-{{org?.name}}
+{{'PROJECT.GRANT.CREATE.ORG_DESCRIPTION_DESC' | translate}}
- -|
- |
-
- |
+ |
diff --git a/console/src/app/pages/user-list/user-list.component.scss b/console/src/app/pages/user-list/user-list.component.scss
index 9bbe7ac01..c87795e32 100644
--- a/console/src/app/pages/user-list/user-list.component.scss
+++ b/console/src/app/pages/user-list/user-list.component.scss
@@ -4,7 +4,7 @@ h1 {
}
.sub {
- color: #81868a;
+ color: #8795a1;
margin-bottom: 2rem;
}
@@ -18,7 +18,7 @@ h1 {
.desc {
font-size: .8rem;
- color: #81868a;
+ color: #8795a1;
}
.count {
font-size: 2rem;
@@ -61,6 +61,19 @@ h1 {
}
}
+ // tr {
+ // .avatar {
+ // filter: grayscale(100%);
+ // transition: filter .1s ease-in-out;
+ // }
+
+ // &:hover {
+ // .avatar {
+ // filter: none;
+ // }
+ // }
+ // }
+
.data-row {
cursor: pointer;
&:hover {
diff --git a/console/src/app/pages/user-list/user-list.module.ts b/console/src/app/pages/user-list/user-list.module.ts
index b85509cc8..923dfe4a0 100644
--- a/console/src/app/pages/user-list/user-list.module.ts
+++ b/console/src/app/pages/user-list/user-list.module.ts
@@ -13,6 +13,7 @@ import { MatTooltipModule } from '@angular/material/tooltip';
import { TranslateLoader, TranslateModule } from '@ngx-translate/core';
import { HttpLoaderFactory } from 'src/app/app.module';
import { HasRoleModule } from 'src/app/directives/has-role/has-role.module';
+import { AvatarModule } from 'src/app/modules/avatar/avatar.module';
import { CardModule } from 'src/app/modules/card/card.module';
import { UserListRoutingModule } from './user-list-routing.module';
@@ -25,6 +26,7 @@ import { UserListComponent } from './user-list.component';
UserListComponent,
],
imports: [
+ AvatarModule,
UserListRoutingModule,
CommonModule,
FormsModule,
diff --git a/console/src/app/pipes/has-role.pipe.ts b/console/src/app/pipes/has-role.pipe.ts
new file mode 100644
index 000000000..a684b7124
--- /dev/null
+++ b/console/src/app/pipes/has-role.pipe.ts
@@ -0,0 +1,16 @@
+import { Pipe, PipeTransform } from '@angular/core';
+
+import { AuthUserService } from '../services/auth-user.service';
+
+@Pipe({
+ name: 'hasRole',
+ pure: false,
+})
+export class HasRolePipe implements PipeTransform {
+
+ constructor(private authUserService: AuthUserService) { }
+
+ public transform(values: string[], each: boolean = false): any {
+ return this.authUserService.isAllowed(values, each);
+ }
+}
diff --git a/console/src/app/pipes/pipes.module.ts b/console/src/app/pipes/pipes.module.ts
index 4a724a773..30e205d37 100644
--- a/console/src/app/pipes/pipes.module.ts
+++ b/console/src/app/pipes/pipes.module.ts
@@ -2,6 +2,7 @@ import { CommonModule } from '@angular/common';
import { NgModule } from '@angular/core';
import { MomentModule } from 'ngx-moment';
+import { HasRolePipe } from './has-role.pipe';
import { LocalizedDatePipe } from './localized-date.pipe';
import { TimestampToDatePipe } from './timestamp-to-date.pipe';
@@ -10,6 +11,7 @@ import { TimestampToDatePipe } from './timestamp-to-date.pipe';
declarations: [
LocalizedDatePipe,
TimestampToDatePipe,
+ HasRolePipe,
],
imports: [
CommonModule,
@@ -18,6 +20,7 @@ import { TimestampToDatePipe } from './timestamp-to-date.pipe';
exports: [
LocalizedDatePipe,
TimestampToDatePipe,
+ HasRolePipe,
],
})
export class PipesModule { }
diff --git a/console/src/app/proto/generated/management_pb.d.ts b/console/src/app/proto/generated/management_pb.d.ts
index db2e26c94..109ace340 100644
--- a/console/src/app/proto/generated/management_pb.d.ts
+++ b/console/src/app/proto/generated/management_pb.d.ts
@@ -113,6 +113,9 @@ export class Change extends jspb.Message {
getSequence(): number;
setSequence(value: number): void;
+ getEditorId(): string;
+ setEditorId(value: string): void;
+
getEditor(): string;
setEditor(value: string): void;
@@ -134,6 +137,7 @@ export namespace Change {
changeDate?: google_protobuf_timestamp_pb.Timestamp.AsObject,
eventType: string,
sequence: number,
+ editorId: string,
editor: string,
data?: google_protobuf_struct_pb.Struct.AsObject,
}
diff --git a/console/src/app/proto/generated/management_pb.js b/console/src/app/proto/generated/management_pb.js
index dd846e1d8..1d605f4d8 100644
--- a/console/src/app/proto/generated/management_pb.js
+++ b/console/src/app/proto/generated/management_pb.js
@@ -3820,7 +3820,8 @@ proto.caos.zitadel.management.api.v1.Change.toObject = function(includeInstance,
changeDate: (f = msg.getChangeDate()) && google_protobuf_timestamp_pb.Timestamp.toObject(includeInstance, f),
eventType: jspb.Message.getFieldWithDefault(msg, 2, ""),
sequence: jspb.Message.getFieldWithDefault(msg, 3, 0),
- editor: jspb.Message.getFieldWithDefault(msg, 4, ""),
+ editorId: jspb.Message.getFieldWithDefault(msg, 4, ""),
+ editor: jspb.Message.getFieldWithDefault(msg, 5, ""),
data: (f = msg.getData()) && google_protobuf_struct_pb.Struct.toObject(includeInstance, f)
};
@@ -3873,9 +3874,13 @@ proto.caos.zitadel.management.api.v1.Change.deserializeBinaryFromReader = functi
break;
case 4:
var value = /** @type {string} */ (reader.readString());
- msg.setEditor(value);
+ msg.setEditorId(value);
break;
case 5:
+ var value = /** @type {string} */ (reader.readString());
+ msg.setEditor(value);
+ break;
+ case 6:
var value = new google_protobuf_struct_pb.Struct;
reader.readMessage(value,google_protobuf_struct_pb.Struct.deserializeBinaryFromReader);
msg.setData(value);
@@ -3931,17 +3936,24 @@ proto.caos.zitadel.management.api.v1.Change.serializeBinaryToWriter = function(m
f
);
}
- f = message.getEditor();
+ f = message.getEditorId();
if (f.length > 0) {
writer.writeString(
4,
f
);
}
+ f = message.getEditor();
+ if (f.length > 0) {
+ writer.writeString(
+ 5,
+ f
+ );
+ }
f = message.getData();
if (f != null) {
writer.writeMessage(
- 5,
+ 6,
f,
google_protobuf_struct_pb.Struct.serializeBinaryToWriter
);
@@ -4013,33 +4025,48 @@ proto.caos.zitadel.management.api.v1.Change.prototype.setSequence = function(val
/**
- * optional string editor = 4;
+ * optional string editor_id = 4;
* @return {string}
*/
-proto.caos.zitadel.management.api.v1.Change.prototype.getEditor = function() {
+proto.caos.zitadel.management.api.v1.Change.prototype.getEditorId = function() {
return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 4, ""));
};
/** @param {string} value */
-proto.caos.zitadel.management.api.v1.Change.prototype.setEditor = function(value) {
+proto.caos.zitadel.management.api.v1.Change.prototype.setEditorId = function(value) {
jspb.Message.setProto3StringField(this, 4, value);
};
/**
- * optional google.protobuf.Struct data = 5;
+ * optional string editor = 5;
+ * @return {string}
+ */
+proto.caos.zitadel.management.api.v1.Change.prototype.getEditor = function() {
+ return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 5, ""));
+};
+
+
+/** @param {string} value */
+proto.caos.zitadel.management.api.v1.Change.prototype.setEditor = function(value) {
+ jspb.Message.setProto3StringField(this, 5, value);
+};
+
+
+/**
+ * optional google.protobuf.Struct data = 6;
* @return {?proto.google.protobuf.Struct}
*/
proto.caos.zitadel.management.api.v1.Change.prototype.getData = function() {
return /** @type{?proto.google.protobuf.Struct} */ (
- jspb.Message.getWrapperField(this, google_protobuf_struct_pb.Struct, 5));
+ jspb.Message.getWrapperField(this, google_protobuf_struct_pb.Struct, 6));
};
/** @param {?proto.google.protobuf.Struct|undefined} value */
proto.caos.zitadel.management.api.v1.Change.prototype.setData = function(value) {
- jspb.Message.setWrapperField(this, 5, value);
+ jspb.Message.setWrapperField(this, 6, value);
};
@@ -4056,7 +4083,7 @@ proto.caos.zitadel.management.api.v1.Change.prototype.clearData = function() {
* @return {boolean}
*/
proto.caos.zitadel.management.api.v1.Change.prototype.hasData = function() {
- return jspb.Message.getField(this, 5) != null;
+ return jspb.Message.getField(this, 6) != null;
};
diff --git a/console/src/app/services/mgmt-user.service.ts b/console/src/app/services/mgmt-user.service.ts
index af5bb0255..c9d48b2a1 100644
--- a/console/src/app/services/mgmt-user.service.ts
+++ b/console/src/app/services/mgmt-user.service.ts
@@ -15,6 +15,9 @@ import {
ProjectGrantMemberSearchQuery,
ProjectGrantMemberSearchRequest,
ProjectGrantMemberSearchResponse,
+ ProjectGrantUserGrantID,
+ ProjectGrantUserGrantSearchRequest,
+ ProjectGrantUserGrantUpdate,
ProjectRoleAdd,
SetPasswordNotificationRequest,
UpdateUserAddressRequest,
@@ -26,9 +29,12 @@ import {
UserEmail,
UserGrant,
UserGrantCreate,
+ UserGrantID,
UserGrantSearchQuery,
UserGrantSearchRequest,
UserGrantSearchResponse,
+ UserGrantUpdate,
+ UserGrantView,
UserID,
UserPhone,
UserProfile,
@@ -367,6 +373,93 @@ export class MgmtUserService {
);
}
+
+ public async searchProjectGrantUserGrants(
+ limit: number,
+ offset: number,
+ queryList?: UserGrantSearchQuery[],
+ ): Promise |
|---|