{% extends 'profil/profil_base.html' %}
{% load static %}

{% block title %} Modifier la photo{% endblock title %}

{% block profil_content %}
<div class="row">
    <div class="col-lg-12"><br/>
        <h3><i class="bi bi-camera-fill"></i> Modifier la photo de profil</h3><hr/>
    </div>
</div>
<div class="row col-lg-10">
    <div class="row">
        <div class="col-lg-4 profil-sidebar">
            {% if member.photo %}
                <img src="/media/{{ member.photo }}" alt="">
            {% else %}
                <img src="{% static 'assets/img/user-default2.png' %}" alt="">
            {% endif %}
        </div>
        <div class="col-lg-8"><br/>
            <center>{% include 'parts/message.html' %}</center><br/>
            <form action="{% url 'photo_update' %}" method="post" enctype="multipart/form-data">
              {% csrf_token %}
              <input type="file" name="photo" value="{{ member.photo }}">
              <button type="submit" class="btn btn-primary mt-3">Modifier</button>
            </form>
        <br/>
    </div>


</div>
{% endblock profil_content %}