{% extends 'core_main_app/_render/admin/theme/tools/modal.html' %}

{% block modal_id %}add-module-modal{% endblock %}
{% block modal_title %}Manage Module{% endblock %}

{% block modal_body %}
<p>
    Select the module you want to associate with the selected element.
</p>
<table class="table table-condensed" id="modules-table">
    <tbody>
    <tr class="red-background">
        <td>Default behavior</td>
        <td>
            <button class="btn btn-danger delete">Restore</button>
        </td>
    </tr>
    {% for module in data.modules %}
    <tr>
        <td data-id="{{module.id}}" data-module-url-value="{{module.url}}">{{module.url | title}}</td>
        <td>
            <button class="btn btn-primary insert">Insert</button>
        </td>
    </tr>
    {% endfor %}
    </tbody>
</table>
{% endblock %}
{% block modal_footer %}
<a class="btn btn-secondary pull-left" data-dismiss="modal" href="#"><i class="fas fa-times"></i> Cancel</a>
{% endblock %}