Don’t right align template stats for one template

We don’t show the graph if a user has only used one template.
This commit is contained in:
Chris Hill-Scott
2017-02-15 14:01:52 +00:00
parent f851da36f7
commit 6404997b93

View File

@@ -24,8 +24,8 @@
</span> </span>
</span> </span>
{% endcall %} {% endcall %}
{% call field(align='right') %} {% if template_statistics|length > 1 %}
{% if template_statistics|length > 1 %} {% call field(align='right') %}
<span id='{{item.template_id}}' class="spark-bar"> <span id='{{item.template_id}}' class="spark-bar">
<span style="width: {{ item.count / most_used_template_count * 100 }}%"> <span style="width: {{ item.count / most_used_template_count * 100 }}%">
{{ big_number( {{ big_number(
@@ -34,14 +34,16 @@
) }} ) }}
</span> </span>
</span> </span>
{% else %} {% endcall %}
{% else %}
{% call field() %}
<span id='{{item.template_id}}' class="heading-small"> <span id='{{item.template_id}}' class="heading-small">
{{ big_number( {{ big_number(
item.count, item.count,
smallest=True smallest=True
) }} ) }}
</span> </span>
{% endif %} {% endcall %}
{% endcall %} {% endif %}
{% endcall %} {% endcall %}
</div> </div>