{% load static %}
<div class="container_form_search_carrier">
    <div class="cont-el-form-search-carrier first abbreviation">
        <label for="id_from_address_point_txt">Откуда</label>

{#                        <input onfocus="focus_el_ins(this)" onclick="show_list_w_places(this)" oninput="searchTown(this)" class="inp_form_find_route_w_abbreviation first" id="inp_form_find_route_w_abbreviation_1" type="text">#}

{#                        <div class="insert-airports-place" id="insert-airports-place_1">#}
{#                            {% include "widgets/w_places_input.html" %}#}
{#                        </div>#}
        <div class="container_inp_w_abr">
            <input
                type="number"
                name="from_address_point"
                id="id_from_address_point"
                class="el_form_find_route"
                hidden
                class="disp-none"
                {% if route_form.initial.from_address_point %}value="{{ route_form.initial.from_address_point }}"{% endif %}
            />
            <input
                oninput="searchTown(this)"
                onclick="showSearchList(this)"
                onblur="onblurInputField(event, this)"
                onFocus="this.select()"
                autocomplete="off"
                type="text"
                minlength="3"
                name="from_address_point_txt"
                class="from_address_point_txt find_route first"
{#                            {% if form.fields.from_address_point.required %} required{% endif %}#}
                id="id_from_address_point_txt"
                {% if route_form.initial.from_address_point_txt %}value="{{ route_form.initial.from_address_point_txt }}"{% endif %}
            />
            <div id="abbreviation_airport_in_search" class="abbreviation_airport_in_search"></div>
            <div class="input_list find_route" name="from_address_point_txt_list">

            </div>
        </div>
    </div>
    <div class="cont-el-form-search-carrier">
        <label for="id_to_address_point_txt">Куда</label>
{#                    <div class="container_inp_w_abr">#}
{#                        <input onfocus="focus_el_ins(this)" onclick="show_list_w_places(this)" oninput="searchTown(this)" class="inp_form_find_route_w_abbreviation" id="inp_form_find_route_w_abbreviation_2" type="text">#}

{#                        <div class="insert-airports-place" id="insert-airports-place_2">#}
{#                            {% include "widgets/w_ac_input_address_point.html" %}#}
{#                        </div>#}
{#                    </div>#}
        <div class="container_inp_w_abr">
            <input
                    type="number"
                    name="to_address_point"
                    id="id_to_address_point"
                    class="el_form_find_route"
                    hidden
                    class="disp-none"
                    {% if route_form.initial.to_address_point %}value="{{ route_form.initial.to_address_point}}"{% endif %}/>
            <input
                oninput="searchTown(this)"
                onclick="showSearchList(this)"
                onblur="onblurInputField(event, this)"

                onFocus="this.select()"
                autocomplete="off"
                type="text"
                name="to_address_point_txt"
{#                            {% if form.fields.to_address_point.required %} required{% endif %}#}
                id="id_to_address_point_txt"
                class="to_address_point_txt find_route"
                {% if route_form.initial.to_address_point_txt %}value="{{ route_form.initial.to_address_point_txt}}"{% endif %}/>
                <div class="abbreviation_airport_in_search"></div>
                <div class="input_list find_route" name="to_address_point_txt_list">

                </div>
        </div>
    </div>
    <div class="cont-el-form-search-carrier">
        <label for="id_departure_DT">Дата отправки</label>
{#        <input class="el_form_find_route" name="departure_DT" id="id_departure_DT" type="date" {% if route_form.fields.departure_DT.required %} {% endif %} {% if route_form.initial.departure_DT %} value="{{ route_form.initial.departure_DT }}"{% endif %} >#}
        <input class="el_form_find_route" type="text" id="id_departure_DT" name="departure_DT"  placeholder="" {% if route_form.initial.departure_DT %} value="{{ route_form.initial.departure_DT }}"{% endif %}/>
        <div id="displayRegervation"></div>
    </div>
    <div class="cont-el-form-search-carrier">
        <label for="id_arrival_DT">Дата прибытия</label>
{#        <input class="el_form_find_route" name="arrival_DT" id="id_arrival_DT" type="date" {% if route_form.initial.arrival_DT %} value="{{ route_form.initial.arrival_DT }}"{% endif %}>#}
        <input class="el_form_find_route" type="text" name="arrival_DT" id="id_arrival_DT" placeholder="" {% if route_form.initial.arrival_DT %} value="{{ route_form.initial.arrival_DT }}"{% endif %}/>
        <div id="displayRegervation"></div>
    </div>
    <div class="cont-el-form-search-carrier last">
        <label>test</label>
        <select class="custom_select el_form_find_route" name="cargo_type" id="id_cargo_type" {% if route_form.fields.cargo_type.required %} {% endif %}>
            <option value="" selected="selected">не имеет значения</option>
            {% for item in route_form.fields.cargo_type.choices %}
                <option value="{{ item.0 }}" {% if route_form.initial.cargo_type == item.0  %} selected{% endif %}>{{ item.1 }}</option>
            {% endfor %}


        </select>
    </div>
    <div class="cont-el-form-search-carrier el_form_find_route">
        <label style="opacity: 0">test</label>
        {% if show_filter_and_results %}
            <button class="btn_find_routes" onclick="filters_func_find_route_main(this,'{{ owner_type }}')" data-owner_type='{{ owner_type }}'>Найти</button>
        {% else %}
            <button class="btn_find_routes" onclick="filters_func_find_route_main(this,'{{ owner_type }}','{% url "route_search_results_View" %}')" data-owner_type='{{ owner_type }}'>Найти</button>
        {% endif %}
    </div>
</div>