{% extends 'beltradar/base.html' %}
{% load i18n %}

{% block page_template_title %}
    {{ title }}
{% endblock page_template_title %}

{% block page_topic %}
    <h1 class="page-header text-center">
        {{ title }}
    </h1>
{% endblock page_topic %}

{% block aabeltradar_header %}
    <div class="card">
        <div class="card-header bg-primary rounded d-flex align-items-center">
            <h3>{% translate "My Sessions" %}</h3>
        </div>
    </div>
{% endblock aabeltradar_header %}

{% block aabeltradar_block %}
    {% include 'beltradar/partials/view-my-sessions/survey-sessions-table.html' %}
{% endblock aabeltradar_block %}


{% block extra_css %}
    {% include 'bundles/datatables-2-css-bs5.html' %}
    {% include 'bundles/datatables-2-columncontrol-css-bs5.html' %}
    {% include 'beltradar/bundles/aa-beltradar-css.html' %}
{% endblock %}

{% block extra_javascript %}
    <script>
        /**
         * Override settings for Belt Radar
         */
        const aaBeltRadarSettingsOverride = {
            url: {
                mySessions: "{% url 'beltradar:api:get_my_sessions' character_id=character_id %}",
            },
            translations: {
                errorLoadingData: "{% translate 'An error occurred while loading sessions data.' %}"
            }
        };
    </script>
    {% include 'beltradar/bundles/aa-beltradar-js.html' %}
    {% include 'bundles/datatables-2-js-bs5.html' %}
    {% include 'bundles/datatables-2-columncontrol-js-bs5.html' %}
        <!-- load modals -->
    {% include 'beltradar/partials/modals/request-accept-delete-survey-session.html' %}
{% endblock extra_javascript %}
