比赛功能也太难写了

This commit is contained in:
masnn committed 2020-04-12 08:59:05 +08:00
1 parent f73859a42f
commit 32ad47e031
16 files changed
+195 -176

No files matched your search

+2 -2
View File
@@ -1,8 +1,8 @@
{% import "components/user.html" as user with context %}
{% macro render_time(tdoc_time) %}
{{ datetime_span(tdoc_time, false, '%Y-%m-%d %H:%M') }}
{{ datetime_span(tdoc_time, false, '%Y-%m-%d %H:%M')|safe }}
{% endmacro %}
{% macro render_duration(tdoc) %}
{{ ((tdoc['end_at'] - tdoc['begin_at']).total_seconds() / 3600)|round(1) }}
{{ ((tdoc.endAt.getTime() - tdoc.beginAt.getTime()) /1000 / 3600)|round(1) }}
{% endmacro %}