{% load i18n %}
<table class="listing">
    <col width="40%" />
    <col width="40%"/>
    <col />
    <thead>
        <tr>
            <th class="title">{% trans "Search term(s)" %}</th>
            <th>{% trans "Promoted results" %}</th>
            <th>{% trans "Views (past week)" %}</th>
        </tr>
    </thead>
    <tbody>
        {% for query in queries %}
            <tr>
                <td class="title">
                    <h2><a href="{% url 'wagtailsearch_editorspicks_edit' query.id %}" title="{% trans 'Edit this pick' %}">{{ query.query_string }}</a></h2>
                </td>
                <td>
                    {% for editors_pick in query.editors_picks.all %}
                        <a href="{% url 'wagtailadmin_pages:edit' editors_pick.page.id %}" class="nolink">{{ editors_pick.page.title }}</a>{% if not forloop.last %}, {% endif %}
                    {% empty %}
                        {% trans "None" %}
                    {% endfor %}
                </td>
                <td>{{ query.hits }}</td>
            </tr>
        {% endfor %}
    </tbody>
</table>