<?php $__env->startSection('title'); ?>
    VICTORSPREDICT | Advertisement
<?php $__env->stopSection(); ?>
<?php $__env->startSection('page'); ?>
    Sponsored Ads
<?php $__env->stopSection(); ?>
<?php $__env->startSection('content'); ?>
    <div class="col-sm-12">
        <span class="pull-right"><a href="#" data-target="#sponsorModal" data-toggle="modal"><button class="btn btn-md btn-success">ADD NEW LINK</button></a></span>
        <hr>
        <table id="datatable" class="table table-striped table-bordered nowrap" cellspacing="0" width="100%">
            <thead>
            <tr>
                <th>SN</th>
                <th>SPONSOR NAME</th>
                <th>SPONSOR LINK</th>
                <th>STATUS</th>
                <th>EDIT</th>
                <th>DELETE</th>
            </tr>
            </thead>
            <tbody>
            <?php foreach($ads as $key => $item): ?>
                <tr id="record<?php echo e($item->id); ?>">
                    <td class="red"><?php echo e($key+1); ?></td>
                    <td><?php echo e($item->sponsorName); ?></td>
                    <td><?php echo e($item->sponsorUrl); ?></td>
                    <td>
                        <?php if($item->publishStatus=='0'): ?>
                            <span class="text-success">Published</span>
                        <?php else: ?>
                            <span class="text-danger">Draft</span>
                        <?php endif; ?>
                    </td>
                    <td><a class="fetchSponsor" href="<?php echo e(route('/editSponsor')); ?>" data-id="<?php echo e($item->id); ?>" data-target="#editSponsor" data-toggle="modal"><span style="color: green;"><i class="fa fa-edit"></i> EDIT</span></a></td>
                    <td><a href="<?php echo e(route('/deleteSponsor')); ?>" class="deleteItem" data-id="<?php echo e($item->id); ?>" data-msg="DELETE THIS SPONSOR"><i class=" fa fa-trash-o"></i> DELETE</a></td>
                </tr>
            <?php endforeach; ?>
            </tbody>
        </table>
    </div>
<?php $__env->stopSection(); ?>

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