@extends('layouts.app') @section('content')

Bon de Commandes PDF Excel

@can('authorize', 'add_commands') Ajouter Un Nouveau Bon @endcan
@foreach($commands as $command) @endforeach
Date Code Fournisseur Produits Mode TVA Total Statut
{{ \Carbon\Carbon::create($command->date)->isoFormat('ll') }}
{{ ($command->code)?$command->code:"" }}
{{ ($command->supplier_id)?$command->supplier->name:"" }}
@php $products = json_decode($command->products); @endphp
@isset($products) @foreach($products as $product) {{ $product->command_quantity }} {{ json_decode($product->command_measure)->unit }}(s) de {{ $product->product }},
@endforeach @endif
{{ (isset($command->paymentMethod))?$command->paymentMethod->method:null }}
{{ $command->tva }}
{{ $command->total }} FCFA
{{ $command->state->name }}
@php $command->paymentMethod /* utile pour pouvoir recuperer payment_method dans data-command dans faire de merge */ @endphp
@if(request()->is('commands') || request()->is('commands/*')) @can('authorize', 'browse_commands') @includeIf('commands.show') @includeIf('commands.modal-command-print') @endcan @can('authorize', 'add_commands') @includeIf('commands.create') @endcan @can('authorize', 'edit_commands') @includeIf('commands.edit') @endcan @can('authorize', 'delete_commands') @includeIf('commands.delete') @endcan @endif @endsection @push('scripts') @endpush