diff --git a/console/src/app/app-routing.module.ts b/console/src/app/app-routing.module.ts
index 5eb260c94f..65147aed33 100644
--- a/console/src/app/app-routing.module.ts
+++ b/console/src/app/app-routing.module.ts
@@ -63,6 +63,15 @@ const routes: Routes = [
roles: ['iam.read', 'iam.write'],
},
},
+ {
+ path: 'org/create',
+ component: OrgCreateComponent,
+ canActivate: [AuthGuard, RoleGuard],
+ data: {
+ roles: ['(org.create)?(iam.write)?'],
+ },
+ loadChildren: () => import('./pages/org-create/org-create.module').then((m) => m.OrgCreateModule),
+ },
{
path: 'org',
loadChildren: () => import('./pages/orgs/orgs.module').then((m) => m.OrgsModule),
@@ -71,15 +80,6 @@ const routes: Routes = [
roles: ['org.read'],
},
},
- {
- path: 'org/create',
- component: OrgCreateComponent,
- canActivate: [RoleGuard],
- data: {
- roles: ['(org.create)?(iam.write)?'],
- },
- loadChildren: () => import('./pages/org-create/org-create.module').then((m) => m.OrgCreateModule),
- },
{
path: 'actions',
loadChildren: () => import('./pages/actions/actions.module').then((m) => m.ActionsModule),
diff --git a/console/src/app/app.module.ts b/console/src/app/app.module.ts
index 7112bd4ef0..df20a5c91c 100644
--- a/console/src/app/app.module.ts
+++ b/console/src/app/app.module.ts
@@ -11,6 +11,7 @@ import { MatDialogModule } from '@angular/material/dialog';
import { MatIconModule } from '@angular/material/icon';
import { MatProgressBarModule } from '@angular/material/progress-bar';
import { MatProgressSpinnerModule } from '@angular/material/progress-spinner';
+import { MatSelectModule } from '@angular/material/select';
import { MatSidenavModule } from '@angular/material/sidenav';
import { MatSnackBarModule } from '@angular/material/snack-bar';
import { MatToolbarModule } from '@angular/material/toolbar';
@@ -130,6 +131,7 @@ const authConfig: AuthConfig = {
MatSnackBarModule,
AvatarModule,
WarnDialogModule,
+ MatSelectModule,
MatDialogModule,
RegExpPipeModule,
OnboardingModule,
diff --git a/console/src/app/pages/org-create/org-create.component.html b/console/src/app/pages/org-create/org-create.component.html
index e132a529b8..7a227598a0 100644
--- a/console/src/app/pages/org-create/org-create.component.html
+++ b/console/src/app/pages/org-create/org-create.component.html
@@ -1,183 +1,183 @@
-
-
-
+
+
+ {{ 'ORG.PAGES.CREATE' | translate }}
+ Step {{ currentCreateStep }} of {{ createSteps }}
+
-
-
- Use your personal account as organisation owner
-
+
+
+ {{'ORG.PAGES.USERSELFACCOUNT' | translate}}
+
-
-
- {{'ORG.PAGES.ORGDETAIL_TITLE' | translate}}
+
+
+ {{'ORG.PAGES.ORGDETAIL_TITLE' | translate}}
-
+
+
+
+ {{'ORG.PAGES.ORGDETAILUSER_TITLE' | translate}}
+
+
\ No newline at end of file
diff --git a/console/src/app/pages/org-create/org-create.component.ts b/console/src/app/pages/org-create/org-create.component.ts
index 607c57b7c1..5e794601a8 100644
--- a/console/src/app/pages/org-create/org-create.component.ts
+++ b/console/src/app/pages/org-create/org-create.component.ts
@@ -44,9 +44,7 @@ function passwordConfirmValidator(c: AbstractControl): any {
style({ height: '0', opacity: 0 }),
animate('150ms ease-in-out', style({ height: '*', opacity: 1 })),
]),
- transition(':leave', [
- animate('150ms ease-in-out', style({ height: '0', opacity: 0 })),
- ]),
+ transition(':leave', [animate('150ms ease-in-out', style({ height: '0', opacity: 0 }))]),
]),
],
})
@@ -72,11 +70,14 @@ export class OrgCreateComponent {
private mgmtService: ManagementService,
private authService: GrpcAuthService,
) {
- this.authService.isAllowed(['iam.write']).pipe(take(1)).subscribe((allowed) => {
- if (allowed) {
- this.forSelf = false;
- }
- });
+ this.authService
+ .isAllowed(['iam.write'])
+ .pipe(take(1))
+ .subscribe((allowed) => {
+ if (allowed) {
+ this.forSelf = false;
+ }
+ });
this.orgForm = this.fb.group({
name: ['', [Validators.required]],
@@ -123,7 +124,7 @@ export class OrgCreateComponent {
// this.router.navigate(['/org', 'overview']);
// }
})
- .catch(error => {
+ .catch((error) => {
this.toast.showError(error);
});
}
@@ -152,7 +153,7 @@ export class OrgCreateComponent {
const validators: Validators[] = [Validators.required];
if (this.usePassword) {
- this.mgmtService.getDefaultPasswordComplexityPolicy().then(data => {
+ this.mgmtService.getDefaultPasswordComplexityPolicy().then((data) => {
if (data.policy) {
this.policy = data.policy;
@@ -195,7 +196,6 @@ export class OrgCreateComponent {
this.orgForm = this.fb.group({
name: ['', [Validators.required]],
});
-
} else {
this.createSteps = 2;
@@ -208,16 +208,14 @@ export class OrgCreateComponent {
public createOrgForSelf(): void {
if (this.name && this.name.value) {
- this.mgmtService.addOrg(this.name.value).then(() => {
- this.router.navigate(['/org/overview']);
- // const newOrg = org.toObject();
- // setTimeout(() => {
- // this.authService.setActiveOrg(newOrg);
- // this.router.navigate(['/org']);
- // }, 1000);
- }).catch(error => {
- this.toast.showError(error);
- });
+ this.mgmtService
+ .addOrg(this.name.value)
+ .then(() => {
+ this.router.navigate(['/org/overview']);
+ })
+ .catch((error) => {
+ this.toast.showError(error);
+ });
}
}
diff --git a/console/src/app/pages/org-create/org-create.module.ts b/console/src/app/pages/org-create/org-create.module.ts
index f86e6a412f..411aec252f 100644
--- a/console/src/app/pages/org-create/org-create.module.ts
+++ b/console/src/app/pages/org-create/org-create.module.ts
@@ -16,22 +16,22 @@ import { OrgCreateRoutingModule } from './org-create-routing.module';
import { OrgCreateComponent } from './org-create.component';
@NgModule({
- declarations: [OrgCreateComponent],
- imports: [
- OrgCreateRoutingModule,
- CommonModule,
- FormsModule,
- ReactiveFormsModule,
- InputModule,
- MatButtonModule,
- MatIconModule,
- MatSelectModule,
- HasRolePipeModule,
- TranslateModule,
- HasRoleModule,
- MatCheckboxModule,
- PasswordComplexityViewModule,
- MatSlideToggleModule,
- ],
+ declarations: [OrgCreateComponent],
+ imports: [
+ OrgCreateRoutingModule,
+ CommonModule,
+ FormsModule,
+ ReactiveFormsModule,
+ InputModule,
+ MatButtonModule,
+ MatIconModule,
+ MatSelectModule,
+ HasRolePipeModule,
+ TranslateModule,
+ HasRoleModule,
+ MatCheckboxModule,
+ PasswordComplexityViewModule,
+ MatSlideToggleModule,
+ ],
})
-export class OrgCreateModule { }
+export class OrgCreateModule {}
diff --git a/console/src/assets/i18n/de.json b/console/src/assets/i18n/de.json
index 5252f470e6..52b228cb97 100644
--- a/console/src/assets/i18n/de.json
+++ b/console/src/assets/i18n/de.json
@@ -641,6 +641,7 @@
"LISTDESCRIPTION": "Wähle eine Organisation aus.",
"ACTIVE": "Aktiv",
"CREATE": "Organisation erstellen",
+ "USERSELFACCOUNT": "Verwenden Sie Ihr persönliches Konto als Organisationsinhaber",
"ORGDETAIL_TITLE": "Gebe den Namen und die Domain für die neue Organisation ein.",
"ORGDETAIL_TITLE_WITHOUT_DOMAIN": "Geben Sie den Namen der neuen Organisation ein.",
"ORGDETAILUSER_TITLE": "Organisationsbesitzer hinzufügen",
diff --git a/console/src/assets/i18n/en.json b/console/src/assets/i18n/en.json
index 8fc1ae13fc..7e35a0f6c0 100644
--- a/console/src/assets/i18n/en.json
+++ b/console/src/assets/i18n/en.json
@@ -641,6 +641,7 @@
"LISTDESCRIPTION": "Choose an organisation.",
"ACTIVE": "Active",
"CREATE": "Create Organisation",
+ "USERSELFACCOUNT": "Use your personal account as organisation owner",
"ORGDETAIL_TITLE": "Enter the name and domain of your new organisation.",
"ORGDETAIL_TITLE_WITHOUT_DOMAIN": "Enter the name of your new organisation.",
"ORGDETAILUSER_TITLE": "Configure Organisation Owner",
diff --git a/console/src/assets/i18n/it.json b/console/src/assets/i18n/it.json
index fa8231e353..5ef36acaed 100644
--- a/console/src/assets/i18n/it.json
+++ b/console/src/assets/i18n/it.json
@@ -641,6 +641,7 @@
"LISTDESCRIPTION": "Scegli un'organizzazione.",
"ACTIVE": "Attivo",
"CREATE": "Creare un'organizzazione",
+ "USERSELFACCOUNT": "Usa il tuo account personale come proprietario dell'organizzazione",
"ORGDETAIL_TITLE": "Inserisci il nome e il dominio della tua nuova organizzazione.",
"ORGDETAIL_TITLE_WITHOUT_DOMAIN": "Inserisci il nome della tua nuova organizzazione.",
"ORGDETAILUSER_TITLE": "Configurare il proprietario dell'organizzazione",