{% load bootstrap_toolkit %}
{% load crud_renderer %}

<table class="table">
    <tr>
    {% for action in global_actions %}
        <td><a href="{% url form_url %}/{{ action.opt }}">{{ action.caption }}</a></td>
    {% endfor %}
    </tr>
</table>

<table class="table">
    <tr>
        {% for attr, designs, header in action.columns %}
            <td>{{ header|apply_design:action.header_designs }}</td>
        {% endfor %}

        {% for action in global_actions %}
            <td></td>
        {% endfor %}
    </tr>
        
    {% for elem in action.elements %}
        <tr class="{{ action|apply_css:elem }}">
            {%for attr, designs, header in action.columns %}
                <td>{{ elem|get_attribute:attr|apply_design:designs }}</td>
            {% endfor %}

            {% for action in row_actions %}
                <td><a href="{% url form_url %}/{{ action.opt }}/{{ elem.id }}">{{ action.caption }}</a></td>
            {% endfor %}
        </tr>
    {% endfor %}
</table>
    
{{ action.elements|pagination }}

