@extends('layout')
@section('title','Retour d\'emballage  ')
@section('description','Détails retour emballage')
@section('content')
<div class="section-header">
            <h1>Retour emballage</h1>
            <div class="section-header-breadcrumb">
              <div class="breadcrumb-item active"><a href="{{route('nouveau_transfert')}}">Retour d'emballage  </a></div>
              <div class="breadcrumb-item"><a href="#">Retour d'emballage</a></div>
            </div>
          </div>
          <div class="section-body">
		    @if (session('status'))
            <div class="alert alert-warning" style="font-size: 15px; background-color: #328039; color: white">
                <i class="fa fa-check"></i> &nbsp; {{ session('status') }}
            </div>
        @endif

        @if (session('error'))
            <div class="alert alert-danger" style="font-size: 15px; background-color: #fb5757; color: white">
                <i class="ti-na"></i> {{ session('error') }}
            </div>
        @endif
        @if ($errors->any())
            <div class="alert alert-danger" style="font-size: 15px; background-color: #fb5757; color: white" >
                <ul>
                    @foreach ($errors->all() as $error)
                        <li> <i class="ti-na"></i> {{ $error }}</li>
                    @endforeach
                </ul>
            </div>
        @endif
            
          </div>
		  
		  
		   <div class="section-body">
            <div class="row">
              <div class="col-12">
                <div class="card">
                  <div class="card-header">
                    <h4>Détails emballage</h4>
                  </div>
                  <div class="card-body">
                    <div class="table-responsive">
                      <table class="table table-striped" id="table-1">
                        <thead>
                          <tr>
                            <th class="text-center"> N° </th>
                            <th class="text-center">Emballage</th>
							<th class="text-center">Quantité</th>
							<th class="text-center">Etat</th>
                            
                          </tr>
                        </thead>
                        <tbody>
						@foreach($ligne as $lignes)
                          <tr>
							<td style="text-align:center;">{{$loop->iteration}}</td>
							
							<td style="text-align:center;"> {{ DB::table('emballage')->where('id', $lignes->emballage_id)->first()->libelle }} </td>
							
							<td style="text-align:center;">{{$lignes->qte}}</td>
							
							 <td class="text-center">
							    @if( $lignes->etat ==  "En cours")
									
                                  <div class="badge badge-warning badge-shadow">{{$lignes->etat}}</div>
							    @else
                                      <div class="badge badge-success badge-shadow">{{$lignes->etat}}</div>
                                @endif
								  
                            </td>
		
                          </tr>
						  @endforeach
                        </tbody>
                      </table>
                    </div>
                  </div>
                </div>
              </div>
            </div>
           
           
          </div>
		  
             
            </div>
          </div>
		  
	   @push('scripts') 
	   
	   
@endpush

@endsection