added svcapi ui and camunda code
[it/otf.git] / otf-frontend / client / src / app / layout / test-definition-expanded-details / test-definition-expanded-details.component.pug
diff --git a/otf-frontend/client/src/app/layout/test-definition-expanded-details/test-definition-expanded-details.component.pug b/otf-frontend/client/src/app/layout/test-definition-expanded-details/test-definition-expanded-details.component.pug
new file mode 100644 (file)
index 0000000..6b0cc0c
--- /dev/null
@@ -0,0 +1,63 @@
+//-  Copyright (c) 2019 AT&T Intellectual Property.                             #\r
+//-                                                                             #\r
+//-  Licensed under the Apache License, Version 2.0 (the "License");            #\r
+//-  you may not use this file except in compliance with the License.           #\r
+//-  You may obtain a copy of the License at                                    #\r
+//-                                                                             #\r
+//-      http://www.apache.org/licenses/LICENSE-2.0                             #\r
+//-                                                                             #\r
+//-  Unless required by applicable law or agreed to in writing, software        #\r
+//-  distributed under the License is distributed on an "AS IS" BASIS,          #\r
+//-  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.   #\r
+//-  See the License for the specific language governing permissions and        #\r
+//-  limitations under the License.                                             #\r
+//- #############################################################################\r
+\r
+\r
+.row.mt-2\r
+  .col-sm-4(*ngIf="data")\r
+    h3 {{ data.testName }}\r
+    p {{ data.testDescription }}\r
+    p.text-muted Updated At {{ data.updatedAt }}\r
+    p.text-muted Created At {{ data.createdAt }}\r
+  .col-sm-8\r
+    mat-card.mb-4\r
+      div(mat-card-image, style="padding: 5% 2px; margin:0px; width:100%; position: relative; cursor: pointer", #canvas, (click)="enlargeBpmn()", [attr.id]="'canvas' + testDefinitionId")\r
+        button(mat-icon-button, color="primary", style="position: absolute; top: 0px; right: 0px; z-index: 100")\r
+          mat-icon zoom_in\r
+\r
+.row(*ngIf="testInstanceList")\r
+  .col-12\r
+    table.mat-elevation-z4(mat-table, [dataSource]="testInstanceList", style="width: 100%")\r
+\r
+      ng-container(matColumnDef="name")\r
+        th(mat-header-cell, *matHeaderCellDef) Instances\r
+        td(mat-cell, *matCellDef="let element")\r
+          a([routerLink]="['/test-instances', {filter: element._id}]") {{ element.testInstanceName}}\r
+\r
+      ng-container(matColumnDef="{{status}}", *ngFor="let status of statusList")\r
+        th(mat-header-cell, *matHeaderCellDef) # {{status.toLowerCase()}}\r
+        td(mat-cell, *matCellDef="let element") \r
+          .dropdown(ngbDropdown, placement="top-right", *ngIf="element[status]")\r
+            a(ngbDropdownToggle) {{ element[status]}}\r
+            .dropdown-menu(ngbDropdownMenu, style="max-height: 200px; overflow-y: scroll")\r
+              div(*ngFor="let execution of testExecutionList | filterBy: {testResult: status}")\r
+                a.dropdown-item([routerLink]="['/control-panel']", [queryParams]="{id: execution._id}", *ngIf="execution.historicTestInstance._id == element._id" )\r
+                  i.fa.fa-fw.fa-bar-chart(style="color: orange")\r
+                  span.pl-1 {{execution.startTime}}\r
+      \r
+      ng-container(matColumnDef="options", stickyEnd)\r
+        th.optionsColumn(mat-header-cell, *matHeaderCellDef)\r
+        td.optionsColumn(mat-cell, *matCellDef="let element") \r
+          .dropdown.options(ngbDropdown, placement="left", style="margin-right: -20px")\r
+            button(mat-icon-button, ngbDropdownToggle) \r
+              mat-icon more_vert\r
+            .dropdown-menu(ngbDropdownMenu)\r
+              a.dropdown-item((click)='executeTestInstance(element)')\r
+                i.fa.fa-fw.fa-refresh(style="color: green")\r
+                span.pl-1 Execute\r
+\r
+      tr(mat-header-row, *matHeaderRowDef="displayedColumns")\r
+      tr(mat-row, *matRowDef="let row; columns: displayedColumns")\r
+\r
+    mat-paginator([pageSizeOptions]="[5, 10]")
\ No newline at end of file