@extends ('includes.main-layout')

@section('styles')

@endsection

@section('header')
    @include('includes.admin-header')
@endsection

@section('content')
    <div class="row">
        <div class="col-md-6 mx-auto">
            <div class="card mt-4">
            @include('includes.errors')
                <div class="card-body">
                    <h3 class="card-title text-primary">Ajouter un produit</h3>
                    <hr>
                    <form action="{{route('products.store')}}" method="post" enctype="multipart/form-data">
                        <div class="form-group">
                            <label for="name">Libellé*</label>
                            <input type="text" name="name" class="form-control" id="name" placeholder="Libellé">
                            <input type="hidden" name="_token" class="form-control" value="{{csrf_token()}}">
                        </div>
                        <div class="form-group">
                            <label for="price">Prix*</label>
                            <input type="text" name="price" class="form-control" id="price" placeholder="Prix">
                        </div>
                        <div class="form-group">
                            <label for="file">Photo*</label>
                            <input type="file" name="file" class="form-control" id="file">
                        </div>
                        <div class="form-group">
                            <button class="btn btn-primary" type="submit">Valider</button>
                        </div>
                    </form>
                </div>
            </div>
        </div>
    </div>
@endsection

@section('footer')

@endsection

@section('scripts')

@endsection
