<?php $__env->startSection('title', 'Manage Outputs'); ?>

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

    <div class="page-header clearfix">
        <h1 class="pull-left">Manage Outputs</h1>
        <a href="<?php echo e(URL::route('admin.output.create')); ?>" class="pull-right btn btn-default">Add output</a>
    </div>

    <table class="table table-striped">
        <thead>
            <tr>
                <th>Output Name</th>
                <th>Plural</th>
                <th></th>
            </tr>
        </thead>
        <tbody>
            <?php if(!count($outputs)): ?>
                <tr>
                    <td colspan="3" class="text-center">No outputs created. Why not, <a href="<?php echo e(URL::route('admin.output.create')); ?>">add a new output</a>?</td>
                </tr>
            <?php endif; ?>

            <?php foreach($outputs as $output): ?>
                <tr>
                    <td><?php echo e($output->name); ?></td>
                    <td><?php echo e($output->plural); ?></td>
                    <td>
                        <a class="btn btn-default" href="<?php echo e(URL::route('admin.output.show', $output->id)); ?>">View details</a>&nbsp;
                        <a class="btn btn-default" href="<?php echo e(URL::route('admin.assignedActions.createFor', 'output')); ?>">Assign actions</a>&nbsp;
                        <a class="btn btn-default" href="<?php echo e(URL::route('admin.output.edit', $output->id)); ?>">Edit</a>&nbsp;
                        <form action="<?php echo e(URL::route('admin.output.destroy', $output->id)); ?>" class="inline delete-form" method="post">
                            <?php echo csrf_field(); ?>

                            <input type="hidden" name="_method" value="DELETE">
                            <button class="btn btn-danger">Delete</button>
                        </form>
                    </td>
                </tr>
            <?php endforeach; ?>
        </tbody>
    </table>
<?php $__env->stopSection(); ?>

<?php echo $__env->make('layouts.admin', array_except(get_defined_vars(), array('__data', '__path')))->render(); ?>