<?php $__env->startSection('title', '| Modifier Activité'); ?>

<?php $__env->startSection('content'); ?>

    <div class="content-wrapper">

        <div class="container">
            <div class="content-header">
                <div class="container-fluid">
                    <div class="row mb-2">
                    <div class="col-sm-6">
                        <h1 class="m-0 text-info">Modifier Activité <?php echo e($projet->nom); ?></h1>
                    </div><!-- /.col -->
                    <div class="col-sm-6">
                        <ol class="breadcrumb float-sm-right">
                        <li class="breadcrumb-item"><a href="<?php echo e(route('home')); ?>" role="button" class="btn btn-success">ACCUEIL</a></li>
                        <li class="breadcrumb-item active"><a href="<?php echo e(route('suiviactivite.projet',$projet_id)); ?>" role="button" class="btn btn-success">RETOUR</a></li>

                        </ol>
                    </div><!-- /.col -->
                    </div><!-- /.row -->
                </div><!-- /.container-fluid -->
            </div>

        <?php echo Form::model($suiviActivite, ['method'=>'PATCH','route'=>['suiviActivite.update', $suiviActivite->id]]); ?>

            <?php echo csrf_field(); ?>
             <div class="card border-danger border-0">
                        <div class="card-header bg-success text-center">FORMULAIRE DE MODIFICATION D'une activite <?php echo e($projet->nom); ?></div>
                        <div class="card-body">
                            <?php if($errors->any()): ?>
                                <div class="alert alert-danger">
                                    <ul>
                                        <?php $__currentLoopData = $errors->all(); $__env->addLoop($__currentLoopData); foreach($__currentLoopData as $error): $__env->incrementLoopIndices(); $loop = $__env->getLastLoop(); ?>
                                            <li><?php echo e($error); ?></li>
                                        <?php endforeach; $__env->popLoop(); $loop = $__env->getLastLoop(); ?>
                                    </ul>
                                </div>
                            <?php endif; ?>
                            <div class="col-lg-6">
                                <div class="form-group">
                                    <label>Activite</label>
                                    <select class="form-control" name="activite_id" required>
                                        <option value="">Faites un choix</option>
                                        <?php $__currentLoopData = $activites; $__env->addLoop($__currentLoopData); foreach($__currentLoopData as $activite): $__env->incrementLoopIndices(); $loop = $__env->getLastLoop(); ?>
                                        <option value="<?php echo e($activite->id); ?>" <?php echo e(old('activite_id', $suiviActivite->activite_id) == $activite->id ? 'selected' : ''); ?>><?php echo e($activite->nom); ?></option>
                                        <?php endforeach; $__env->popLoop(); $loop = $__env->getLastLoop(); ?>
                                    </select>
                                </div>
                            </div>
                            <div class="col-lg-6">
                                <div class="form-group">
                                    <label>Niveau  de réalisation</label>
                                    <select class="form-control" name="niveaur" required>
                                        <option value="">Faites un choix</option>
                                        <option value="realise" <?php echo e(old('niveaur', $suiviActivite->niveaur) == 'realise' ? 'selected' : ''); ?> >prévue réalisée</option>
                                        <option value="non realise" <?php echo e(old('niveaur', $suiviActivite->niveaur) == 'non realise' ? 'selected' : ''); ?>>non prévue réalisée</option>
                                    </select>
                                </div>
                            </div>
                            <input type="hidden" name="projet_id" value="<?php echo e($projet_id); ?>">
                            <div class="col-lg-6">
                                <div class="form-group">
                                    <label>Date de Réalsation</label>
                                    <input type="date" name="dater" id="from"  value="<?php echo e($suiviActivite->dater); ?>" class="form-control" required>
                                </div>
                            </div>
                            <div class="col-lg-12">
                                <div class="form-group">
                                <label>Résultats obtenus (Livrables)</label>
                                <textarea class="textarea" name="resultat" placeholder="Place some text here"
                                          style="width: 100%; height: 240px; font-size: 14px; line-height: 18px; border: 1px solid #dddddd; padding: 10px;"><?php echo e($suiviActivite->resultat); ?></textarea>
                                </div>
                            </div>
                            <div class="col-lg-12">
                                <div class="form-group">
                                <label>Observation</label>
                                <textarea class="textarea" name="observation" placeholder="Place some text here"
                                          style="width: 100%; height: 340px; font-size: 14px; line-height: 18px; border: 1px solid #dddddd; padding: 10px;"><?php echo e($suiviActivite->observation); ?></textarea>
                                </div>
                            </div>
                            <div class="col-lg-6">
                                <div class="form-group">
                                    <label>Lieu</label>
                                    <select class="form-control" id="commune_id" name="commune_id" required="">
                                        <option value="">Selectionnez</option>
                                        <?php $__currentLoopData = $communes; $__env->addLoop($__currentLoopData); foreach($__currentLoopData as $commune): $__env->incrementLoopIndices(); $loop = $__env->getLastLoop(); ?>
                                        <option value="<?php echo e($commune->id); ?>" <?php echo e($commune->id == $suiviActivite->commune_id ? 'selected' : ''); ?>><?php echo e($commune->nomc); ?></option>
                                            <?php endforeach; $__env->popLoop(); $loop = $__env->getLastLoop(); ?>

                                    </select>
                                </div>
                            </div>
                            <input type="hidden" name="projet_id" value="<?php echo e($activite->projet_id); ?>" required>
                            <div>
                                <center>
                                    <button type="submit" class="btn btn-success btn btn-lg "> ENREGISTRER</button>
                                </center>
                            </div>
                        </div>

                        </div>
    <?php echo Form::close(); ?>

                </div>
        </div>

    </div>

<?php $__env->stopSection(); ?>

<?php echo $__env->make('layout', \Illuminate\Support\Arr::except(get_defined_vars(), ['__data', '__path']))->render(); ?><?php /**PATH D:\enda\RFA\plateforme RFA\rfaBackend\resources\views/suiviActivite/edit.blade.php ENDPATH**/ ?>