<?php $__env->startSection('content'); ?>
<div class="col-md-12 content-header" >
    <h1><i class="fa fa-puzzle-piece"></i> products</h1>
</div>

<section class="content">
    <div class="row">
        <div class="col-md-12">
            <!--    Hover Rows  -->
            <a href="<?php echo e(route('products.create')); ?>" class="btn btn-primary btn-sm pull-right" data-toggle="ajax-modal"> <i class="fa fa-plus"></i> New Product</a> <br/><br/>
            <?php if(Session::has('flash_notification.message')): ?>
            <?php echo message(); ?>

            <?php endif; ?>
            <div class="panel panel-default">
                <div class="panel-heading">
                    Products
                </div>
                <div class="panel-body">
                    <table class="table table-bordered table-striped table-hover datatable">
                        <thead>
                        <tr>
                            <th></th>
                            <th>Name</th>
                            <th>Code</th>
                            <th>Category</th>
                            <th>Price</th>
                            <th>Action </th>
                        </tr>
                        </thead>
                        <tbody>
                        <?php foreach($products as $product): ?>
                        <tr>
                            <td></td>
                            <td><?php echo e($product->name); ?> </td>
                            <td><?php echo e($product->code); ?> </td>
                            <td><?php echo e($product->category); ?> </td>
                            <td><?php echo e($product->price); ?> </td>
                            <td>
                                <?php echo edit_btn('products.edit', $product->id); ?>

                                <?php echo delete_btn('products.destroy', $product->id); ?>

                            </td>
                        </tr>
                        <?php endforeach; ?>
                        </tbody>
                    </table>
                </div>
            </div>
            <!-- End  Hover Rows  -->
        </div>
    </div>
</section>
<?php $__env->stopSection(); ?>

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