{% load i18n %}
<table class="table table-condensed table-responsive-md">
    <thead>
        <tr>
            <th>Question</th>
            <th>required</th>
            <th>active</th>
            <th></th>
        </tr>
    </thead>
    <tbody>
        {% for question in questions %}
            <tr {% if not question.active %}class="table-secondary"{% endif %}>
                <td>
                    <a href="{{ question.urls.base }}">
                        {{ question.question }}
                    </a>
                </td>
                <td>
                    <span class="fa fa-{% if question.required %}check-circle{% else %}times-circle{% endif %}">

                    </span>
                </td>
                <td>
                    <span class="fa fa-{% if question.active %}check-circle{% else %}times-circle{% endif %}">

                    </span>
                </td>
                <td class="text-right">
                    <a href="{{ question.urls.edit }}"
                        class="btn btn-sm btn-secondary">
                        <span class="fa fa-pencil"></span>
                    </a>
                    <a href="{{ question.urls.delete }}"
                        class="btn btn-sm btn-secondary">
                        <span class="fa fa-trash"></span>
                    </a>
                </td>
            </tr>
        {% empty %}
            <tr><td>
                {% trans "You have configured no questions yet." %}
                <a href="{{request.event.cfp.urls.new_question }}?type={{ type }}" class="btn btn-small btn-secondary">
                    <i class="fa fa-plus"></i>
                    {% trans "Add a question now!" %}
                </a>
            </td></tr>
        {% endfor %}
    </tbody>
</table>
