roundabout,
created on Saturday, 16 March 2024, 17:55:10 (1710611710),
received on Wednesday, 31 July 2024, 06:54:42 (1722408882)
Author identity: vlad <vlad.muntoiu@gmail.com>
65dd8b1ca680772082a778c5b6001814401ab599
app.py
@@ -142,6 +142,7 @@ def settings():
user.URL = flask.request.form["url"] user.company = flask.request.form["company"] user.company_URL = flask.request.form["companyurl"] user.email = flask.request.form.get("email") if flask.request.form.get("email") else Noneuser.location = flask.request.form["location"] user.show_mail = True if flask.request.form.get("showmail") else False user.bio = flask.request.form.get("bio")
templates/user-settings.html
@@ -12,10 +12,8 @@
<section class="card-main"> <h2>{% trans %}Basic information{% endtrans %}</h2> <p>{% trans username=user.username %}Username: {{ username }}{% endtrans %}</p> <p>{% trans email=user.email %}Email address: {{ email }}{% endtrans %}</p><x-buttonbox> <a class="button" href="password">{% trans %}Change password{% endtrans %}</a> <a class="button" href="email">{% trans %}Change email{% endtrans %}</a></x-buttonbox> </section> </article>
@@ -24,6 +22,13 @@
<form method="post"> <h2>{% trans %}Profile{% endtrans %}</h2> <x-vbox> <x-vbox class="nopad"> <label for="email">{% trans %}Email address{% endtrans %}</label> <input id="email" name="email" type="email" value="{% if user.email %}{{ user.email }}{% endif %}"> </x-vbox> <x-vbox class="nopad"> <label><input name="showmail" value="showmail" {% if user.show_mail %}checked{% endif %} type="checkbox">{% trans %}Show email on my profile{% endtrans %}</label> </x-vbox><x-vbox class="nopad"> <label for="displayname">{% trans %}Friendly name{% endtrans %}</label> <input id="displayname" name="displayname" value="{% if user.display_name %}{{ user.display_name }}{% endif %}" placeholder="{{ user.username }}">
@@ -44,9 +49,6 @@
</x-vbox> </x-hbox> </x-vbox> <x-vbox class="nopad"><label><input name="showmail" value="showmail" {% if user.show_mail %}checked{% endif %} type="checkbox">{% trans %}Show email on my profile{% endtrans %}</label></x-vbox><x-vbox class="nopad"> <label for="location">{% trans %}Location{% endtrans %}</label> <input id="location" name="location" value="{% if user.location %}{{ user.location }}{% endif %}" type="text">