add recipes table

This commit is contained in:
bastien ollier
2024-06-14 15:19:25 +02:00
parent 632e9b69e5
commit eb82a16ac1
9 changed files with 969 additions and 9 deletions

View File

@@ -1 +1,40 @@
<p>recipes works!</p>
<div class="mat-elevation-z8">
<table mat-table [dataSource]="dataSource">
<!-- Position Column -->
<ng-container matColumnDef="id">
<th mat-header-cell *matHeaderCellDef> id </th>
<td mat-cell *matCellDef="let element">
<a [routerLink]="['/recipe/', element.id]" >
{{element.id}}
</a>
</ng-container>
<ng-container matColumnDef="name">
<th mat-header-cell *matHeaderCellDef> name </th>
<td mat-cell *matCellDef="let element">
<a [routerLink]="['/recipe/', element.id]" >
{{element.name}}
</a>
</td>
</ng-container>
<ng-container matColumnDef="description">
<th mat-header-cell *matHeaderCellDef> description </th>
<td mat-cell *matCellDef="let element">
<a [routerLink]="['/recipe/', element.id]" >
{{element.description}}
</a>
</td>
</ng-container>
<tr mat-header-row *matHeaderRowDef="displayedColumns"></tr>
<tr mat-row *matRowDef="let row; columns: displayedColumns;"></tr>
</table>
<mat-paginator [pageSizeOptions]="[5, 10, 20]"
showFirstLastButtons
aria-label="Select page of periodic elements">
</mat-paginator>
</div>