Index: sitescripts/stats/template/fileStats.html |
=================================================================== |
--- a/sitescripts/stats/template/fileStats.html |
+++ b/sitescripts/stats/template/fileStats.html |
@@ -119,17 +119,23 @@ |
{%- if not field.filter and not field.hidden and field.name in data %} |
<a href="#{{field.name}}">{{field.title}}</a> |
{%- endif %} |
{%- endfor %} |
</div> |
{%- if filterFields|length > 0 %} |
{%- if filter %} |
- {%- set params = {"totalhits": data.hits, "totalbandwidth": data.bandwidth, "field": {"name": None}} %} |
+ {%- |
+ set params = { |
+ "totalhits": data.hits if data.hits != 0 else 1, |
Sebastian Noack
2014/11/12 20:13:58
If there are no hits there aren't any. IMO, preten
Wladimir Palant
2014/11/12 20:56:36
Yes, you reviewed that workaround for other occasi
|
+ "totalbandwidth": data.bandwidth if data.bandwidth != 0 else 1, |
+ "field": {"name": None} |
+ } |
+ %} |
{%- else %} |
{%- set items = data.day|sortfield("day") %} |
{%- set params = {"totalhits": items|sumhits, "totalbandwidth": items|sumbandwidth, "field": {"name": None}} %} |
{%- endif %} |
<div id="overview" class="block_title">Overview</div> |
<div class="block"> |
<table align="center"> |
<tr> |