--- a/src/pyams_content/root/zmi/templates/dashboard.pt Thu Oct 08 13:37:39 2015 +0200
+++ b/src/pyams_content/root/zmi/templates/dashboard.pt Thu Oct 15 15:38:49 2015 +0200
@@ -1,4 +1,11 @@
-<tal:loop repeat="table view.tables">
- <tal:if condition="tuple(table.values)"
- content="structure table.render()" />
-</tal:loop>
+<tal:var define="global dashboard_length 0">
+ <tal:loop repeat="table view.tables">
+ <tal:if condition="table.values">
+ <tal:var content="structure table.render()" />
+ <tal:var define="global dashboard_length dashboard_length + len(table.values)" />
+ </tal:if>
+ </tal:loop>
+ <div tal:condition="not:dashboard_length" class="alert alert-info" i18n:translate="">
+ You are not actually concerned by any content.
+ </div>
+</tal:var>
--- a/src/pyams_content/shared/common/zmi/templates/dashboard.pt Thu Oct 08 13:37:39 2015 +0200
+++ b/src/pyams_content/shared/common/zmi/templates/dashboard.pt Thu Oct 15 15:38:49 2015 +0200
@@ -22,11 +22,16 @@
</div>
</div>
</form>
- <div id="search_results">
+ <div id="search_results" tal:define="global dashboard_length 0">
<tal:loop repeat="table view.tables">
- <tal:if condition="tuple(table.values)"
- content="structure table.render()" />
+ <tal:if condition="table.values">
+ <tal:var content="structure table.render()" />
+ <tal:var define="global dashboard_length dashboard_length + len(table.values)" />
+ </tal:if>
</tal:loop>
+ <div tal:condition="not:dashboard_length" class="alert alert-info" i18n:translate="">
+ You are not actually concerned by any content.
+ </div>
</div>
</div>
</div>