{% extends "admin/base_site.html" %}
{% load markup %}

{% block content_title %}<a class="brand">Choose data to Export</a>{% endblock %}


{% block content %}
<div class="row">
    <div class="span8">
        <form class="form" action="." method="POST" accept-charset="utf-8">

            <p>{% csrf_token %}</p>
            <table class="table">

            {{form.as_table}}

            <tr>
              <td></td><td><input class="btn btn-danger" type="submit" name="some_name" value="Download" id="some_name"></td>
            </tr>
            </table>
        </form>
    </div>
{% endblock %}

{% block sidebar %}
    <div class="span4">
        <h4>Information on data exporting</h4>

        <ul>
        <li> Data can be exported from multiple studies at once (e.g. sub-studies within a trial). </li>

        <li> Remember to <a href="{% url 'resolve_double_entry_conflicts' %}">resolve duplicate replies for your studies</a> before exporting if possible (get to this from the study edit page).</li>
        <li> Also remember that duplicate replies <strong>will be</strong> exported, but marked <code>1</code> in the <code>is_canonical_reply</code> column.</li>

        <li>To allow for a shared reference point (in time) for data exported, this form allows you to
        specify a 'reference study'. </li>
        <li>The date the participant was randomised to the reference study
        is used to calculate how many days from baseline (day 0) each observation is. This may be helpful when participants can enter substudies at slightly differently latencies,
        but final analyses need and offset from a common reference date (e.g. treatment commencement)</li>

        </ul>
    </div>
</div>

{% endblock %}

