
<?php $__env->startSection('categorias','active'); ?>
<?php $__env->startSection('categorias_true','true'); ?>
<?php $__env->startSection('categorias_show','show'); ?>
<?php $__env->startSection('categorias_collapsed','collapsed'); ?>
<?php $__env->startSection('form'); ?>

<div class="container">
    <div class="row">
        <div class="col-12">
            <h2>Editar categor&iacute;a para la secci&oacute;n <?= $seccion ?></h2>
        </div>
        <div class="col-12">
            <form method="POST" action="<?= route('editCategoria', $seccion) ?>" enctype="multipart/form-data">
    <?php echo csrf_field(); ?>
    <input type="hidden" name="id" value="<?= $categoria->id ?>">
    <div class="mb-3">
        <label for="inputNombre" class="form-label">Nombre</label>
        <input type="text" class="form-control" value="<?= $categoria->nombre ?>" id="inputNombre" required name="nombre">
    </div>
    <div class="mb-3">
        <label for="inputOrden" class="form-label">Orden</label>
        <input type="text" class="form-control" value="<?= $categoria->orden ?>" id="inputOrden" required name="orden">
    </div>
    <?php if($seccion == 'productos'){ ?>
        <div class="form-check">
            <?php if($categoria->destacado == 1){ ?>
                <input class="form-check-input" name="destacado" type="checkbox" id="flexCheckDefault" checked="checked">
            <?php } else { ?>
                <input class="form-check-input" name="destacado" type="checkbox" id="flexCheckDefault">
            <?php } ?>
            <label class="form-check-label" for="flexCheckDefault">
                Destacar categoria
            </label>
        </div>
    
        <div class="mb-3">
            <label for="formFile" class="form-label">Imagen(Tama&ntilde;o recomendado: 1080 x 1080 px)</label>
            <input class="form-control" type="file" id="formFile" name="foto">
            <img src="<?php echo e(asset(Storage::url($categoria->foto))); ?>" class="img-thumbnail mt-4 h-25 w-25">
        </div>
    <?php } ?>
    <button type="submit" class="btn btn-primary">Actualizar categor&iacute;a</button>
</form>
        </div>
    </div>
</div>



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

<?php echo $__env->make('adm.index', \Illuminate\Support\Arr::except(get_defined_vars(), ['__data', '__path']))->render(); ?><?php /**PATH /home/d11osolecom/public_html/grupohelmont/resources/views/adm/categorias/edit.blade.php ENDPATH**/ ?>