{% extends 'base.html' %}
{% block title %}修改密码{% endblock %}
{% block content %}
<div class="row justify-content-center">
  <div class="col-md-6">
    <h3 class="mb-3">修改密码</h3>
    <form method="post">
      {% csrf_token %}
      <div class="mb-3">
        <label class="form-label">当前密码</label>
        {{ form.old_password }}
      </div>
      <div class="mb-3">
        <label class="form-label">新密码</label>
        {{ form.new_password1 }}
      </div>
      <div class="mb-3">
        <label class="form-label">确认新密码</label>
        {{ form.new_password2 }}
      </div>
      <button class="btn btn-primary" type="submit">保存</button>
      <a class="btn btn-outline-secondary ms-2" href="{% url 'accounts:profile' %}">返回用户中心</a>
    </form>
  </div>
</div>
{% endblock %}