Commit 38e0f538 by Francisco Salazar

distancia en vista

parent d09f3cf8
...@@ -328,7 +328,7 @@ class AdminProductController extends Controller ...@@ -328,7 +328,7 @@ class AdminProductController extends Controller
$shipping_price = $shipping->shipping_price; $shipping_price = $shipping->shipping_price;
$origin = CodigoPostal::where("postal_code", 67150)->first(); $origin = CodigoPostal::where("postal_code", 67150)->first();
$destination = CodigoPostal::where("postal_code", $addres->cp)->first(); $destination = CodigoPostal::where("postal_code", $shipping->cp)->first();
$total_cart = 0; $total_cart = 0;
foreach($sale->products()->get() as $p){ foreach($sale->products()->get() as $p){
......
...@@ -181,10 +181,10 @@ setlocale(LC_MONETARY, 'en_US'); ...@@ -181,10 +181,10 @@ setlocale(LC_MONETARY, 'en_US');
@endif @endif
@if($shipping_price != null) @if($shipping_price != null)
<tr> <tr>
<td>{{$distancia." km"}}</td> <td>{{$distance." km"}}</td>
<td>{{$shipping_price->name}}</td> <td>{{$shipping_price->name}}</td>
<td>{{money_format('%(#10n', $shipping_price->cost)}}</td> <td>{{money_format('%(#10n', $shipping_price->cost)}}</td>
<td>{{money_format('%(#10n', $shipping_price->cost * $distancia)}}</td> <td>{{money_format('%(#10n', $shipping_price->cost * $distance)}}</td>
</tr> </tr>
@endif @endif
<tfoot> <tfoot>
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment