{% extends "admin/base.html" %}
{% load i18n %}


<!-- 20/01/2012 MJG - add datetimepicker widget to the from/until dates
     http://trentrichardson.com/examples/timepicker/  -->
{% block extrahead %}
<link rel="stylesheet" type="text/css" href="/media/css/jquery-ui.css" />
<link rel="stylesheet" type="text/css" href="/media/css/jquery-ui-timepicker-addon.css" />
<script src="/media/admin/js/jquery.min.js"></script>
<script src="/media/js/jquery-ui.min.js"></script>
<script src="/media/js/jquery-ui-timepicker-addon.js"></script>
<script type="text/javascript">
    $(function() {
        $("#id_datefrom").datetimepicker({
            dateFormat: 'yy-mm-dd',
            timeFormat: 'hh:mm:ss',
            minDate: {{ bots_minDate }},
            maxDate: 0.1,
        });
        $("#id_dateuntil").datetimepicker({
            ampm: false,
            dateFormat: 'yy-mm-dd',
            timeFormat: 'hh:mm:ss',
            minDate: {{ bots_minDate }},
            maxDate: 0.1,
        });
    });
</script>
{% endblock %}

{% block content %}
<br/>
{% if request.META.PATH_INFO == "/processes/" %}
    <h1>Select process errors</h1>
{% else %}
    {% if request.META.PATH_INFO == "/confirm/" %}
        <h1>Select confirmations</h1>
    {% else %}
        <h1>Select {{request.META.PATH_INFO|cut:'/'}}</h1>
    {% endif %}
{% endif %}
<p>&nbsp;Make your required selections below:</p>
<br/>
<form action="{{ form.action }}" method="post">{% csrf_token %}
    <table>
        {{ form.as_table }}
    </table>
    <br/>&nbsp;
    <p></p>
    <input type="submit" name="fromselect" value="{% trans 'Show selection' %}" />
</form>
{% endblock %}
