

<?php $__env->startSection('content'); ?>
    <div class="row match-height">
        <div class="col-md-12 col-12">
            <div class="card">
                <div class="card-header">
                    <h4 class="card-title text-primary">Cadastrando Agente Político</h4>
                    <p class="text-muted">Cadastrando Agente Político no Sistema</p>
                    <a class="btn btn-outline-primary btn-block d-grid gap-2" type="button"
                        href="<?php echo e(route('agentespoliticos.index')); ?>" role="button">Ver todos</a>
                </div>
                <div class="card">
                    <div class="card-body">
                        <form action="<?php echo e(route('agentespoliticos.store')); ?>" method="POST" class="form-horizontal"
                            enctype="multipart/form-data">
                            <?php echo csrf_field(); ?>
                            <div class="box box-info">
                                <!-- Nome -->
                                <div class="row">
                                    <div class="form-group col-md-10">
                                        <label class="col-form-label">Nome <span>*</span></label>
                                        <input type="text" name="nome" value="<?php echo e(old('nome')); ?>"
                                            class="form-control <?php $__errorArgs = ['nome'];
$__bag = $errors->getBag($__errorArgs[1] ?? 'default');
if ($__bag->has($__errorArgs[0])) :
if (isset($message)) { $__messageOriginal = $message; }
$message = $__bag->first($__errorArgs[0]); ?> is-invalid <?php unset($message);
if (isset($__messageOriginal)) { $message = $__messageOriginal; }
endif;
unset($__errorArgs, $__bag); ?>">
                                    </div>
                                    <!-- Status -->
                                    <div class="col-md-2">
                                        <label class="col-form-label">Ativo</label><br>
                                        <label class="radio-inline">
                                            <input type="radio" name="status" value="S"
                                                <?php echo e(old('status', 'S') == 'S' ? 'checked' : ''); ?>> Sim
                                        </label>
                                        <label class="radio-inline">
                                            <input type="radio" name="status" value="N"
                                                <?php echo e(old('status') == 'N' ? 'checked' : ''); ?>> Não
                                        </label>
                                    </div>
                                </div>
                                <!-- Cargo -->
                                <div class="row">
                                    <div class="col-md-6">
                                        <label class="col-form-label">Cargo </label>
                                        <select class="form-control <?php $__errorArgs = ['id_cargo'];
$__bag = $errors->getBag($__errorArgs[1] ?? 'default');
if ($__bag->has($__errorArgs[0])) :
if (isset($message)) { $__messageOriginal = $message; }
$message = $__bag->first($__errorArgs[0]); ?> is-invalid <?php unset($message);
if (isset($__messageOriginal)) { $message = $__messageOriginal; }
endif;
unset($__errorArgs, $__bag); ?>"
                                            name="id_cargo">
                                            <option value="">Selecione</option>
                                            <?php $__currentLoopData = $cargos; $__env->addLoop($__currentLoopData); foreach($__currentLoopData as $cargo): $__env->incrementLoopIndices(); $loop = $__env->getLastLoop(); ?>
                                                <option value="<?php echo e($cargo->id); ?>"
                                                    <?php echo e(old('id_cargo') == $cargo->id ? 'selected' : ''); ?>>
                                                    <?php echo e($cargo->descricao); ?>

                                                </option>
                                            <?php endforeach; $__env->popLoop(); $loop = $__env->getLastLoop(); ?>
                                        </select>
                                    </div>
                                </div>
                                <!-- Foto -->
                                <div class="form-group">
                                    <label class="col-form-label">Foto</label>
                                    <input type="file" name="foto"
                                        class="form-control <?php $__errorArgs = ['foto'];
$__bag = $errors->getBag($__errorArgs[1] ?? 'default');
if ($__bag->has($__errorArgs[0])) :
if (isset($message)) { $__messageOriginal = $message; }
$message = $__bag->first($__errorArgs[0]); ?> is-invalid <?php unset($message);
if (isset($__messageOriginal)) { $message = $__messageOriginal; }
endif;
unset($__errorArgs, $__bag); ?>">
                                </div>
                                <!-- Contato -->
                                <div class="row">
                                    <div class="col-md-6">
                                        <label class="col-form-label">Telefone</label>
                                        <input type="text" name="telefone" value="<?php echo e(old('telefone')); ?>"
                                            class="form-control <?php $__errorArgs = ['telefone'];
$__bag = $errors->getBag($__errorArgs[1] ?? 'default');
if ($__bag->has($__errorArgs[0])) :
if (isset($message)) { $__messageOriginal = $message; }
$message = $__bag->first($__errorArgs[0]); ?> is-invalid <?php unset($message);
if (isset($__messageOriginal)) { $message = $__messageOriginal; }
endif;
unset($__errorArgs, $__bag); ?>">
                                    </div>
                                    <div class="col-md-6">
                                        <label class="col-form-label">E-mail</label>
                                        <input type="email" name="email" value="<?php echo e(old('email')); ?>"
                                            class="form-control <?php $__errorArgs = ['email'];
$__bag = $errors->getBag($__errorArgs[1] ?? 'default');
if ($__bag->has($__errorArgs[0])) :
if (isset($message)) { $__messageOriginal = $message; }
$message = $__bag->first($__errorArgs[0]); ?> is-invalid <?php unset($message);
if (isset($__messageOriginal)) { $message = $__messageOriginal; }
endif;
unset($__errorArgs, $__bag); ?>">
                                    </div>
                                </div>
<br>
                                <!-- Submit Button -->
                                <div class="form-group">
                                    <button type="submit" class="btn btn-outline-success btn-sm w-100"
                                        name="form1">Gravar</button>
                                </div>
                            </div>
                        </form>
                    </div>
                </div>
            </div>
        </div>
    </div>
<?php $__env->stopSection(); ?>

<?php echo $__env->make('admin.layouts.layout', \Illuminate\Support\Arr::except(get_defined_vars(), ['__data', '__path']))->render(); ?><?php /**PATH C:\laragon\www\portalmunicipal\resources\views/admin/agentespoliticos/create.blade.php ENDPATH**/ ?>