Commit 2a8a636d authored by Robin Sonnabend's avatar Robin Sonnabend
Browse files

Small fixes for using start_time

parent d5efed83
...@@ -484,7 +484,6 @@ def new_protocol(): ...@@ -484,7 +484,6 @@ def new_protocol():
flash("Dir fehlen die nötigen Zugriffsrechte.", "alert-error") flash("Dir fehlen die nötigen Zugriffsrechte.", "alert-error")
return redirect(request.args.get("next") or url_for("index")) return redirect(request.args.get("next") or url_for("index"))
protocol = Protocol(protocoltype_id=protocoltype.id) protocol = Protocol(protocoltype_id=protocoltype.id)
print(form.start_time.data)
form.populate_obj(protocol) form.populate_obj(protocol)
if form.start_time.data is None: if form.start_time.data is None:
protocol.start_time = protocoltype.usual_time protocol.start_time = protocoltype.usual_time
......
...@@ -82,7 +82,7 @@ ...@@ -82,7 +82,7 @@
{% endif %} {% endif %}
{% else %} {% else %}
{% if protocol.date is not none %} {% if protocol.date is not none %}
<p><strong>Geplant:</strong> {{protocol.date|datify_long}}, {{protocol.start_time|timify}}</p> <p><strong>Geplant:</strong> {{protocol.date|datify_long}}, {{protocol.get_time()|timify}}</p>
{% endif %} {% endif %}
{% for meta in protocol.metas %} {% for meta in protocol.metas %}
<p><strong>{{meta.name}}:</strong> {{meta.value}}</p> <p><strong>{{meta.name}}:</strong> {{meta.value}}</p>
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment