se agrego el modificar

This commit is contained in:
matias mella
2021-07-15 00:40:56 -04:00
parent 61aaf3cba3
commit 069413b577
3 changed files with 66 additions and 6 deletions

View File

@@ -1,12 +1,33 @@
<table *ngIf="restaurante">
<tr>
<table class="table" *ngIf="restaurante" border="1">
<thead>
<tr >
<td>id</td><td>nombre</td><td>creacion</td><td>modificacion</td>
</tr>
<tr *ngFor="let r of restaurante.data">
</thead>
<tbody>
<tr *ngFor="let r of restaurante.data">
<td>{{r.id}}</td>
<td>{{r.nombre}}</td>
<td>{{r['created_at']}}</td>
<td>{{r['updated_at']}}</td>
</tr>
</table>
</tr>
</tbody>
</table>
<div>
<p>
nombre:<input type="text" [(ngModel)]="agre.nombre">
</p>
<p><button (click)="agregarRes()">agregar</button></p>
<p><button (click)="eliminarRes('6205091c-f172-424e-908c-f3c4bde39a9b')">elimiminar</button></p>
<p><button (click)="modificarRes('59323ad5-b0e5-45a2-8a2b-696f275ef209')">modificar</button></p>
</div>