{% extends 'base.html' %}
{% block content%}

<div class="container">
    <div class="row justify-content-center">
      <div class="col-md-6 mt-5">
        <div class="card">
          <div class="card-header bg-primary text-white">Edit Profile</div>
          <div class="card-body">
            <form method="post" action="{% url 'update-userlibrarian' %}">
              {% csrf_token %}
              <div class="mb-3">
                <label for="id_name" class="form-label">Name</label>
                <input type="text" name="name" id="id_name" value="{{ member.name }}" placeholder="Input Name" class="form-control" required>
              </div>
              <div class="mb-3">
                <label for="id_last_name" class="form-label">Last Name</label>
                <input type="text" name="last_name" id="id_last_name" placeholder="Input Last Name" class="form-control" required>
              </div>
              <div class="mb-3">
                <label for="id_address" class="form-label">Address</label>
                <textarea type="text" name="address" id="id_address" placeholder="Input Address" class="form-control" required></textarea>
              </div>
              <div class="mb-3">
                <label for="id_birth_place" class="form-label">Birth Place</label>
                <input type="text" name="birth_place" id="id_birth_place" placeholder="Input Birth Place" class="form-control" required>
              </div>
              <div class="mb-3">
                <label for="id_date_birth" class="form-label">Birth Date</label>
                <input type="date" name="date_birth" id="id_date_birth" placeholder="Input datebirth" class="form-control" required>
              </div>
              <div class="mb-3">
                <label for="id_phone_number" class="form-label">Phone Number</label>
                <input type="tel" name="phone_number" id="id_phone_number" value="{{ librarian.phone_number }}" placeholder="Phone Number" class="form-control" required>
              </div>
              <button type="submit" class="btn btn-primary" role="button">Save</button>
              <a class="btn btn-danger col-2 mx-2" href="{% url 'dashboard' %}"" role="button">Back</a>
            </form>
          </div>
        </div>
      </div>
    </div>
</div>

{% endblock content%}