Ittay Stern | 6f900cc | 2018-08-29 17:01:32 +0300 | [diff] [blame] | 1 | <div class="drawing-board-header"> |
| 2 | <div class="left-header"> |
| 3 | <span class="vid-logo-small"></span> |
| 4 | <span class="icon-back"> |
| 5 | <svg-icon |
| 6 | (click)="closePage()" |
| 7 | [testId]="'backBtn'" |
| 8 | [size]="'large'" |
| 9 | [name]="'navigation-arrow-back'"> |
| 10 | </svg-icon> |
| 11 | </span> |
| 12 | |
Ittay Stern | f792671 | 2019-07-07 19:23:03 +0300 | [diff] [blame^] | 13 | <div class="header-col middleDetails" style="padding-top: 7px;padding-left: 13px;line-height: 100%;" *ngIf="isServiceFailed"> |
Ittay Stern | 6f900cc | 2018-08-29 17:01:32 +0300 | [diff] [blame] | 14 | <custom-popover class="failed-popover-wrap" [value]= "serviceStatusMessage" [placement]="'bottom'" [popoverType]="'error'"> |
| 15 | <span [attr.data-tests-id]="'service-failed-msg'" class="failed-msg labelPosition" >Failed</span> |
| 16 | </custom-popover> |
| 17 | </div> |
| 18 | <div class="header-col middleDetails" style="padding-top: 0px;padding-left: 13px;line-height: 100%;padding-right: 50px;"> |
| 19 | <span [attr.data-tests-id]="'serviceInstance'" class="service-instance-label labelPosition">Service instance:</span> |
| 20 | <span [attr.data-tests-id]="'serviceName'" [ngClass]="{'deleted' : isDeleted}" class="service-instance-name">{{serviceName}}</span> |
| 21 | </div> |
| 22 | <div class="header-col middleDetails notShowOnCreateMode" |
| 23 | style="padding-top: 0px;padding-left: 13px;line-height: 100%;"> |
| 24 | <span [attr.data-tests-id]="'orchStatusLabel'" class="service-instance-label labelPosition">Orch Status:</span> |
Ittay Stern | f792671 | 2019-07-07 19:23:03 +0300 | [diff] [blame^] | 25 | <span [attr.data-tests-id]="'orchStatusValue'" |
| 26 | [ngClass]="{'tag-status-value' :serviceOrchStatus?.toLowerCase()!= 'active'}" |
| 27 | class="orch-status-value">{{serviceOrchStatus}}</span> |
Ittay Stern | 6f900cc | 2018-08-29 17:01:32 +0300 | [diff] [blame] | 28 | </div> |
| 29 | <div class="quantity-container header-col middleDetails" |
| 30 | style="padding-top: 0px;padding-left: 13px;line-height: 100%;" |
| 31 | tooltip="Number of services to instantiate including all their objects as defined below"> |
| 32 | <span [attr.data-tests-id]="'quantityLabel'" class="quantity-instance-label labelPosition">Scale Times:</span> |
| 33 | <span [attr.data-tests-id]="'servicesQuantity'" class="scale-value" |
| 34 | style="font-family: OpenSans-Semibold;font-size: 13px;"> {{numServicesToDeploy}} </span> |
| 35 | </div> |
| 36 | |
| 37 | <span [attr.data-tests-id]="'serviceStatus'" class="status" tooltip="{{status}}"></span> |
| 38 | <span [attr.data-tests-id]="'isViewOnly-status-test'" class="service-instance-label purple">{{getModeName()}}</span> |
| 39 | </div> |
| 40 | |
| 41 | |
| 42 | <div class="right-header"> |
Ittay Stern | f792671 | 2019-07-07 19:23:03 +0300 | [diff] [blame^] | 43 | <span class="action-status-type-header delete" [attr.data-tests-id]="'delete-status-type-header'" *ngIf="isDeleted === true">Delete</span> |
| 44 | <span class="action-status-type-header resume" [attr.data-tests-id]="'resume-status-type-header'" *ngIf="isResume === true">Resume</span> |
Ittay Stern | 6f900cc | 2018-08-29 17:01:32 +0300 | [diff] [blame] | 45 | <span class="menu-container notShowOnViewMode notShowOnRetryMode"> |
| 46 | <span [attr.data-tests-id]="'openMenuBtn'" class="icon-browse" (click)="onContextMenu($event)"></span> |
| 47 | <context-menu> |
| 48 | <ng-template *ngIf="drawingBoardHeaderService?.showEditService(mode, serviceModelId)" contextMenuItem (execute)="editService()"> |
| 49 | <div [attr.data-tests-id]="'context-menu-header-edit-item'"> |
| 50 | <span class="icon-edit"></span>Edit</div> |
| 51 | </ng-template> |
| 52 | <ng-template *ngIf="mode === 'EDIT'" contextMenuItem |
Ittay Stern | f792671 | 2019-07-07 19:23:03 +0300 | [diff] [blame^] | 53 | (execute)="onDeleteUndoDeleteClick()"> |
Ittay Stern | 6f900cc | 2018-08-29 17:01:32 +0300 | [diff] [blame] | 54 | <div [attr.data-tests-id]="'context-menu-header-delete-item'"><span class="icon-trash"></span>{{isDeleted ? 'Undo delete': 'Delete'}}</div> |
| 55 | </ng-template> |
| 56 | <ng-template *ngIf="mode !== 'CREATE'" contextMenuItem |
| 57 | (execute)="drawingBoardHeaderService.showAuditInfo(serviceModelId)"> |
| 58 | <div [attr.data-tests-id]="'context-menu-header-audit-item'" style="float: left;margin-top: 8px;"> |
| 59 | <svg-icon |
| 60 | [ngClass]="'eye-o'" |
| 61 | class="eye-o" |
| 62 | [size]="'small'" |
| 63 | [name]="'eye-o'"> |
| 64 | </svg-icon></div> |
| 65 | <div style="padding-left: 12px;">Show Audit Info</div> |
| 66 | </ng-template> |
Ittay Stern | f792671 | 2019-07-07 19:23:03 +0300 | [diff] [blame^] | 67 | <ng-template *ngIf="drawingBoardHeaderService?.showResumeService(serviceModelId)" contextMenuItem |
| 68 | (execute)="onResumeUndoResumeClick()"> |
| 69 | <div [attr.data-tests-id]="'context-menu-header-resume-item'"><span class="icon-trash"></span>{{isResume ? 'Undo resume': 'Resume'}}</div> |
| 70 | </ng-template> |
Ittay Stern | 6f900cc | 2018-08-29 17:01:32 +0300 | [diff] [blame] | 71 | </context-menu> |
| 72 | </span> |
| 73 | <button [disabled]="drawingBoardHeaderService?.deployShouldBeDisabled(serviceModelId, mode)" |
| 74 | *ngIf="mode !== 'VIEW' && mode !== 'RETRY'; else viewEditButton" |
| 75 | [attr.data-tests-id]="'deployBtn'" |
| 76 | (click)="deployService()" |
| 77 | class="deploy-btn">{{drawingBoardHeaderService?.getModeButton(mode)}}</button> |
| 78 | <ng-template #viewEditButton> |
| 79 | <button [disabled]="!isPermitted()" |
| 80 | [attr.data-tests-id]="'editBtn'" |
| 81 | (click)="editViewEdit()" |
| 82 | class="deploy-btn">{{drawingBoardHeaderService?.getButtonText(mode)}} |
| 83 | </button> |
| 84 | </ng-template> |
| 85 | </div> |
| 86 | </div> |