<?php $__env->startSection('titulo'); ?>
    <i class="fas fa-globe-americas"></i> Cadastro de UF
<?php $__env->stopSection(); ?>

<?php $__env->startSection('scripts'); ?>
    <script src="<?php echo e(URL::asset('js/views/adm/uf.js')); ?>"></script>
<?php $__env->stopSection(); ?>

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

<div class="content-wrapper">
    <div class="container-fluid mt-2">
        <div class="card">
            <div class="card-body">
                <div class="row" >
                    <div class="col panel panel-primary table-responsive">

                        <table id="tbEstados" class="table table-striped table-bordered text-left ">
                            <thead  style="background-color:#333333; color: #ccc; font-weight: bold;">
                                <tr>
                                    <th>Nome</th>
                                    <th>Sigla</th>
                                    <th>Ações</th>
                                </tr>
                            </thead>
                            <tbody>

                                <?php $__currentLoopData = $ufs; $__env->addLoop($__currentLoopData); foreach($__currentLoopData as $uf): $__env->incrementLoopIndices(); $loop = $__env->getLastLoop(); ?>
                                    <tr>
                                        <td id="<?php echo e($uf->getId()); ?>_nome"><?php echo e($uf->getNome()); ?></td>
                                        <td id="<?php echo e($uf->getId()); ?>_sigla"><?php echo e($uf->getSigla()); ?></td>
                                        <td>
                                            <span name="editBtn" class="fas fa-edit fa-2x" data="<?php echo e($uf->getId()); ?>" style="cursor: pointer;color: #009933;" title="Editar"></span>
                                        </td>
                                    </tr>
                                <?php endforeach; $__env->popLoop(); $loop = $__env->getLastLoop(); ?>

                            </tbody>
                        </table>

                    </div>
                </div>
            </div>
        </div>
    </div>
</div>

    <!-- Inclui formulário modal -->
    <?php echo $__env->make('partials._modal_form',
    [
        'titulo'=> 'Atualizar Estado',
		'icone'=> 'fa-globe-americas',
        'rota' => 'adm.uf.salvar',
        'campos'=> 
        [
            [
                'id' =>'txtNome',
                'label'=>'Nome',
                'nome'=>'nome',
                'tamanho'=>'50',
                'tipo'=>'txt',
                'required'=> true,
                'autofocus'=> true,
                'disabled'=>false
            ],
            [
                'id' =>'txtSigla',
                'label'=>'Sigla',
                'nome'=>'sigla',
                'tamanho'=>'2',
                'tipo'=>'txt',
                'required'=> true,
                'autofocus'=> true,
                'disabled'=>false
            ]
        ]
    ], \Illuminate\Support\Arr::except(get_defined_vars(), array('__data', '__path')))->render(); ?>

<?php $__env->stopSection(); ?>
<?php echo $__env->make('layouts.app', \Illuminate\Support\Arr::except(get_defined_vars(), array('__data', '__path')))->render(); ?>