Files
brewman/overlord/src/app/batch-integrity-report/batch-integrity-report.component.html
T

37 lines
1.3 KiB
HTML

<h2>Batch Integrity</h2>
@if (infoResource.isLoading()) {
<app-skeleton-loader type="table" [count]="1" />
} @else if (infoResource.error()) {
<app-error-state [message]="'Failed to load data.'" (retryAction)="infoResource.reload()" />
} @else {
<mat-table [dataSource]="info()">
<!-- Batch Column -->
<ng-container matColumnDef="batch">
<mat-header-cell *matHeaderCellDef>Batch</mat-header-cell>
<mat-cell *matCellDef="let row">
{{ row.product }} dated {{ row.date }} &#64; {{ row.price | currency: 'INR' }} is showing
{{ row.showing }} instead of {{ row.actual }}
</mat-cell>
</ng-container>
<!-- Details Column -->
<ng-container matColumnDef="details">
<mat-header-cell *matHeaderCellDef>Details</mat-header-cell>
<mat-cell *matCellDef="let row">
<ul>
@for (detail of row.details; track detail) {
<li>
<a [routerLink]="detail.url">{{ detail.type }}</a> on {{ detail.date }} of {{ detail.quantity }} &#64;
{{ detail.price | currency: 'INR' }}
</li>
}
</ul>
</mat-cell>
</ng-container>
<mat-header-row *matHeaderRowDef="displayedColumns"></mat-header-row>
<mat-row *matRowDef="let row; columns: displayedColumns"></mat-row>
</mat-table>
}