{% if 0 < userPager|length %}
    <table class="table user_badge_list">
        <thead>
            <th class="username">{{ 'username'|trans({}, 'platform') }}</th>
            <th>{{ 'awarded_badges'|trans({}, 'badge') }}</th>
        </thead>
        <tbody>
            {% for user in userPager %}
                <tr>
                    <td>
                        <a href="{{ path('claro_public_profile_view', {'publicUrl': user.getPublicUrl()}) }}">{{ user.lastName ~ ' ' ~ user.firstName }}</a>
                    </td>
                    <td>
                       <ul class="list-inline">
                       {% for badge in user.badges %}
                           <li>
                                <a href="{{ path(parameters.edit_link.url, {'slug': badge.slug}|merge(parameters.route_parameters)) }}" title="{{ badge.name }}">
                                    <img class="badge_image" src="{{ asset(badge.webPath) }}" alt="{{ badge.name }}" />
                                </a>
                           </li>
                       {% endfor %}
                       </ul>
                    </td>
                </tr>
            {% endfor %}
        </tbody>
    </table>
    {% if userPager.haveToPaginate %}
        <div>
            {{
                pagerfanta(
                    userPager,
                    'twitter_bootstrap_translated',
                    {
                        'proximity' :    1,
                        'routeName':     parameters.current_link,
                        'routeParams':   parameters.route_parameters,
                        'pageParameter': '[userPage]',
                        'queryString':   '#!users'
                    }
                )
            }}
        </div>
    {% endif %}
{% else %}
    <p>{{ 'no_user_subscribed_to_workspace'|trans({}, 'badge') }}</p>
{% endif %}