Created
June 24, 2020 07:47
-
-
Save parzibyte/364b7e32a4f321d70a3d62000c00e69d to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<table class="table table-bordered"> | |
<thead> | |
<tr> | |
<th>Código de barras</th> | |
<th>Descripción</th> | |
<th>Precio de compra</th> | |
<th>Precio de venta</th> | |
<th>Utilidad</th> | |
<th>Existencia</th> | |
<th>¿Servicio?</th> | |
<th>Editar</th> | |
<th>Eliminar</th> | |
</tr> | |
</thead> | |
<tbody> | |
@foreach($productos as $producto) | |
<tr> | |
<td>{{$producto->codigo_barras}}</td> | |
<td>{{$producto->descripcion}}</td> | |
<td>{{$producto->precio_compra}}</td> | |
<td>{{$producto->precio_venta}}</td> | |
<td>{{$producto->precio_venta - $producto->precio_compra}}</td> | |
<td>{{$producto->existencia}}</td> | |
<td> | |
@if($producto->es_servicio) | |
<i class="fa fa-check"></i> | |
@else | |
<i class="fa fa-times"></i> | |
@endif | |
</td> | |
<td> | |
<a class="btn btn-warning" href="{{route("productos.edit",[$producto])}}"> | |
<i class="fa fa-edit"></i> | |
</a> | |
</td> | |
<td> | |
<form action="{{route("productos.destroy", [$producto])}}" method="post"> | |
@method("delete") | |
@csrf | |
<button type="submit" class="btn btn-danger"> | |
<i class="fa fa-trash"></i> | |
</button> | |
</form> | |
</td> | |
</tr> | |
@endforeach | |
</tbody> | |
</table> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment