<?php $__env->startSection('title', "Измени {$department->name}"); ?>

<?php $__env->startSection('content'); ?>
    <div class="container">
        <div class="h1 text-center">
            <?php echo e($department->name); ?>

        </div>

        <div class="row justify-content-center">
            <div class="col-md-8 mt-5">
                <form method="POST" action="<?php echo e(route('admin.departments.update', $department->id)); ?>">
                    <?php echo csrf_field(); ?>
                    <?php echo method_field('PATCH'); ?>

                    <?php echo $__env->make('admin.departments.partials.fields', \Illuminate\Support\Arr::except(get_defined_vars(), ['__data', '__path']))->render(); ?>

                    <div class="d-flex justify-content-center">
                        <button type="submit" class="btn btn-success mr-3">Сачувај</button>
                        <button type="button" class="btn btn-danger" data-toggle="modal" data-target="#delete-modal">Избриши</button>
                    </div>
                </form>
            </div>
        </div>
    </div>
    <form action="<?php echo e(route('admin.departments.destroy', $department)); ?>" method="POST">
        <?php echo csrf_field(); ?>
        <?php echo method_field('DELETE'); ?>

        <?php echo $__env->make('layouts.confirm_modal', [
            'name' => 'delete-modal',
            'title' => "Избриши {$department->name}",
            'text' => "Потврди брисање смера {$department->name}",
            'action' => 'Избриши',
            'cancel' => 'Одустани',
        ], \Illuminate\Support\Arr::except(get_defined_vars(), ['__data', '__path']))->render(); ?>
    </form>
<?php $__env->stopSection(); ?>

<?php echo $__env->make('layouts.admin', \Illuminate\Support\Arr::except(get_defined_vars(), ['__data', '__path']))->render(); ?><?php /**PATH /home/akademij/public_html/anketa-vranje/resources/views/admin/departments/edit.blade.php ENDPATH**/ ?>