X-Git-Url: https://git.rapsys.eu/airbundle/blobdiff_plain/9ea61d2e082e341a554fea43e22f25f7f09bfdd1..22ab06ae0ac4b9be42a4b9203341ed17b42d70d6:/Resources/views/form/edit.html.twig?ds=inline

diff --git a/Resources/views/form/edit.html.twig b/Resources/views/form/edit.html.twig
index 8540c46..390ba1f 100644
--- a/Resources/views/form/edit.html.twig
+++ b/Resources/views/form/edit.html.twig
@@ -1,8 +1,10 @@
 {% extends '@RapsysAir/body.html.twig' %}
 {% block title %}{{ site.title }} - {{ title }}{% endblock %}
 {% block content %}
-	<section id="form">
-		<h2><a href="{{ path('rapsys_user_edit', {'mail': app.user.mail|short, 'hash': app.user.mail|short|hash}) }}">{{ title }}</a></h2>
+	<article>
+		<header>
+			<h2><a href="{{ app.request.requesturi }}">{{ title }}</a></h2>
+		</header>
 		{{ form_start(edit) }}
 			<div>
 				{% if edit.mail is defined %}
@@ -25,20 +27,42 @@
 					{{ form_row(edit.pseudonym) }}
 				{% endif %}
 
+				{% if edit.zipcode is defined %}
+					{{ form_row(edit.zipcode) }}
+				{% endif %}
+
+				{% if edit.city is defined %}
+					{{ form_row(edit.city) }}
+				{% endif %}
+
+				{% if edit.country is defined %}
+					{{ form_row(edit.country) }}
+				{% endif %}
+
 				{% if edit.phone is defined %}
 					{{ form_row(edit.phone) }}
 				{% endif %}
 
+				{% if edit.dances is defined %}
+					{{ form_row(edit.dances) }}
+				{% endif %}
+
+				{% if edit.subscriptions is defined %}
+					{{ form_row(edit.subscriptions) }}
+				{% endif %}
+
 				{{ form_row(edit.submit) }}
 			</div>
 
 			{# Render CSRF token etc .#}
 			<footer style="display:none">{{ form_rest(edit) }}</footer>
 		{{ form_end(edit) }}
-	</section>
+	</article>
 	{% if reset is defined %}
-		<section id="form">
-			<h2><a href="{{ path('rapsys_user_register') }}">{{ password }}</a></h2>
+		<article>
+			<header>
+				<h2><a href="{{ app.request.requesturi }}">{{ password }}</a></h2>
+			</header>
 			{{ form_start(reset) }}
 				<div>
 					{% if reset.password is defined %}
@@ -53,6 +77,66 @@
 				{# Render CSRF token etc .#}
 				<footer style="display:none">{{ form_rest(reset) }}</footer>
 			{{ form_end(reset) }}
-		</section>
+		</article>
+	{% endif %}
+	{% if calendar is defined %}
+		<article>
+			<header>
+				<h2><a href="{{ app.request.requesturi }}">{% trans %}Calendar{% endtrans %}</a></h2>
+			</header>
+			{% if calendar.link is defined %}
+				<section>
+					<header>
+						<h3>{% trans %}Add{% endtrans %}</h3>
+					</header>
+					<div>
+						<a class="center" href="{{ calendar.link }}"><img src="{{ asset(calendar.logo.svg) }}?20221024100144" srcset="{{ asset(calendar.logo.png) }}?20221024100144 200w, {{ asset(calendar.logo.svg) }}?20221024100144 400w" sizes="(min-width:400px) 400px, 200px" alt="{% trans %}Google Calendar logo{% endtrans %}" width="50" height="50" /><span>{% trans %}Link a Google Calendar account{% endtrans %}</span></a>
+					</div>
+				</section>
+			{% endif %}
+			{% if calendar.form is defined %}
+				{% for mail, form in calendar.form %}
+					<section>
+						<header>
+							<h3>{{ mail|ucfirst }}</h3>
+						</header>
+						{{ form_start(form) }}
+							<div>
+								{{ form_widget(form.calendar) }}
+
+								<div class="row">
+									{{ form_widget(form.submit) }}
+
+									{% if form.refresh is defined %}
+										{{ form_widget(form.refresh) }}
+									{% endif %}
+
+									{% if form.add is defined %}
+										{{ form_widget(form.add) }}
+									{% endif %}
+
+									{% if form.delete is defined %}
+										{{ form_widget(form.delete) }}
+									{% endif %}
+
+									{% if form.unlink is defined %}
+										{{ form_widget(form.unlink) }}
+									{% endif %}
+								</div>
+							</div>
+
+							{# Render CSRF token etc .#}
+							<footer style="display:none">{{ form_rest(form) }}</footer>
+						{{ form_end(form) }}
+					</section>
+				{% endfor %}
+			{% endif %}
+		</article>
 	{% endif %}
+	<article>
+		<header>
+			<h2><a href="{{ app.request.requesturi }}">{% trans %}Newsletter{% endtrans %}</a></h2>
+		</header>
+		<p class="center"><span>TODO: add newsletter stuff here ?</span></p>
+	</article>
 {% endblock %}