@extends('layouts.user_type.auth') @section('content') @if(str_replace('-', ' ', Request::path()) != "administration") Ajouter une commande @endif Ajout d'une commande × Numéro du code de la commande * Article * Choisir . . . {{ $ps = DB::table("materiaus")->where("statut", "1")->orderby("nom")->get() }} @foreach($ps as $p) {{ $p->nom }} @endforeach Quantite * Prix Remise Date de la commande * Date de livraison Description Fournisseur Choisir . . . {{ $ps = DB::table("fournisseurs")->where("statut", "1")->orderby("nom")->get() }} @foreach($ps as $p) {{ $p->nom }} @endforeach Client Choisir . . . {{ $ps = DB::table("clients")->where("statut", "1")->orderby("nom")->get() }} @foreach($ps as $p) {{ $p->nom }} @endforeach LISTE DES COMMANDES ARTICLE QTE PRIX FOURNISSEUR ETAT DE LA COMMANDE ACTION @foreach($commandes as $commande) {{ DB::table("materiaus")->find($commande->article)->nom ?? '' }} {{ $commande->quantite ?? '' }} {{ $commande->prix ?? '' }} {{ DB::table("fournisseurs")->find($commande->fournisseur)->nom ?? '' }} {{ $commande->etat == 0 ? 'En attente de livraison' : 'Livraison éffectuée' ?? '' }} @if(collect(["BOSS", "RESPONSABLE EXECUTION"])->contains(auth()->user()->role)) @endif @endforeach {{ $commandes->links() }} @endsection