{% load i18n material_form material_form_internal %}
{% part bound_field.field %}{% part field label %}
{% endpart %}
<div class="row" id="id_{{ bound_field.html_name }}_container">
    <div class="col s12">
        <label{% attrs bound_field 'label' %}
                 for="{{ bound_field.id_for_label }}"
                 {% endattrs %}>{{ bound_field.label }}</label>
    </div>
    <div class="input-field input-group" style="padding-left:10px;padding-right:10px">
        <div{% attrs bound_field 'group' %}
               class="{% if field.required %} required{% endif %}{% if bound_field.errors %} has-error{% endif %}"
               style="margin-top:-7px"
               {% endattrs %}>
            {% part field prefix %}{% endpart %}{% part field control %}
            <i class="material-icons prefix">view_module</i>
            <input{% attrs bound_field 'widget_date' default field.widget.attrs %}
                     id="id_{{ bound_field.html_name }}_0"
                     name="{{ bound_field.html_name }}_0"
                     type="text"
                     data-date-format="{{ field.fields.0|jquery_datepicker_format }}"
                     data-form-control="date"
                     {% if bound_field.errors %}class="invalid"{% endif %}
                     {% if bound_field.value %} value="{{ bound_field|multiwidget_value:0|datepicker_value:field.fields.0.input_formats.0 }}"{% endif %}
                     {% endattrs %}>
            {% endpart %}{% part field help_text %}
            {% part field errors %}
            {% if bound_field.errors %}
            {% include  'material/field_errors.html' %}
            {% endif %}
            {% endpart %}{% if field.help_text %}
            <small class="help-block">{{ bound_field.help_text }}</small>
            {% endif %}
            {% endpart %}{{ hidden_initial }}            
        </div>
        <div class="{% if field.required %} required{% endif %}{% if bound_field.errors %} has-error{% endif %}"
             style="margin-top:-7px">
            <i class="material-icons prefix" style="padding-left:10px">query_builder</i>
            <input{% attrs bound_field 'widget_time' default field.widget.attrs %}
                     id="id_{{ bound_field.html_name }}_1"
                     name="{{ bound_field.html_name }}_1"
                     type="text"
                     data-date-format="{{ field.fields.1|jquery_datepicker_format }}"
                     data-form-control="time"
                     {% if bound_field.errors %}class="invalid"{% endif %}
                     {% if bound_field.value %} value="{{ bound_field|multiwidget_value:1|datepicker_value:field.fields.1.input_formats.0 }}"{% endif %}                 
                     {% endattrs %}>
        </div>
        <span class="suffix">
            <a href="#" data-form-control="date-today-shortcut">{% trans 'Today' %}</a>
        </span>
    </div>
</div>{% endpart %}
