<?php $__env->startSection('content'); ?>
    <h1>Manage Backend Users</h1>
    <div id="backend_users">
        <?php if($canInsert): ?>
        <button type="button" data-toggle="tooltip" data-placement="right" class="btn btn-default command-add list-add-btn" title="<?php echo Lang::get('backend.new_user'); ?>">
            <span class="icon glyphicon glyphicon-plus"></span>
        </button>
        <?php endif; ?>
        <table id="grid" class="table table-condensed table-hover table-striped">
            <thead>
                <tr>
                    <th data-column-id="id" data-type="numeric" data-identifier="true">ID</th>
                    <th data-column-id="first_name" data-order="asc">First name</th>
                    <th data-column-id="last_name">Last name</th>
                    <th data-column-id="email">Email</th>
                    <th data-column-id="role">Role</th>
                    <th data-column-id="commands" data-formatter="commands" data-sortable="false"><?php echo Lang::get('backend.actions'); ?></th>
                </tr>
            </thead>
        </table>
    </div>
    <script>
        $(function() {
            var manageUsersView = new Eae.View.BackendUsersList({
                el : $('#backend_users'),
                userId : "<?php echo Auth::backend()->user()->id; ?>",
                canInsert: <?php echo $canInsert ? 'true' : 'false'; ?>

            });
        });     
    </script>
<?php $__env->stopSection(); ?>
<?php echo $__env->make('admin.layouts.main', array('scripts' => array(Config::get('path.backoffice.js_path') . '/view/user/backend-users-list.js')), array_except(get_defined_vars(), array('__data', '__path')))->render(); ?>