<?php $__env->startSection('title', 'Filtre - Lista'); ?>

<?php $__env->startSection('content_header', 'Filtre <small>lista filtre</small>'); ?>

<?php $__env->startSection('content'); ?>
    <div class="row">
        <div class="col-xs-12">
            <div class="box">
                <div class="box-header">
                    <h3 class="box-title">Filtre</h3>
					<div class="box-tools">
                        <a href="<?php echo e(route('admin.filtre.create')); ?>" class="btn btn-box-tool pull-right" data-toggle="tooltip" title="Create" data-widget="chat-pane-toggle" data-original-title="Create"><i class="fa fa-plus"></i> Create</a>
                        <form class="form-horizontal" method="GET" action="<?php echo e(route('admin.filtre.index')); ?>">
                            <div class="input-group">
                                <input type="text" name="query" class="form-control input-sm pull-right" style="width: 180px;" placeholder="Search by title, location..." value="<?php echo e($query); ?>">
                                <div class="input-group-btn">
                                    <button class="btn btn-sm btn-default"><i class="fa fa-search"></i></button>
                                </div>
                            </div>
                        </form>
                    </div>
                </div>
                <?php if(count($filtre) > 0): ?>
                    <div class="box-body table-responsive no-padding">
                        <table class="table table-hover">
                            <tr>
                                <th><?php echo $__env->make('admin._partials.sort_snippet', ['_field' => 'id', '_title' => '#'], array_except(get_defined_vars(), array('__data', '__path')))->render(); ?></th>
                                <th><?php echo $__env->make('admin._partials.sort_snippet', ['_field' => 'nume_filtru', '_title' => 'Nume filtru'], array_except(get_defined_vars(), array('__data', '__path')))->render(); ?></th>
                                <th><?php echo $__env->make('admin._partials.sort_snippet', ['_field' => 'title', '_title' => 'Categorie'], array_except(get_defined_vars(), array('__data', '__path')))->render(); ?></th>
								<th>&nbsp;</th>
                            </tr>
                            <?php foreach($filtre as $filtru): ?>
                                <tr>
                                    <td><?php echo e($filtru->id); ?></td>
                                    <td><?php echo e($filtru->filter_name); ?></td>
									<td><?php echo e(@$filtru->category[0]->title); ?></td>
                                    <td class="text-right">
										<a href="<?php echo e(route('admin.valori.indexValue', $filtru->id)); ?>" class="btn btn-success btn-xs">Adauga valori</a>
                                        <a href="<?php echo e(route('admin.filtre.edit', $filtru->id)); ?>" class="btn btn-warning btn-xs">editare</a>
                                        <a href="<?php echo e(route('admin.filtre.delete', $filtru->id)); ?>" class="btn btn-danger btn-xs confirm-action">stergere</a>
                                    </td>
                                </tr>
                            <?php endforeach; ?>
                        </table>
                    </div>
                    <?php if($filtre->hasPages()): ?>
                        <div class="box-footer">
                            <?php echo $filtre->render(); ?>

                        </div>
                    <?php endif; ?>
                <?php else: ?>
                    <div class="box-body">
                        <div class="alert alert-info">Nu exista filtre</div>
                    </div>
                <?php endif; ?>
            </div>
        </div>
    </div>
<?php $__env->stopSection(); ?>
<?php echo $__env->make('admin.app', array_except(get_defined_vars(), array('__data', '__path')))->render(); ?>