You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@dlab.apache.org by an...@apache.org on 2019/05/30 12:58:28 UTC
[incubator-dlab] branch feature/projects updated (8cee4bb ->
17a9e7d)
This is an automated email from the ASF dual-hosted git repository.
ankovalyshyn pushed a change to branch feature/projects
in repository https://gitbox.apache.org/repos/asf/incubator-dlab.git.
from 8cee4bb [DLAB-631]: tabs component fixes
new c65fa44 [DLAB-631]: replaced progress uploading component with material
new c548259 [DLAB-631]: replaced cost detail component with material
new 17a9e7d [DLAB-631]: replaced confirmation dialog component
The 3 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails. The revisions
listed as "add" were already present in the repository and have only
been added to this reference.
Summary of changes:
.../src/app/administration/management/index.ts | 8 ++---
.../management-grid/management-grid.component.html | 1 -
.../management-grid/management-grid.component.ts | 25 ++++++-------
.../management/management.component.html | 2 --
.../management/management.component.ts | 1 -
.../app/administration/roles/roles.component.html | 9 +----
...utational-resource-create-dialog.component.html | 2 +-
.../cost-details-dialog.component.html | 8 +++--
.../cost-details-dialog.component.scss | 0
.../cost-details-dialog.component.ts | 0
.../cost-details-dialog/index.ts | 3 +-
.../detail-dialog/detail-dialog.component.ts | 1 -
.../src/app/resources/resources-grid/index.ts | 2 +-
.../resources-grid/resources-grid.component.html | 13 ++-----
.../resources-grid/resources-grid.component.ts | 26 +++++---------
.../confirmation-dialog.component.html | 26 +++++++-------
.../confirmation-dialog.component.ts | 42 ++++++++--------------
.../modal-dialog/confirmation-dialog/index.ts | 1 +
.../shared/modal-dialog/progress-dialog/index.ts | 5 +--
.../progress-dialog/progress-dialog.component.html | 13 +++----
.../progress-dialog/progress-dialog.component.ts | 18 ++++------
.../src/app/shared/navbar/navbar.component.html | 8 -----
.../src/app/shared/navbar/navbar.component.ts | 11 +++---
.../resources/webapp/src/assets/styles/_theme.scss | 2 +-
24 files changed, 88 insertions(+), 139 deletions(-)
rename services/self-service/src/main/resources/webapp/src/app/resources/{billing => exploratory}/cost-details-dialog/cost-details-dialog.component.html (93%)
rename services/self-service/src/main/resources/webapp/src/app/resources/{billing => exploratory}/cost-details-dialog/cost-details-dialog.component.scss (100%)
rename services/self-service/src/main/resources/webapp/src/app/resources/{billing => exploratory}/cost-details-dialog/cost-details-dialog.component.ts (100%)
rename services/self-service/src/main/resources/webapp/src/app/resources/{billing => exploratory}/cost-details-dialog/index.ts (92%)
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@dlab.apache.org
For additional commands, e-mail: commits-help@dlab.apache.org
[incubator-dlab] 02/03: [DLAB-631]: replaced cost detail component
with material
Posted by an...@apache.org.
This is an automated email from the ASF dual-hosted git repository.
ankovalyshyn pushed a commit to branch feature/projects
in repository https://gitbox.apache.org/repos/asf/incubator-dlab.git
commit c5482594b5b44ceaedc71fff8292bf70ce7318ab
Author: Andriana Kovalyshyn <An...@epam.com>
AuthorDate: Thu May 30 14:30:20 2019 +0300
[DLAB-631]: replaced cost detail component with material
---
.../webapp/src/app/administration/roles/roles.component.html | 9 +--------
.../computational-resource-create-dialog.component.html | 2 +-
.../cost-details-dialog/cost-details-dialog.component.html | 8 +++++---
.../cost-details-dialog/cost-details-dialog.component.scss | 0
.../cost-details-dialog/cost-details-dialog.component.ts | 0
.../{billing => exploratory}/cost-details-dialog/index.ts | 3 +--
.../resources/webapp/src/app/resources/resources-grid/index.ts | 2 +-
.../app/resources/resources-grid/resources-grid.component.html | 4 ++--
.../src/app/resources/resources-grid/resources-grid.component.ts | 5 ++---
.../resources/webapp/src/app/shared/navbar/navbar.component.ts | 1 -
.../src/main/resources/webapp/src/assets/styles/_theme.scss | 2 +-
11 files changed, 14 insertions(+), 22 deletions(-)
diff --git a/services/self-service/src/main/resources/webapp/src/app/administration/roles/roles.component.html b/services/self-service/src/main/resources/webapp/src/app/administration/roles/roles.component.html
index cade0b6..778de7b 100644
--- a/services/self-service/src/main/resources/webapp/src/app/administration/roles/roles.component.html
+++ b/services/self-service/src/main/resources/webapp/src/app/administration/roles/roles.component.html
@@ -17,12 +17,7 @@
~ under the License.
-->
-<!-- <modal-dialog #bindDialog modalClass="manage-roles-dialog modal-xxl">
- <modal-header>
- <h4 class="modal-title">Manage roles</h4>
- </modal-header>
- <modal-content> -->
-<div class="content-box">
+<div class="manage-roles">
<button mat-raised-button class="butt add-group" (click)="stepperView = !stepperView">
<i class="material-icons">people_outline</i>Add group
</button>
@@ -157,5 +152,3 @@
</table>
</div>
</div>
-<!-- </modal-content>
-</modal-dialog> -->
\ No newline at end of file
diff --git a/services/self-service/src/main/resources/webapp/src/app/resources/computational/computational-resource-create-dialog/computational-resource-create-dialog.component.html b/services/self-service/src/main/resources/webapp/src/app/resources/computational/computational-resource-create-dialog/computational-resource-create-dialog.component.html
index bfe0b74..6120083 100644
--- a/services/self-service/src/main/resources/webapp/src/app/resources/computational/computational-resource-create-dialog/computational-resource-create-dialog.component.html
+++ b/services/self-service/src/main/resources/webapp/src/app/resources/computational/computational-resource-create-dialog/computational-resource-create-dialog.component.html
@@ -17,7 +17,7 @@
~ under the License.
-->
-<div modalClass="create-cluster" id="dialog-box">
+<div class="create-cluster" id="dialog-box">
<header class="dialog-header">
<h4 class="modal-title">Add computational resources</h4>
<button type="button" class="close" (click)="dialogRef.close()">×</button>
diff --git a/services/self-service/src/main/resources/webapp/src/app/resources/billing/cost-details-dialog/cost-details-dialog.component.html b/services/self-service/src/main/resources/webapp/src/app/resources/exploratory/cost-details-dialog/cost-details-dialog.component.html
similarity index 93%
rename from services/self-service/src/main/resources/webapp/src/app/resources/billing/cost-details-dialog/cost-details-dialog.component.html
rename to services/self-service/src/main/resources/webapp/src/app/resources/exploratory/cost-details-dialog/cost-details-dialog.component.html
index cf904f0..700cc54 100644
--- a/services/self-service/src/main/resources/webapp/src/app/resources/billing/cost-details-dialog/cost-details-dialog.component.html
+++ b/services/self-service/src/main/resources/webapp/src/app/resources/exploratory/cost-details-dialog/cost-details-dialog.component.html
@@ -17,9 +17,11 @@
~ under the License.
-->
-<div modalClass="billing-detail-dialog header-white modal-xl">
- <header></header>
- <div class="modal-content">
+<div id="dialog-box" class="billing-detail-dialog">
+ <header class="dialog-header header-white">
+ <button type="button" class="close" (click)="dialogRef.close()">×</button>
+ </header>
+ <div class="dialog-content">
<div *ngIf="notebook">
<table class="detail-header">
<tr>
diff --git a/services/self-service/src/main/resources/webapp/src/app/resources/billing/cost-details-dialog/cost-details-dialog.component.scss b/services/self-service/src/main/resources/webapp/src/app/resources/exploratory/cost-details-dialog/cost-details-dialog.component.scss
similarity index 100%
rename from services/self-service/src/main/resources/webapp/src/app/resources/billing/cost-details-dialog/cost-details-dialog.component.scss
rename to services/self-service/src/main/resources/webapp/src/app/resources/exploratory/cost-details-dialog/cost-details-dialog.component.scss
diff --git a/services/self-service/src/main/resources/webapp/src/app/resources/billing/cost-details-dialog/cost-details-dialog.component.ts b/services/self-service/src/main/resources/webapp/src/app/resources/exploratory/cost-details-dialog/cost-details-dialog.component.ts
similarity index 100%
rename from services/self-service/src/main/resources/webapp/src/app/resources/billing/cost-details-dialog/cost-details-dialog.component.ts
rename to services/self-service/src/main/resources/webapp/src/app/resources/exploratory/cost-details-dialog/cost-details-dialog.component.ts
diff --git a/services/self-service/src/main/resources/webapp/src/app/resources/billing/cost-details-dialog/index.ts b/services/self-service/src/main/resources/webapp/src/app/resources/exploratory/cost-details-dialog/index.ts
similarity index 92%
rename from services/self-service/src/main/resources/webapp/src/app/resources/billing/cost-details-dialog/index.ts
rename to services/self-service/src/main/resources/webapp/src/app/resources/exploratory/cost-details-dialog/index.ts
index 11a0424..b95c183 100644
--- a/services/self-service/src/main/resources/webapp/src/app/resources/billing/cost-details-dialog/index.ts
+++ b/services/self-service/src/main/resources/webapp/src/app/resources/exploratory/cost-details-dialog/index.ts
@@ -22,12 +22,11 @@ import { CommonModule } from '@angular/common';
import { MaterialModule } from '../../../shared/material.module';
import { CostDetailsDialogComponent } from './cost-details-dialog.component';
-import { ModalModule } from '../../../shared';
export * from './cost-details-dialog.component';
@NgModule({
- imports: [CommonModule, ModalModule, MaterialModule],
+ imports: [CommonModule, MaterialModule],
declarations: [CostDetailsDialogComponent],
entryComponents: [CostDetailsDialogComponent],
exports: [CostDetailsDialogComponent]
diff --git a/services/self-service/src/main/resources/webapp/src/app/resources/resources-grid/index.ts b/services/self-service/src/main/resources/webapp/src/app/resources/resources-grid/index.ts
index ea94971..27e4daa 100644
--- a/services/self-service/src/main/resources/webapp/src/app/resources/resources-grid/index.ts
+++ b/services/self-service/src/main/resources/webapp/src/app/resources/resources-grid/index.ts
@@ -27,7 +27,7 @@ import { ModalModule, ConfirmationDialogModule, BubbleModule } from '../../share
import { ComputationalResourceCreateDialogModule } from '../computational/computational-resource-create-dialog';
import { DetailDialogModule } from '../exploratory/detail-dialog';
import { FormControlsModule } from '../../shared/form-controls';
-import { CostDetailsDialogModule } from '../billing/cost-details-dialog';
+import { CostDetailsDialogModule } from '../exploratory/cost-details-dialog';
import { InstallLibrariesModule } from '../exploratory/install-libraries';
import { AmiCreateDialogModule } from '../exploratory/ami-create-dialog';
import { SchedulerModule } from '../scheduler';
diff --git a/services/self-service/src/main/resources/webapp/src/app/resources/resources-grid/resources-grid.component.html b/services/self-service/src/main/resources/webapp/src/app/resources/resources-grid/resources-grid.component.html
index 2297b6c..4126a52 100644
--- a/services/self-service/src/main/resources/webapp/src/app/resources/resources-grid/resources-grid.component.html
+++ b/services/self-service/src/main/resources/webapp/src/app/resources/resources-grid/resources-grid.component.html
@@ -74,8 +74,8 @@
<computational-resources-list [resources]="env.resources" [environment]="env" [healthStatus]="healthStatus?.status" (buildGrid)="buildGrid($event)"></computational-resources-list>
</td>
<td *ngIf="healthStatus?.billingEnabled">
- <span class="total_cost">{{ env.cost || 'N/A' }} {{env.currency_code || ''}}</span>
- <span (click)="env.billing && printCostDetails(env)" class="currency_details" [ngClass]="{'not-allowed' : !env.billing}">
+ <span class="total_cost">{{ env.cost || 'N/A' }} {{ env.currency_code || '' }}</span>
+ <span (click)="env.billing && printCostDetails(env)" class="currency_details" [ngClass]="{ 'not-allowed' : !env.billing }">
<i class="material-icons">help_outline</i>
</span>
</td>
diff --git a/services/self-service/src/main/resources/webapp/src/app/resources/resources-grid/resources-grid.component.ts b/services/self-service/src/main/resources/webapp/src/app/resources/resources-grid/resources-grid.component.ts
index bf08ec5..aa76c91 100644
--- a/services/self-service/src/main/resources/webapp/src/app/resources/resources-grid/resources-grid.component.ts
+++ b/services/self-service/src/main/resources/webapp/src/app/resources/resources-grid/resources-grid.component.ts
@@ -33,7 +33,7 @@ import { DetailDialogComponent } from '../exploratory/detail-dialog';
import { AmiCreateDialogComponent } from '../exploratory/ami-create-dialog';
import { InstallLibrariesComponent } from '../exploratory/install-libraries';
import { ComputationalResourceCreateDialogComponent } from '../computational/computational-resource-create-dialog/computational-resource-create-dialog.component';
-import { CostDetailsDialogComponent } from '../billing/cost-details-dialog';
+import { CostDetailsDialogComponent } from '../exploratory/cost-details-dialog';
import { SchedulerComponent } from '../scheduler';
import { DICTIONARY } from '../../../dictionary/global.dictionary';
@@ -287,8 +287,7 @@ export class ResourcesGridComponent implements OnInit {
}
printCostDetails(data): void {
- // this.costDetailsDialog.open({ isFooter: false }, data);
- this.dialog.open(CostDetailsDialogComponent, { data: data, panelClass: 'modal-lg' })
+ this.dialog.open(CostDetailsDialogComponent, { data: data, panelClass: 'modal-xl' })
.afterClosed().subscribe(() => this.buildGrid());
}
diff --git a/services/self-service/src/main/resources/webapp/src/app/shared/navbar/navbar.component.ts b/services/self-service/src/main/resources/webapp/src/app/shared/navbar/navbar.component.ts
index 7bf49a0..df29f29 100644
--- a/services/self-service/src/main/resources/webapp/src/app/shared/navbar/navbar.component.ts
+++ b/services/self-service/src/main/resources/webapp/src/app/shared/navbar/navbar.component.ts
@@ -159,7 +159,6 @@ export class NavbarComponent implements OnInit, OnDestroy {
}
private processAccessKeyStatus(status: number): void {
- debugger;
if (status === HTTP_STATUS_CODES.NOT_FOUND || status === HTTP_STATUS_CODES.INTERNAL_SERVER_ERROR) {
!this.dialog.openDialogs.length && this.dialog.closeAll();
diff --git a/services/self-service/src/main/resources/webapp/src/assets/styles/_theme.scss b/services/self-service/src/main/resources/webapp/src/assets/styles/_theme.scss
index 14695e2..b34ca96 100644
--- a/services/self-service/src/main/resources/webapp/src/assets/styles/_theme.scss
+++ b/services/self-service/src/main/resources/webapp/src/assets/styles/_theme.scss
@@ -234,7 +234,7 @@
white-space: pre-line !important;
word-break: break-all;
}
-.manage-roles-dialog,
+.manage-roles,
.project-form {
.mat-form-field {
width: 100%;
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@dlab.apache.org
For additional commands, e-mail: commits-help@dlab.apache.org
[incubator-dlab] 01/03: [DLAB-631]: replaced progress uploading
component with material
Posted by an...@apache.org.
This is an automated email from the ASF dual-hosted git repository.
ankovalyshyn pushed a commit to branch feature/projects
in repository https://gitbox.apache.org/repos/asf/incubator-dlab.git
commit c65fa447a24bba7b93fd0485f9f7a3514ec1cef1
Author: Andriana Kovalyshyn <An...@epam.com>
AuthorDate: Thu May 30 14:02:19 2019 +0300
[DLAB-631]: replaced progress uploading component with material
---
.../webapp/src/app/administration/management/index.ts | 2 --
.../app/administration/management/management.component.html | 2 --
.../app/administration/management/management.component.ts | 1 -
.../src/app/shared/modal-dialog/progress-dialog/index.ts | 5 +++--
.../progress-dialog/progress-dialog.component.html | 13 +++++++------
.../progress-dialog/progress-dialog.component.ts | 12 ------------
.../webapp/src/app/shared/navbar/navbar.component.html | 8 --------
.../webapp/src/app/shared/navbar/navbar.component.ts | 12 +++++++-----
8 files changed, 17 insertions(+), 38 deletions(-)
diff --git a/services/self-service/src/main/resources/webapp/src/app/administration/management/index.ts b/services/self-service/src/main/resources/webapp/src/app/administration/management/index.ts
index 3dadada..88b0e44 100644
--- a/services/self-service/src/main/resources/webapp/src/app/administration/management/index.ts
+++ b/services/self-service/src/main/resources/webapp/src/app/administration/management/index.ts
@@ -24,7 +24,6 @@ import { FormsModule, ReactiveFormsModule } from '@angular/forms';
import {
ModalModule,
UploadKeyDialogModule,
- ProgressDialogModule,
BubbleModule,
ConfirmationDialogModule
} from '../../shared';
@@ -54,7 +53,6 @@ export * from './management.component';
ProjectModule,
ModalModule,
UploadKeyDialogModule,
- ProgressDialogModule,
BubbleModule,
ConfirmationDialogModule,
ComputationalResourcesModule,
diff --git a/services/self-service/src/main/resources/webapp/src/app/administration/management/management.component.html b/services/self-service/src/main/resources/webapp/src/app/administration/management/management.component.html
index cffca62..b46549b 100644
--- a/services/self-service/src/main/resources/webapp/src/app/administration/management/management.component.html
+++ b/services/self-service/src/main/resources/webapp/src/app/administration/management/management.component.html
@@ -42,5 +42,3 @@
[environmentsHealthStatuses]="healthStatus?.list_resources" (refreshGrid)="buildGrid()"
(actionToggle)="manageEnvironmentAction($event)">
</management-grid>
-
-<progress-dialog #preloaderModal></progress-dialog>
\ No newline at end of file
diff --git a/services/self-service/src/main/resources/webapp/src/app/administration/management/management.component.ts b/services/self-service/src/main/resources/webapp/src/app/administration/management/management.component.ts
index e698281..970b41c 100644
--- a/services/self-service/src/main/resources/webapp/src/app/administration/management/management.component.ts
+++ b/services/self-service/src/main/resources/webapp/src/app/administration/management/management.component.ts
@@ -58,7 +58,6 @@ export class ManagementComponent implements OnInit, OnDestroy {
@ViewChild('backupDialog') backupDialog;
@ViewChild('manageEnvDialog') manageEnvironmentDialog;
@ViewChild('keyUploadModal') keyUploadDialog;
- @ViewChild('preloaderModal') preloaderDialog;
@ViewChild('ssnMonitor') ssnMonitorDialog;
// @ViewChild('rolesGroupsModal') rolesGroupsDialog;
diff --git a/services/self-service/src/main/resources/webapp/src/app/shared/modal-dialog/progress-dialog/index.ts b/services/self-service/src/main/resources/webapp/src/app/shared/modal-dialog/progress-dialog/index.ts
index 8001541..f66af62 100644
--- a/services/self-service/src/main/resources/webapp/src/app/shared/modal-dialog/progress-dialog/index.ts
+++ b/services/self-service/src/main/resources/webapp/src/app/shared/modal-dialog/progress-dialog/index.ts
@@ -19,14 +19,15 @@
import { NgModule } from '@angular/core';
import { CommonModule } from '@angular/common';
-import { ModalModule } from '..';
+
import { ProgressDialogComponent } from './progress-dialog.component';
export * from './progress-dialog.component';
@NgModule({
- imports: [CommonModule, ModalModule],
+ imports: [CommonModule],
declarations: [ProgressDialogComponent],
+ entryComponents: [ProgressDialogComponent],
exports: [ProgressDialogComponent],
})
diff --git a/services/self-service/src/main/resources/webapp/src/app/shared/modal-dialog/progress-dialog/progress-dialog.component.html b/services/self-service/src/main/resources/webapp/src/app/shared/modal-dialog/progress-dialog/progress-dialog.component.html
index 45cc7ae..726bcfb 100644
--- a/services/self-service/src/main/resources/webapp/src/app/shared/modal-dialog/progress-dialog/progress-dialog.component.html
+++ b/services/self-service/src/main/resources/webapp/src/app/shared/modal-dialog/progress-dialog/progress-dialog.component.html
@@ -17,13 +17,14 @@
~ under the License.
-->
-<modal-dialog #bindDialog modalClass="modal-xs progress-dialog">
- <modal-header></modal-header>
- <modal-content class="text-center">
+<div id="dialog-box" class="progress-dialog">
+ <header class="dialog-header header-white">
+ <button type="button" class="close" (click)="dialogRef.close()">×</button>
+ </header>
+ <div class="dialog-content text-center">
<div class="content-box">
<div><img src="assets/img/gif-spinner.gif" alt="loader"></div>
<p class="info-label">Initial infrastructure is being created, <br/>please, wait...</p>
</div>
- </modal-content>
- <modal-footer></modal-footer>
-</modal-dialog>
+ </div>
+</div>
diff --git a/services/self-service/src/main/resources/webapp/src/app/shared/modal-dialog/progress-dialog/progress-dialog.component.ts b/services/self-service/src/main/resources/webapp/src/app/shared/modal-dialog/progress-dialog/progress-dialog.component.ts
index 5dc200a..48f6cb5 100644
--- a/services/self-service/src/main/resources/webapp/src/app/shared/modal-dialog/progress-dialog/progress-dialog.component.ts
+++ b/services/self-service/src/main/resources/webapp/src/app/shared/modal-dialog/progress-dialog/progress-dialog.component.ts
@@ -27,20 +27,8 @@ import { Component, OnInit, ViewChild, Input } from '@angular/core';
export class ProgressDialogComponent implements OnInit {
@Input() theBoundCallback: Function;
- @ViewChild('bindDialog') bindDialog;
-
ngOnInit() {
if (this.theBoundCallback)
this.theBoundCallback();
}
-
- open(params) {
- if (!this.bindDialog.isOpened)
- this.bindDialog.open(params);
- }
-
- close() {
- if (this.bindDialog.isOpened)
- this.bindDialog.close();
- }
}
diff --git a/services/self-service/src/main/resources/webapp/src/app/shared/navbar/navbar.component.html b/services/self-service/src/main/resources/webapp/src/app/shared/navbar/navbar.component.html
index 3fd9218..4bd0eaa 100644
--- a/services/self-service/src/main/resources/webapp/src/app/shared/navbar/navbar.component.html
+++ b/services/self-service/src/main/resources/webapp/src/app/shared/navbar/navbar.component.html
@@ -26,13 +26,6 @@
<span class="line"></span>
</button>
- <nav role="navigation">
- <!-- <mat-menu #menu="matMenu" [overlapTrigger]="false">
- <a class="nav-item" mat-menu-item [routerLink]="['/resources_list']" [routerLinkActive]="['active']" [routerLinkActiveOptions]="{exact:true}">List of Resources</a>
- <a class="nav-item" mat-menu-item [routerLink]="['/administration']" [routerLinkActive]="['active']" [routerLinkActiveOptions]="{exact:true}">Environment Management</a>
- <a *ngIf="healthStatus.billingEnabled" class="nav-item" mat-menu-item [routerLink]="['/billing_report']" [routerLinkActive]="['active']" [routerLinkActiveOptions]="{exact:true}">Billing Report</a>
- </mat-menu> -->
- </nav>
<a [routerLink]="['/resources_list']" class="navbar-logo">
<img src="assets/img/logo-nav.png" alt="">
</a>
@@ -127,4 +120,3 @@
<key-upload-dialog #keyUploadModal (generateUserKey)="generateUserKey($event)"
(checkInfrastructureCreationProgress)="checkCreationProgress($event)" [primaryUploading]="true"></key-upload-dialog>
-<progress-dialog #preloaderModal></progress-dialog>
\ No newline at end of file
diff --git a/services/self-service/src/main/resources/webapp/src/app/shared/navbar/navbar.component.ts b/services/self-service/src/main/resources/webapp/src/app/shared/navbar/navbar.component.ts
index 8efc7a7..7bf49a0 100644
--- a/services/self-service/src/main/resources/webapp/src/app/shared/navbar/navbar.component.ts
+++ b/services/self-service/src/main/resources/webapp/src/app/shared/navbar/navbar.component.ts
@@ -33,6 +33,7 @@ import { GeneralEnvironmentStatus } from '../../administration/management/manage
import { DICTIONARY } from '../../../dictionary/global.dictionary';
import { HTTP_STATUS_CODES, FileUtils } from '../../core/util';
import { NotificationDialogComponent } from '../modal-dialog/notification-dialog';
+import { ProgressDialogComponent } from '../modal-dialog/progress-dialog';
@Component({
selector: 'dlab-navbar',
@@ -59,7 +60,6 @@ export class NavbarComponent implements OnInit, OnDestroy {
subscriptions: Subscription = new Subscription();
@ViewChild('keyUploadModal') keyUploadDialog;
- @ViewChild('preloaderModal') preloaderDialog;
constructor(
public toastr: ToastrService,
@@ -159,13 +159,15 @@ export class NavbarComponent implements OnInit, OnDestroy {
}
private processAccessKeyStatus(status: number): void {
+ debugger;
if (status === HTTP_STATUS_CODES.NOT_FOUND || status === HTTP_STATUS_CODES.INTERNAL_SERVER_ERROR) {
- this.preloaderDialog.bindDialog.isOpened && this.preloaderDialog.close();
+ !this.dialog.openDialogs.length && this.dialog.closeAll();
+
this.keyUploadDialog.open({ isFooter: false });
this.alive = false;
this.lastStatus = status;
} else if (status === HTTP_STATUS_CODES.ACCEPTED) {
- !this.preloaderDialog.bindDialog.isOpened && this.preloaderDialog.open({ isHeader: false, isFooter: false });
+ !this.dialog.openDialogs.length && this.dialog.open(ProgressDialogComponent, {panelClass: 'modal-xs'});
if (!this.alive) {
this.alive = true;
@@ -181,7 +183,7 @@ export class NavbarComponent implements OnInit, OnDestroy {
this.lastStatus = false;
}
this.alive = false;
- this.preloaderDialog.close();
+ this.dialog.closeAll();
this.keyUploadDialog.close();
}
}
@@ -191,7 +193,7 @@ export class NavbarComponent implements OnInit, OnDestroy {
if (list.length) {
if (this.dialog.openDialogs.length > 0) return;
const filteredData = this.groupSchedulerData(list);
- const dialogRef: MatDialogRef<NotificationDialogComponent> = this.dialog.open(NotificationDialogComponent, {
+ this.dialog.open(NotificationDialogComponent, {
data: { template: filteredData, type: 'list' },
width: '550px'
});
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@dlab.apache.org
For additional commands, e-mail: commits-help@dlab.apache.org
[incubator-dlab] 03/03: [DLAB-631]: replaced confirmation dialog
component
Posted by an...@apache.org.
This is an automated email from the ASF dual-hosted git repository.
ankovalyshyn pushed a commit to branch feature/projects
in repository https://gitbox.apache.org/repos/asf/incubator-dlab.git
commit 17a9e7d52bc823a00d70ef465cacb9dac66b415b
Author: Andriana Kovalyshyn <An...@epam.com>
AuthorDate: Thu May 30 15:58:16 2019 +0300
[DLAB-631]: replaced confirmation dialog component
---
.../src/app/administration/management/index.ts | 6 ++--
.../management-grid/management-grid.component.html | 1 -
.../management-grid/management-grid.component.ts | 25 ++++++-------
.../detail-dialog/detail-dialog.component.ts | 1 -
.../resources-grid/resources-grid.component.html | 9 -----
.../resources-grid/resources-grid.component.ts | 21 ++++-------
.../confirmation-dialog.component.html | 26 +++++++-------
.../confirmation-dialog.component.ts | 42 ++++++++--------------
.../modal-dialog/confirmation-dialog/index.ts | 1 +
.../progress-dialog/progress-dialog.component.ts | 8 ++++-
10 files changed, 59 insertions(+), 81 deletions(-)
diff --git a/services/self-service/src/main/resources/webapp/src/app/administration/management/index.ts b/services/self-service/src/main/resources/webapp/src/app/administration/management/index.ts
index 88b0e44..329f1c2 100644
--- a/services/self-service/src/main/resources/webapp/src/app/administration/management/index.ts
+++ b/services/self-service/src/main/resources/webapp/src/app/administration/management/index.ts
@@ -30,7 +30,7 @@ import {
import { MaterialModule } from '../../shared/material.module';
import { ManagementComponent } from './management.component';
-import { ManagementGridComponent, ConfirmationDialogComponent } from './management-grid/management-grid.component';
+import { ManagementGridComponent, ReconfirmationDialogComponent } from './management-grid/management-grid.component';
import { ComputationalResourcesModule } from '../../resources/computational/computational-resources-list';
import { FormControlsModule } from '../../shared/form-controls';
@@ -65,13 +65,13 @@ export * from './management.component';
ManagementGridComponent,
BackupDilogComponent,
ManageEnvironmentComponent,
- ConfirmationDialogComponent,
+ ReconfirmationDialogComponent,
ConfirmActionDialogComponent,
SsnMonitorComponent,
EndpointsComponent
],
entryComponents: [
- ConfirmationDialogComponent,
+ ReconfirmationDialogComponent,
ConfirmActionDialogComponent,
BackupDilogComponent,
SsnMonitorComponent,
diff --git a/services/self-service/src/main/resources/webapp/src/app/administration/management/management-grid/management-grid.component.html b/services/self-service/src/main/resources/webapp/src/app/administration/management/management-grid/management-grid.component.html
index 6b8bb95..8694e96 100644
--- a/services/self-service/src/main/resources/webapp/src/app/administration/management/management-grid/management-grid.component.html
+++ b/services/self-service/src/main/resources/webapp/src/app/administration/management/management-grid/management-grid.component.html
@@ -155,7 +155,6 @@
</table>
</ng-template>
-<confirmation-dialog #confirmationDialog [manageAction]="isAdmin" (buildGrid)="buildGrid()"></confirmation-dialog>
<key-upload-dialog #keyReuploadDialog [primaryUploading]="false" (checkInfrastructureCreationProgress)="buildGrid()"
(generateUserKey)="generateUserKey()">
</key-upload-dialog>
\ No newline at end of file
diff --git a/services/self-service/src/main/resources/webapp/src/app/administration/management/management-grid/management-grid.component.ts b/services/self-service/src/main/resources/webapp/src/app/administration/management/management-grid/management-grid.component.ts
index 7cc28e8..0c630df 100644
--- a/services/self-service/src/main/resources/webapp/src/app/administration/management/management-grid/management-grid.component.ts
+++ b/services/self-service/src/main/resources/webapp/src/app/administration/management/management-grid/management-grid.component.ts
@@ -24,6 +24,7 @@ import { ToastrService } from 'ngx-toastr';
import { HealthStatusService, UserAccessKeyService } from '../../../core/services';
import { ConfirmationDialogType } from '../../../shared';
import { FileUtils } from '../../../core/util';
+import { ConfirmationDialogComponent } from '../../../shared/modal-dialog/confirmation-dialog/confirmation-dialog.component';
export interface ManageAction {
action: string;
@@ -51,7 +52,6 @@ export class ManagementGridComponent implements OnInit {
@Output() refreshGrid: EventEmitter<{}> = new EventEmitter();
@Output() actionToggle: EventEmitter<ManageAction> = new EventEmitter();
- @ViewChild('confirmationDialog') confirmationDialog;
@ViewChild('keyReuploadDialog') keyReuploadDialog;
constructor(
@@ -71,7 +71,7 @@ export class ManagementGridComponent implements OnInit {
toggleResourceAction(environment, action: string, resource?) {
if (resource) {
const resource_name = resource ? resource.computational_name : environment.name;
- const dialogRef: MatDialogRef<ConfirmationDialogComponent> = this.dialog.open(ConfirmationDialogComponent, {
+ const dialogRef: MatDialogRef<ReconfirmationDialogComponent> = this.dialog.open(ReconfirmationDialogComponent, {
data: { action, resource_name, user: environment.user },
width: '550px',
panelClass: 'error-modalbox'
@@ -80,16 +80,17 @@ export class ManagementGridComponent implements OnInit {
result && this.actionToggle.emit({ action, environment, resource });
});
} else {
+ const type = (environment.name === 'edge node' || environment.type.toLowerCase() === 'edge node')
+ ? ConfirmationDialogType.StopEdgeNode : ConfirmationDialogType.StopExploratory;
+
if (action === 'stop') {
- this.confirmationDialog.open(
- { isFooter: false },
- environment,
- (environment.name === 'edge node' || environment.type.toLowerCase() === 'edge node')
- ? ConfirmationDialogType.StopEdgeNode
- : ConfirmationDialogType.StopExploratory,
- );
+ this.dialog.open(ConfirmationDialogComponent, {
+ data: { notebook: environment, type: type, manageAction: this.isAdmin }, panelClass: 'modal-md'
+ });
} else if (action === 'terminate') {
- this.confirmationDialog.open({ isFooter: false }, environment, ConfirmationDialogType.TerminateExploratory);
+ this.dialog.open(ConfirmationDialogComponent, {
+ data: { notebook: environment, type: ConfirmationDialogType.TerminateExploratory, manageAction: this.isAdmin }
+ });
} else if (action === 'run') {
this.healthStatusService
.runEdgeNode()
@@ -164,9 +165,9 @@ export class ManagementGridComponent implements OnInit {
styles: [
]
})
-export class ConfirmationDialogComponent {
+export class ReconfirmationDialogComponent {
constructor(
- public dialogRef: MatDialogRef<ConfirmationDialogComponent>,
+ public dialogRef: MatDialogRef<ReconfirmationDialogComponent>,
@Inject(MAT_DIALOG_DATA) public data: any
) {}
}
diff --git a/services/self-service/src/main/resources/webapp/src/app/resources/exploratory/detail-dialog/detail-dialog.component.ts b/services/self-service/src/main/resources/webapp/src/app/resources/exploratory/detail-dialog/detail-dialog.component.ts
index 8f75eea..81bffe3 100644
--- a/services/self-service/src/main/resources/webapp/src/app/resources/exploratory/detail-dialog/detail-dialog.component.ts
+++ b/services/self-service/src/main/resources/webapp/src/app/resources/exploratory/detail-dialog/detail-dialog.component.ts
@@ -56,7 +56,6 @@ export class DetailDialogComponent implements OnInit {
}
ngOnInit() {
- // this.dialogRef.beforeClosed().subscribe(() => this.resetDialog());
this.notebook;
if (this.notebook) {
diff --git a/services/self-service/src/main/resources/webapp/src/app/resources/resources-grid/resources-grid.component.html b/services/self-service/src/main/resources/webapp/src/app/resources/resources-grid/resources-grid.component.html
index 4126a52..2c4e497 100644
--- a/services/self-service/src/main/resources/webapp/src/app/resources/resources-grid/resources-grid.component.html
+++ b/services/self-service/src/main/resources/webapp/src/app/resources/resources-grid/resources-grid.component.html
@@ -152,12 +152,3 @@
</td>
</tr>
</table>
-
-<!-- <detail-dialog #detailDialog (buildGrid)="buildGrid()"></detail-dialog> -->
-
-<!-- <computational-resource-create-dialog #computationalResourceModal (buildGrid)="buildGrid()"></computational-resource-create-dialog> -->
-<confirmation-dialog #confirmationDialog (buildGrid)="buildGrid()"></confirmation-dialog>
-<!-- <cost-details-dialog #costDetailsDialog></cost-details-dialog> -->
-<!-- <install-libraries #installLibs (buildGrid)="buildGrid()"></install-libraries> -->
-<!-- <dlab-scheduler #envScheduler (buildGrid)="buildGrid()"></dlab-scheduler> -->
-<!-- <dlab-ami-create-dialog #createAmi (buildGrid)="buildGrid()"></dlab-ami-create-dialog> -->
diff --git a/services/self-service/src/main/resources/webapp/src/app/resources/resources-grid/resources-grid.component.ts b/services/self-service/src/main/resources/webapp/src/app/resources/resources-grid/resources-grid.component.ts
index aa76c91..6bf5402 100644
--- a/services/self-service/src/main/resources/webapp/src/app/resources/resources-grid/resources-grid.component.ts
+++ b/services/self-service/src/main/resources/webapp/src/app/resources/resources-grid/resources-grid.component.ts
@@ -18,7 +18,7 @@
*/
/* tslint:disable:no-empty */
-import { Component, ViewChild, OnInit } from '@angular/core';
+import { Component, OnInit } from '@angular/core';
import { ToastrService } from 'ngx-toastr';
import { MatDialog } from '@angular/material';
@@ -34,6 +34,7 @@ import { AmiCreateDialogComponent } from '../exploratory/ami-create-dialog';
import { InstallLibrariesComponent } from '../exploratory/install-libraries';
import { ComputationalResourceCreateDialogComponent } from '../computational/computational-resource-create-dialog/computational-resource-create-dialog.component';
import { CostDetailsDialogComponent } from '../exploratory/cost-details-dialog';
+import { ConfirmationDialogComponent } from '../../shared/modal-dialog/confirmation-dialog';
import { SchedulerComponent } from '../scheduler';
import { DICTIONARY } from '../../../dictionary/global.dictionary';
@@ -52,7 +53,6 @@ export class ResourcesGridComponent implements OnInit {
filterConfiguration: FilterConfigurationModel;
filterForm: FilterConfigurationModel = new FilterConfigurationModel('', [], [], [], '');
model = new CreateResourceModel('', '');
- notebookName: string;
isOutscreenDropdown: boolean;
collapseFilterRow: boolean = false;
filtering: boolean = false;
@@ -60,12 +60,6 @@ export class ResourcesGridComponent implements OnInit {
healthStatus: GeneralEnvironmentStatus;
delimitersRegex = /[-_]?/g;
- // @ViewChild('computationalResourceModal') computationalResourceModal;
- @ViewChild('confirmationDialog') confirmationDialog;
- @ViewChild('detailDialog') detailDialog;
- @ViewChild('costDetailsDialog') costDetailsDialog;
- // @ViewChild('envScheduler') scheduler;
-
public filteringColumns: Array<any> = [
{ title: 'Environment name', name: 'name', className: 'th_name', filtering: {} },
{ title: 'Status', name: 'statuses', className: 'th_status', filtering: {} },
@@ -281,7 +275,6 @@ export class ResourcesGridComponent implements OnInit {
}
printDetailEnvironmentModal(data): void {
- // this.detailDialog.open({ isFooter: false }, data);
this.dialog.open(DetailDialogComponent, { data: data, panelClass: 'modal-lg' })
.afterClosed().subscribe(() => this.buildGrid());
}
@@ -293,9 +286,6 @@ export class ResourcesGridComponent implements OnInit {
exploratoryAction(data, action: string) {
if (action === 'deploy') {
- this.notebookName = data.name;
- // this.computationalResourceModal.open({ isFooter: false }, data, this.environments);
-
this.dialog.open(ComputationalResourceCreateDialogComponent, { data: { notebook: data, full_list: this.environments}, panelClass: 'modal-xxl'})
.afterClosed().subscribe(() => this.buildGrid());
} else if (action === 'run') {
@@ -305,14 +295,15 @@ export class ResourcesGridComponent implements OnInit {
() => this.buildGrid(),
error => this.toastr.error(error.message || 'Exploratory starting failed!', 'Oops!'));
} else if (action === 'stop') {
- this.confirmationDialog.open({ isFooter: false }, data, ConfirmationDialogType.StopExploratory);
+ this.dialog.open(ConfirmationDialogComponent, { data: { notebook: data, type: ConfirmationDialogType.StopExploratory }, panelClass: 'modal-sm'})
+ .afterClosed().subscribe(() => this.buildGrid());
} else if (action === 'terminate') {
- this.confirmationDialog.open({ isFooter: false }, data, ConfirmationDialogType.TerminateExploratory);
+ this.dialog.open(ConfirmationDialogComponent, {data: { notebook: data, type: ConfirmationDialogType.TerminateExploratory }, panelClass: 'modal-sm'})
+ .afterClosed().subscribe(() => this.buildGrid());
} else if (action === 'install') {
this.dialog.open(InstallLibrariesComponent, { data: data, panelClass: 'modal-fullscreen' })
.afterClosed().subscribe(() => this.buildGrid());
} else if (action === 'schedule') {
- // this.scheduler.open({ isFooter: false }, data, 'EXPLORATORY');
this.dialog.open(SchedulerComponent, { data: {notebook: data, type: 'EXPLORATORY'}, panelClass: 'modal-xl-s' })
.afterClosed().subscribe(() => this.buildGrid());
} else if (action === 'ami') {
diff --git a/services/self-service/src/main/resources/webapp/src/app/shared/modal-dialog/confirmation-dialog/confirmation-dialog.component.html b/services/self-service/src/main/resources/webapp/src/app/shared/modal-dialog/confirmation-dialog/confirmation-dialog.component.html
index d9ba880..a19d773 100644
--- a/services/self-service/src/main/resources/webapp/src/app/shared/modal-dialog/confirmation-dialog/confirmation-dialog.component.html
+++ b/services/self-service/src/main/resources/webapp/src/app/shared/modal-dialog/confirmation-dialog/confirmation-dialog.component.html
@@ -17,8 +17,8 @@
~ under the License.
-->
-<modal-dialog #bindDialog modalClass="confirmation-dialog modal-md">
- <modal-header>
+<div id="dialog-box" class="confirmation-dialog">
+ <header class="dialog-header">
<h4 class="modal-title">
<span *ngIf="model.notebook.name && model.notebook.name !== 'edge node'">
<span>{{ confirmationType ? 'Terminate' : 'Stop' }} notebook: {{ model.notebook.name }}</span>
@@ -27,12 +27,14 @@
<i class="material-icons">priority_high</i>Warning
</span>
</h4>
- </modal-header>
- <modal-content>
+ <button type="button" class="close" (click)="dialogRef.close()">×</button>
+ </header>
+ <div class="dialog-content">
<div class="content-box">
<p class="info text-center">{{ model.title }}</p>
- <mat-list class="resources" [hidden]="model.notebook.type === 'Edge Node' || model.notebook.name === 'edge node'
+ <mat-list class="resources"
+ [hidden]="model.notebook.type === 'Edge Node' || model.notebook.name === 'edge node'
|| !model.notebook.resources || model.notebook.resources.length === 0 || (!isAliveResources && !confirmationType) || onlyKilled">
<mat-list-item class="list-header">
<div class="cluster">Cluster</div>
@@ -41,23 +43,23 @@
</mat-list-item>
<div class="scrolling-content" id="scrolling">
<mat-list-item *ngFor="let resource of model.notebook.resources"
- [hidden]="resource.status === 'failed' || resource.status === 'terminated' || resource.status === 'terminating' || (resource.status === 'stopped' && !confirmationType)">
+ [hidden]="resource.status === 'failed' || resource.status === 'terminated' || resource.status === 'terminating' || (resource.status === 'stopped' && !confirmationType)">
<div class="cluster ellipsis">{{ resource.computational_name }}</div>
<div class="status" [ngClass]="{ 'stopped': !confirmationType && resource.image === 'docker.dlab-dataengine',
- 'terminated': resource.image === 'docker.dlab-dataengine-service' || confirmationType }">{{ (!confirmationType && resource.image === 'docker.dlab-dataengine') ? 'Stopped' : 'Terminated' }}</div>
+ 'terminated': resource.image === 'docker.dlab-dataengine-service' || confirmationType }">
+ {{ (!confirmationType && resource.image === 'docker.dlab-dataengine') ? 'Stopped' : 'Terminated' }}</div>
<div class="size">{{ resource[DICTIONARY[resource.image].master_node_shape] }}</div>
</mat-list-item>
</div>
</mat-list>
<div class="text-center m-top-20">
- <p *ngIf="model.notebook.name">Do you want to proceed?</p>
- <p *ngIf="model.notebook.type">Are you sure you want to continue?</p>
+ <p>Do you want to proceed?</p>
</div>
<div class="text-center m-top-20">
- <button mat-raised-button type="button" class="butt action" (click)="bindDialog.close()">No</button>
+ <button mat-raised-button type="button" class="butt action" (click)="dialogRef.close()">No</button>
<button mat-raised-button type="button" class="butt butt-success action" (click)="confirm()">Yes</button>
</div>
</div>
- </modal-content>
-</modal-dialog>
+ </div>
+</div>
\ No newline at end of file
diff --git a/services/self-service/src/main/resources/webapp/src/app/shared/modal-dialog/confirmation-dialog/confirmation-dialog.component.ts b/services/self-service/src/main/resources/webapp/src/app/shared/modal-dialog/confirmation-dialog/confirmation-dialog.component.ts
index c1fe712..fda9525 100644
--- a/services/self-service/src/main/resources/webapp/src/app/shared/modal-dialog/confirmation-dialog/confirmation-dialog.component.ts
+++ b/services/self-service/src/main/resources/webapp/src/app/shared/modal-dialog/confirmation-dialog/confirmation-dialog.component.ts
@@ -17,8 +17,9 @@
* under the License.
*/
-import { Component, OnInit, ViewChild, Input, Output, EventEmitter, ViewEncapsulation } from '@angular/core';
+import { Component, OnInit, Inject, Input, Output, EventEmitter, ViewEncapsulation } from '@angular/core';
import { ToastrService } from 'ngx-toastr';
+import { MatDialogRef, MAT_DIALOG_DATA } from '@angular/material';
import { ConfirmationDialogModel } from './confirmation-dialog.model';
import { ConfirmationDialogType } from './confirmation-dialog-type.enum';
@@ -35,19 +36,22 @@ import { DICTIONARY } from '../../../../dictionary/global.dictionary';
export class ConfirmationDialogComponent implements OnInit {
readonly DICTIONARY = DICTIONARY;
+
model: ConfirmationDialogModel;
isAliveResources: boolean;
onlyKilled: boolean = false;
+ notebook: any;
dataengines: Array<any> = [];
dataengineServices: Array<any> = [];
confirmationType: number = 0;
- @ViewChild('bindDialog') bindDialog;
@Input() manageAction: boolean = false;
@Output() buildGrid: EventEmitter<{}> = new EventEmitter();
constructor(
+ @Inject(MAT_DIALOG_DATA) public data: any,
+ public dialogRef: MatDialogRef<ConfirmationDialogComponent>,
private userResourceService: UserResourceService,
private healthStatusService: HealthStatusService,
private manageEnvironmentsService: ManageEnvironmentsService,
@@ -57,38 +61,27 @@ export class ConfirmationDialogComponent implements OnInit {
}
ngOnInit() {
- this.bindDialog.onClosing = () => this.resetDialog();
- }
-
- public open(param, notebook: any, type: ConfirmationDialogType) {
- this.confirmationType = type;
-
- this.model = new ConfirmationDialogModel(type, notebook,
+ this.confirmationType = this.data.type;
+ this.notebook = this.data.notebook;
+ this.model = new ConfirmationDialogModel(this.confirmationType, this.notebook,
response => {
- if (response.status === HTTP_STATUS_CODES.OK) {
- this.close();
- this.buildGrid.emit();
- }
+ if (response.status === HTTP_STATUS_CODES.OK) this.dialogRef.close();
},
error => this.toastr.error(error.message || 'Action failed!', 'Oops'),
- this.manageAction,
+ this.data.manageAction,
this.userResourceService,
this.healthStatusService,
this.manageEnvironmentsService);
- this.bindDialog.open(param);
- if (!this.confirmationType) this.filterResourcesByType(notebook.resources);
- this.isAliveResources = this.model.isAliveResources(notebook.resources);
- this.onlyKilled = notebook.resources ? !notebook.resources.some(el => el.status !== 'terminated') : false;
+ if (!this.confirmationType) this.filterResourcesByType(this.notebook.resources);
+ this.isAliveResources = this.model.isAliveResources(this.notebook.resources);
+ this.onlyKilled = this.notebook.resources ? !this.notebook.resources.some(el => el.status !== 'terminated') : false;
}
+
public confirm() {
this.model.confirmAction();
}
- public close() {
- this.bindDialog.close();
- }
-
private filterResourcesByType(resources) {
resources
.filter(resource =>
@@ -97,9 +90,4 @@ export class ConfirmationDialogComponent implements OnInit {
.forEach(resource => {
(resource.image === 'docker.dlab-dataengine') ? this.dataengines.push(resource) : this.dataengineServices.push(resource); });
}
-
- private resetDialog(): void {
- this.dataengines = [];
- this.dataengineServices = [];
- }
}
diff --git a/services/self-service/src/main/resources/webapp/src/app/shared/modal-dialog/confirmation-dialog/index.ts b/services/self-service/src/main/resources/webapp/src/app/shared/modal-dialog/confirmation-dialog/index.ts
index 2790f28..331a072 100644
--- a/services/self-service/src/main/resources/webapp/src/app/shared/modal-dialog/confirmation-dialog/index.ts
+++ b/services/self-service/src/main/resources/webapp/src/app/shared/modal-dialog/confirmation-dialog/index.ts
@@ -30,6 +30,7 @@ export * from './confirmation-dialog-type.enum';
@NgModule({
imports: [CommonModule, ModalModule, MaterialModule],
declarations: [ConfirmationDialogComponent],
+ entryComponents: [ConfirmationDialogComponent],
exports: [ConfirmationDialogComponent]
})
export class ConfirmationDialogModule {}
diff --git a/services/self-service/src/main/resources/webapp/src/app/shared/modal-dialog/progress-dialog/progress-dialog.component.ts b/services/self-service/src/main/resources/webapp/src/app/shared/modal-dialog/progress-dialog/progress-dialog.component.ts
index 48f6cb5..9e2c7ad 100644
--- a/services/self-service/src/main/resources/webapp/src/app/shared/modal-dialog/progress-dialog/progress-dialog.component.ts
+++ b/services/self-service/src/main/resources/webapp/src/app/shared/modal-dialog/progress-dialog/progress-dialog.component.ts
@@ -17,7 +17,8 @@
* under the License.
*/
-import { Component, OnInit, ViewChild, Input } from '@angular/core';
+import { Component, OnInit, Input, Inject } from '@angular/core';
+import { MatDialogRef, MAT_DIALOG_DATA } from '@angular/material';
@Component({
selector: 'progress-dialog',
@@ -27,6 +28,11 @@ import { Component, OnInit, ViewChild, Input } from '@angular/core';
export class ProgressDialogComponent implements OnInit {
@Input() theBoundCallback: Function;
+ constructor(
+ @Inject(MAT_DIALOG_DATA) public data: any,
+ public dialogRef: MatDialogRef<ProgressDialogComponent>,
+ ) { }
+
ngOnInit() {
if (this.theBoundCallback)
this.theBoundCallback();
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@dlab.apache.org
For additional commands, e-mail: commits-help@dlab.apache.org