|
1 | 1 | {% extends 'master.html' %}
|
2 |
| -{% load i18n l10n link_tags file_tags button_tags utils icon_tags form_tags %} |
| 2 | +{% load i18n l10n form_tags %} |
| 3 | + |
| 4 | +{% block extra_head %} |
| 5 | + {{form.media}} |
| 6 | +{% endblock %} |
3 | 7 |
|
4 | 8 | {% block content %}
|
5 |
| -<h1 class="h1" id="title"> |
6 |
| - {% trans "Profiel bewerken" %} |
7 |
| -</h1> |
| 9 | + <h1 class="h1" id="title"> |
| 10 | + {% trans "Profiel bewerken" %} |
| 11 | + </h1> |
| 12 | + |
| 13 | + {% render_form id="profile-edit" method="POST" form=form form_action=form_action enctype="multipart/form-data" %} |
| 14 | + {% csrf_token %} |
| 15 | + |
| 16 | + {% with request.user as user %} |
| 17 | + {% if user.is_digid_and_brp %} |
| 18 | + {% input form.display_name %} |
| 19 | + {% input form.email %} |
| 20 | + {% input form.phonenumber %} |
| 21 | + {% if user.contact_type == "begeleider" %} |
| 22 | + {% input form.image no_help=True %} |
| 23 | + {% image_crop form.cropping %} |
| 24 | + {% endif %} |
| 25 | + {% else %} |
| 26 | + {% input form.first_name %} |
| 27 | + {% input form.last_name %} |
| 28 | + {% input form.display_name %} |
| 29 | + {% input form.email %} |
| 30 | + {% input form.phonenumber %} |
| 31 | + {% date_field form.birthday no_help=True %} |
| 32 | + {% input form.street %} |
| 33 | + {% input form.housenumber %} |
| 34 | + {% input form.postcode %} |
| 35 | + {% input form.city %} |
| 36 | + {% if user.contact_type == "begeleider" %} |
| 37 | + {% input form.image no_help=True %} |
| 38 | + {% image_crop form.cropping %} |
| 39 | + {% endif %} |
| 40 | + {% endif %} |
| 41 | + {% endwith %} |
| 42 | + {% form_actions primary_text=_("Opslaan") primary_icon="arrow_forward" secondary_href='accounts:my_profile' secondary_text=_('Terug') secondary_icon='arrow_backward' secondary_icon_position="before" enctype="multipart/form-data" %} |
| 43 | + {% endrender_form %} |
8 | 44 |
|
9 |
| -{% form form_object=form method="POST" id="profile-edit" submit_text=_("Opslaan") secondary_href='accounts:my_profile' secondary_text=_('Terug') secondary_icon='arrow_backward' secondary_icon_position="before" enctype="multipart/form-data" %} |
10 | 45 | {% endblock content %}
|
0 commit comments