@extends('layouts.header-Admin')
@section('modification')

<div class="pagetitle">

    <div class="row">

        <h1 class="col">Modifications</h1>

        <nav>
            <ol class="breadcrumb">
                <li class="breadcrumb-item"><a href="{{ route('admin.index') }}">liste des policiers</a></li>
                <li class="breadcrumb-item">modification</li>
                <h1 class="col-11 text-end">
                    <a href="{{ route('admin.index') }}">
                        <button type="button" class="btn btn-success">Retour</button>
                    </a>
                </h1>
            </ol>

        </nav>

    </div>

    <nav>
        <ol class="breadcrumb">
            <li class="breadcrumb-item"><a href="#"></a></li>
        </ol>
    </nav>
</div><!-- End Page Title -->

<section class="section">
    <div class="row">
        <div class="col-lg-9 " style="margin-left: 80px">
            <div class="card">
                <div class="card-body mt-5">
                    <form action="{{ route('admin.update', $admin->id) }}" method="POST">
                        @csrf
                        @method('put')

                        <div class="row">
                            <div class="col-sm-6">
                                <label for="formMatricule" class="form-label">Matricule</label>
                                <input type="text" class="form-control" value="{{ $admin->matricule }}"
                                    name="matricule" id="formMatricule" disabled readonly required>
                            </div>
                            <div class="col-sm-6">
                                <label for="inputPrenom" class="form-label">Nom Prenoms</label>
                                <input type="text" value="{{ $admin->nom }} {{ $admin->prenoms }}"   class="form-control"
                                    id="inputPrenom" disabled readonly required>
                            </div>
                        </div>
                        <div class="row mt-3">
                            <div class="col-sm-6">
                                <label for="inputCorps" class="form-label">Corps</label>
                                <input type="text" value="{{ $admin->corps }}" name="corps"
                                    class="form-control" id="inputCorps" required>
                            </div>
                            <div class="col-sm-6">
                                <label for="inputGrade" class="form-label">Grade</label>
                                <input type="text" value="{{ $admin->grade }}" name="grade"
                                    class="form-control" id="inputTaille" required>
                            </div>
                        </div>


                        <div class="row mt-3">
                            <div class="col-sm-12 text-end">
                                <button class="btn btn-color" type="submit">Modifier</button>
                            </div>
                        </div>
                    </form>
                </div>
            </div>
        </div>
    </div>
</section>
@endsection
