{% load static %}

<div class="block_inf_profile">
    <div class="f-l width-50">
        <div class="upload_photo_container">
            <img class="avatar_user_profile" {% if user.user_profile.avatar %}
            src="{{ user.user_profile.avatar.url }}"
            {% else %}src="{% static "img/svg/User.svg" %}"{% endif %} >
            <input type="file" onchange="upload_photo_f_profile(this)" class="btn_f_upload_photo" id="id_btn_f_upload_photo">
            <label class="upload_photo_label" for="id_btn_f_upload_photo">Загрузить фото</label>
        </div>
        <div class="clear_both"></div>
    </div>
    <div class="f-r width-50">
        <div class="f-r">
            <div class="cur_subscribe_label">Текущая подписка:</div>
            <div class="cur_subscribe_f_profile">{{ user_subscribe.subscribe.name }}</div>
            <div class="btn_go_to_subscribes pointer" onclick="select_tab_profile(this,'show_cur_subscribe')">Перейти к подпискам</div>
        </div>
        <div class="clear_both"></div>
    </div>
    <div class="clear_both"></div>
</div>
<form name="form_user_data">
    <div class="container_form_profile">
        <div class="container_el_form_profile">
            <label class="label_f_profile" for="name">{% if profileForm.fields.firstname.required %}<span class="orange-text">*</span>{% endif %} Ваше имя</label>
            <input class="input_f_profile" type="text" id="id_firstname" name="firstname" {% if profileForm.initial.firstname %}value="{{ profileForm.initial.firstname }}" {% endif %}  {% if profileForm.initial.firstname %}data-initial-value="{{ profileForm.initial.firstname }}"{% else %}data-initial-value=""{% endif %} >
            {% if profileForm.errors.firstname %}<div class="error_form_profile">{{ profileForm.errors.firstname }}</div>{% endif %}
        </div>
        <div class="container_el_form_profile">
            <label class="label_f_profile" for="id_lastname">{% if profileForm.fields.lastname.required %}<span class="orange-text">*</span>{% endif %} Ваша фамилия</label>
            <input class="input_f_profile" type="text" id="id_lastname" name="lastname" {% if profileForm.initial.lastname %}value="{{ profileForm.initial.lastname }}" {% endif %} {% if profileForm.initial.lastname %}data-initial-value="{{ profileForm.initial.lastname }}"{% else %}data-initial-value=""{% endif %}>
        {% if profileForm.errors.lastname %}<div class="error_form_profile">{{ profileForm.errors.lastname }}</div>{% endif %}
        </div>
        <div class="container_el_form_profile">
            <label class="label_f_profile" for="id_tel">{% if profileForm.fields.tel.required %}<span class="orange-text">*</span>{% endif %} Номер телефона</label>
            <input class="input_f_profile" type="text" id="id_tel" name="tel" {% if profileForm.initial.tel %}value="{{ profileForm.initial.tel }}" {% endif %} {% if profileForm.initial.tel %}data-initial-value="{{ profileForm.initial.tel }}"{% else %}data-initial-value=""{% endif %}>
            {% if profileForm.errors.tel %}<div class="error_form_profile">{{ profileForm.errors.tel }}</div>{% endif %}
        </div>
        <div class="container_el_form_profile">
            <label class="label_f_profile" for="id_email">{% if profileForm.fields.email.required %}<span class="orange-text">*</span>{% endif %} Е-mail</label>
            <input class="input_f_profile" type="text" id="id_email" name="email" {% if profileForm.initial.email %}value="{{ profileForm.initial.email }}" {% endif %} {% if profileForm.initial.email %}data-initial-value="{{ profileForm.initial.email }}"{% else %}data-initial-value=""{% endif %}>
            {% if profileForm.errors.email %}<div class="error_form_profile">{{ profileForm.errors.email }}</div>{% endif %}
        </div>
        <div class="container_el_form_profile">
            <label class="label_f_profile" for="id_country">{% if profileForm.fields.country.required %}<span class="orange-text">*</span>{% endif %} Страна проживания</label>
            <input class="input_f_profile" type="text" id="id_country" name="country" {% if profileForm.initial.country %}value="{{ profileForm.initial.country }}" {% endif %} {% if profileForm.initial.country %}data-initial-value="{{ profileForm.initial.country }}"{% else %}data-initial-value=""{% endif %}>
            {% if profileForm.errors.country %}<div class="error_form_profile">{{ profileForm.errors.country }}</div>{% endif %}
        </div>
        <div class="container_el_form_profile">
            <label class="label_f_profile" for="id_city">{% if profileForm.fields.city.required %}<span class="orange-text">*</span>{% endif %} Город проживаня</label>
            <input class="input_f_profile" type="text" id="id_city" name="city" {% if profileForm.initial.city %}value="{{ profileForm.initial.city }}" {% endif %} {% if profileForm.initial.city %}data-initial-value="{{ profileForm.initial.city }}"{% else %}data-initial-value=""{% endif %}>
            {% if profileForm.errors.city %}<div class="error_form_profile">{{ profileForm.errors.city }}</div>{% endif %}
        </div>

        <div class="line_f_form_profile"></div>

        <div class="container_el_form_profile">
            <label class="label_f_profile" for="id_password">{% if profileForm.fields.password.required %}<span class="orange-text">*</span>{% endif %} Новый пароль</label>
            <input class="input_f_profile" type="text" id="id_password" name="password" {% if profileForm.initial.password %}value="{{ profileForm.initial.password }}" {% endif %} {% if profileForm.initial.password %}data-initial-value="{{ profileForm.initial.password }}"{% else %}data-initial-value=""{% endif %}>
        </div>
        <div class="container_el_form_profile">
            <label class="label_f_profile" for="id_confirm_password">{% if profileForm.fields.confirm_password.required %}<span class="orange-text">*</span>{% endif %} Подвердить пароль</label>
            <input class="input_f_profile" type="text" id="id_confirm_password" name="confirm_password" {% if profileForm.initial.confirm_password %}value="{{ profileForm.initial.confirm_password }}" {% endif %} {% if profileForm.initial.confirm_password %}data-initial-value="{{ profileForm.initial.confirm_password }}"{% else %}data-initial-value=""{% endif %}>
        </div>
        <button class="confirm_profile_btn" onclick="change_profile_confirm(this)">Сохарнить</button>

    </div>
</form>