oggui/ogWebconsole/src/app/components/commands/commands-task/detail-task/detail-task.component.html

48 lines
1.9 KiB
HTML

<div class="detail-task-container">
<h2>{{ 'taskDetailsTitle' | translate }}</h2>
<mat-card>
<mat-card-header>
<mat-card-subtitle>{{ 'createdBy' | translate }}: {{ task.createdBy }}</mat-card-subtitle>
</mat-card-header>
<mat-card-content>
<p><strong>{{ 'taskId' | translate }}:</strong> {{ task.uuid }}</p>
<p><strong>{{ 'creationDate' | translate }}:</strong> {{ task.createdAt | date: 'short' }}</p>
<p><strong>{{ 'notes' | translate }}:</strong> {{ task.notes }}</p>
<h3>{{ 'commandsToExecute' | translate }}</h3>
<table mat-table [dataSource]="task.commandTaskScripts || []" class="mat-elevation-z8" *ngIf="task.commandTaskScripts?.length > 0">
<ng-container matColumnDef="order">
<th mat-header-cell *matHeaderCellDef>Orden</th>
<td mat-cell *matCellDef="let script">{{ script.order }}</td>
</ng-container>
<ng-container matColumnDef="type">
<th mat-header-cell *matHeaderCellDef>Tipo</th>
<td mat-cell *matCellDef="let script">{{ script.type }}</td>
</ng-container>
<ng-container matColumnDef="content">
<th mat-header-cell *matHeaderCellDef>Contenido</th>
<td mat-cell *matCellDef="let script">
<span *ngIf="script.content">{{ script.content }}</span>
<span *ngIf="!script.content && script.parameters">
(parámetros configurados)
</span>
</td>
</ng-container>
<tr mat-header-row *matHeaderRowDef="['order', 'type', 'content']"></tr>
<tr mat-row *matRowDef="let row; columns: ['order', 'type', 'content'];"></tr>
</table>
<p *ngIf="!task.commandTaskScripts?.length">No hay acciones configuradas.</p>
</mat-card-content>
</mat-card>
<div class="task-actions">
<button class="ordinary-button" (click)="closeDialog()">{{ 'buttonCancel' | translate }}</button>
</div>
</div>