This is an automated email from the ASF dual-hosted git repository.
ankovalyshyn pushed a commit to branch project_grid
in repository https://gitbox.apache.org/repos/asf/incubator-dlab.git
The following commit(s) were added to refs/heads/project_grid by this push:
new 78a6295 extended notification dialog
78a6295 is described below
commit 78a6295b5520ab8985e0e67cbddf9d79870214b6
Author: Andriana Kovalyshyn <[email protected]>
AuthorDate: Fri May 24 18:05:14 2019 +0300
extended notification dialog
---
.../notification-dialog.component.ts | 58 ++++++++++++++--------
.../webapp/src/assets/styles/_dialogs.scss | 1 +
2 files changed, 37 insertions(+), 22 deletions(-)
diff --git
a/services/self-service/src/main/resources/webapp/src/app/shared/modal-dialog/notification-dialog/notification-dialog.component.ts
b/services/self-service/src/main/resources/webapp/src/app/shared/modal-dialog/notification-dialog/notification-dialog.component.ts
index dab2f10..a83ecad 100644
---
a/services/self-service/src/main/resources/webapp/src/app/shared/modal-dialog/notification-dialog/notification-dialog.component.ts
+++
b/services/self-service/src/main/resources/webapp/src/app/shared/modal-dialog/notification-dialog/notification-dialog.component.ts
@@ -23,30 +23,41 @@ import { MatDialogRef, MAT_DIALOG_DATA } from
'@angular/material';
@Component({
selector: 'notification-dialog',
template: `
- <header>
- <h4><i class="material-icons">priority_high</i>Warning</h4>
- <a class="ani" (click)="dialogRef.close()"><i
class="material-icons">close</i></a>
- </header>
- <div mat-dialog-content class="content info message">
- <div *ngIf="data.type === 'list'; else info">
- <div *ngIf="data.template.notebook.length > 0">
- Following notebook server<span
*ngIf="data.template.notebook.length>1">s </span>
- <span *ngFor="let item of data.template.notebook">
- <b>{{ item.exploratory_name }}</b>
- <span *ngIf="data.template.notebook.length > 1">, </span>
- </span> will be stopped and all computational resources will be
stopped/terminated
- </div>
+ <div id="dialog-box">
+ <header class="dialog-header">
+ <h4 class="modal-title"><i
class="material-icons">priority_high</i>Warning</h4>
+ <button type="button" class="close"
(click)="dialogRef.close()">×</button>
+ </header>
+ <div mat-dialog-content class="content info message">
+ <div *ngIf="data.type === 'list'; else info">
+ <div *ngIf="data.template.notebook.length > 0">
+ Following notebook server<span
*ngIf="data.template.notebook.length>1">s </span>
+ <span *ngFor="let item of data.template.notebook">
+ <b>{{ item.exploratory_name }}</b>
+ <span *ngIf="data.template.notebook.length > 1">, </span>
+ </span> will be stopped and all computational resources will be
stopped/terminated
+ </div>
- <div *ngIf="data.template.cluster.length > 0">
- <p *ngFor="let item of data.template.cluster">
- Computational resource<span *ngIf="data.template.cluster.length >
1">s </span>
- <b>{{ item.computational_name }}</b> on <b>{{
item.exploratory_name }}</b>
- will be stopped
- </p>
+ <div *ngIf="data.template.cluster.length > 0">
+ <p *ngFor="let item of data.template.cluster">
+ Computational resource<span *ngIf="data.template.cluster.length
> 1">s </span>
+ <b>{{ item.computational_name }}</b> on <b>{{
item.exploratory_name }}</b>
+ will be stopped
+ </p>
+ </div>
+ <strong>by a schedule in 15 minutes.</strong>
+ </div>
+ <div *ngIf="data.type === 'message'"><span
[innerHTML]="data.template"></span></div>
+ <div *ngIf="data.type === 'confirmation'" class="confirm-dialog">
+ <p><strong>{{ data.item.name }}</strong> will be decommissioned.</p>
+ <p class="m-top-20"><strong>Do you want to proceed?</strong></p>
+
+ <div class="text-center m-top-30 m-bott-10">
+ <button type="button" class="butt" mat-raised-button
(click)="dialogRef.close()">No</button>
+ <button type="button" class="butt butt-success" mat-raised-button
(click)="dialogRef.close(true)">Yes</button>
+ </div>
</div>
- <strong>by a schedule in 15 minutes.</strong>
</div>
- <ng-template #info><span [innerHTML]="data.template"></span></ng-template>
</div>
`,
styles: [`
@@ -63,5 +74,8 @@ export class NotificationDialogComponent {
constructor(
public dialogRef: MatDialogRef<NotificationDialogComponent>,
@Inject(MAT_DIALOG_DATA) public data: any
- ) { }
+ ) {
+ console.log(data);
+
+ }
}
diff --git
a/services/self-service/src/main/resources/webapp/src/assets/styles/_dialogs.scss
b/services/self-service/src/main/resources/webapp/src/assets/styles/_dialogs.scss
index 9681eb6..6ed2eb0 100644
---
a/services/self-service/src/main/resources/webapp/src/assets/styles/_dialogs.scss
+++
b/services/self-service/src/main/resources/webapp/src/assets/styles/_dialogs.scss
@@ -29,6 +29,7 @@
.modal-fullscreen { width: 100vw; height: 100vh;}
mat-dialog-container {
+ overflow-x: hidden;
&.mat-dialog-container {
padding: 0;
border-radius: 0;
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]