@extends('layout')
@section('title','Stock ')
@section('description','Stock')
@section('content')
    <!-- content ends -->
	<div class="row">
	
    <div class="box col-md-12">
	@if (session('status'))
				<div class="alert alert-success" role="alert">
					<i class="ti-check"></i> {{ session('status') }}
				</div>
			@endif

			@if (session('error'))
				<div class="alert alert-danger" role="alert">
					<i class="ti-na"></i> {{ session('error') }}
				</div>
			@endif
	@if(session('user')->roles == "Admin")
	<br/><br/><br/><br/><br/>
		<div class="card">
                  <div class="card-header">
                    <h4>Par période</h4>
                  </div>
				  
                  <div class="card-body">
				  
				  <h7><strong>Veuillez d'abord sélectionner la date début et la date fin</strong></h7>
				  
				<form  action="{{route('recherche-situation')}}" method="POST">
                         {{csrf_field()}}
				
				  <div class="row" style="padding-top: 30px">
					<div class="col-lg-4 col-md-4"> 
					  <div class="form-group">
                      <label>Catégorie<font color="red">*</font></label>
                      <select class="form-control select2" name="categorie_id" required>
                        <option value="">Sélectionner la catégorie</option>
						<option value="0">Tous les produits</option>
						 @foreach($categorie as $categories)
						<option value="{{$categories->idcat}}">{{$categories->libelle}} </option>
						@endforeach
                      </select>
                    </div>
					</div>
					 <div class="col-lg-3 col-md-12"> 
					 <div class="form-group">
                      <label>Date début</label>
                      <input type="date" class="form-control" name="date_debut">
                    </div>
					</div>
					<div class="col-lg-3 col-md-12"> 
					 <div class="form-group">
                      <label>Date fin</label>
                      <input type="date" class="form-control" name="date_fin">
                    </div>
					</div>
					 <div class="col-lg-1 col-md-12" style="margin-top: 30px"> 
					 <button class="btn btn-icon  btn-primary " ><i  class="fa fa-search"></i></button>
					</div>
					</div>	  
				</form>
					  
					    </div>
						 
                    </div>
					@endif
		<br/>
</div>
</div><!--/#content.col-md-0-->
	@push('scripts')
	@endpush
@endsection