<div class="form-group row">
    <div class="col-md-6">
    <?php echo html()->label( 'Nom','name'); ?>

    <?php echo html()->text('name', null)->attributes([($mode=="show"?'disabled':''), 'placeholder' => 'Nom','class' => 'form-control text-uppercase']); ?>

    </div>

</div>


<div class="form-group row">
    <div class="col-md-6">
    <?php echo html()->label( 'Email','email'); ?>

    <?php echo html()->email('email', null)->attributes([($mode=="show"?'disabled':''), 'placeholder' => 'Email','class' => 'form-control text-lowercase']); ?>

    </div>
</div>


<div class="form-group row">
    <div class="col-md-4">
    <?php echo html()->label( 'Mot de passe','password'); ?>

    <?php echo html()->password('password', null)->attributes([($mode=="show"?'disabled':''), 'placeholder' => 'Mot de passe','class' => 'form-control text-lowercase']); ?>

    </div>
</div>

<div class="form-group row">
    <div class="custom-control custom-switch custom-switch-off-danger custom-switch-on-success">
        <?php echo html()->checkbox('change_pwd', null)->attributes([($mode=="show"?'disabled':''),'id' => 'change_pwd', 'class' => 'custom-control-input']); ?>

        <label class="custom-control-label" for="change_pwd">Changer à la prochaine connexion</label>
    </div>
</div>

<div class="form-group row">
    <div class="custom-control custom-switch custom-switch-off-danger custom-switch-on-success">
        <?php echo html()->checkbox('actif', null)->attributes([($mode=="show"?'disabled':''),'id' => 'actif', 'class' => 'custom-control-input']); ?>

        <label class="custom-control-label" for="actif">Actif</label>
    </div>
</div>

<div class="row">
    <div class="col-md-6">
        <div class="form-group">
            <?php echo html()->label( 'Rôles','roles'); ?>

            <select id="users_role" name="users_role[]" class="select2"
                multiple="" data-placeholder="Choisissez un rôle..." style="width: 100%;" data-select2-id="8" <?php echo e(($mode=="show"?'disabled':'')); ?> >
                    <?php $__currentLoopData = $liste_roles; $__env->addLoop($__currentLoopData); foreach($__currentLoopData as $role=>$nom_role): $__env->incrementLoopIndices(); $loop = $__env->getLastLoop(); ?>
                        <option
                            <?php echo (in_array($nom_role,$t_getroles)?"selected":""); ?>

                            value="<?php echo $nom_role; ?>"><?php echo $nom_role; ?>

                        </option>
                    <?php endforeach; $__env->popLoop(); $loop = $__env->getLastLoop(); ?>
            </select>
        </div>
    </div>
</div>

<div class='form-group'>
    <?php if($mode=="show"): ?>
        <?php if($user_sel->IsModifiable): ?> <a class="btn btn-primary" href="<?php echo url('users/'.$user_sel->id.'/edit'); ?>" id="btn_modifier">Modifier</a><?php endif; ?>
    <?php else: ?>
        <?php echo html()->button('Enregistrer')->value('Enregistrer')->type('submit')->attributes(['class' => 'btn btn-primary']); ?>

    <?php endif; ?>

    <?php if(($mode=="show") && $user_sel->IsSupprimable): ?>
        <?php echo e(html()->form('DELETE', url('/users/'. $user_sel->id))->open()); ?>

        &nbsp;<button class="btn btn-danger" onclick="if(!confirm('Voulez-vous vraiment supprimer cet utilisateur ?')) return false;">Supprimer</button>
        <?php echo e(html()->form()->close()); ?>

    <?php endif; ?>


    &nbsp;<a class="btn btn-warning"  href="<?php echo url('users/'); ?>">Retour</a>
</div>

<?php /**PATH C:\xampp\htdocs\DOUANES\SYGI\SYGI2_VISU\resources\views/acces/users/content.blade.php ENDPATH**/ ?>