{% extends 'CoyoteFrontBundle:Base:base.html.twig' %}

{% block nav %}
    {{ include('CoyoteFrontBundle:Base:navigation.html.twig') }}
{% endblock nav %}

{% block stylesheets %}
    <link rel="stylesheet" href="{{ asset('bundles/coyotefront/css/style_schedule.css') }}" type="text/css" media="all" />
{% endblock %}

{% block content %}

    <p id="title">{{"admin.title.exportbe"|trans}}</p>

    <form role="form" action="{{ path('schedule_exportdatauser') }}" method='post'>
        <table class='table' id='tab_expense'>
        	<tr>
        	    <th class="center">{{'admin.month'|trans}}</th>
        		<th class="center">{{'admin.year'|trans}}</th>
        	</tr>
            <tr>
                <td class="center">
                    {% set counter = 0 %}
                    <select name='month' id='month' >
                    {% for mois in tab_num_mois %}
                        {% if mois == month %}
                        <option value={{mois}} selected>{{tab_mois[counter]|trans}}</option>
                        {% else %}
                        <option value={{mois}}>{{tab_mois[counter]|trans}}</option>
                        {% endif %}
                        {% set counter = counter + 1 %}
                    {% endfor %}
                    </select>
                </td>
                <td class="center">
                    <select name='year' id='year' >
                    {% for annee in tab_annee %}
                        {% if annee == year %}
                        <option value={{annee}} selected>{{annee}}</option>
                        {% else %}
                        <option value={{annee}}>{{annee}}</option>
                        {% endif %}
                    {% endfor %}
                    </select>
                </td>
            </tr>
        </table>
        <div id="btn_show">
            <button class='btn btn-primary' type="submit" value="Telecharger" id="telecharger">{{'admin.submit.download'|trans}}</button>
        </div>
    </form>
{% endblock %}