added message for empty directories

This commit is contained in:
Gered 2013-05-26 14:02:59 -04:00
parent 40ba9e23bd
commit 6eb1141c17
2 changed files with 37 additions and 26 deletions

View file

@ -58,6 +58,11 @@ code, pre {
width: 220px;
}
div.file-list-container {
margin-top: 20px;
margin-bottom: 20px;
}
.center {
float: none;
margin-left: auto;

View file

@ -21,32 +21,38 @@
<div class="clearfix"></div>
</div>
<table class="table table-hover table-condensed">
<thead>
<tr>
<th width="440px">Filename</th>
<th width="100px">Size</th>
<th width="240px">Last Modified</th>
<th width="160px">&nbsp;</th>
</tr>
</thead>
<tbody>
{% for file in files %}
<tr>
<td>
<a href="{{context}}/files{{path}}{{file.filename}}"><i class="icon-file"></i> {{file.filename}}</a><br />
<small class="muted">{{file.content-type}}</small>
</td>
<td>{{file.size}}</td>
<td>{{file.last_modified|to_fulltime}}</td>
<td style="text-align: right;"">
<a class="btn btn-warning" data-updatefileid="{{file.id}}" href="#">Update</a>
<a class="btn btn-danger" data-deletefileid="{{file.id}}" href="#">Delete</a>
</td>
</tr>
{% endfor %}
</tbody>
</table>
<div class="file-list-container">
{% ifempty not files %}
<table class="table table-hover table-condensed">
<thead>
<tr>
<th width="440px">Filename</th>
<th width="100px">Size</th>
<th width="240px">Last Modified</th>
<th width="160px">&nbsp;</th>
</tr>
</thead>
<tbody>
{% for file in files %}
<tr>
<td>
<a href="{{context}}/files{{path}}{{file.filename}}"><i class="icon-file"></i> {{file.filename}}</a><br />
<small class="muted">{{file.content-type}}</small>
</td>
<td>{{file.size}}</td>
<td>{{file.last_modified|to_fulltime}}</td>
<td style="text-align: right;">
<a class="btn btn-warning" data-updatefileid="{{file.id}}" href="#">Update</a>
<a class="btn btn-danger" data-deletefileid="{{file.id}}" href="#">Delete</a>
</td>
</tr>
{% endfor %}
</tbody>
</table>
{% else %}
<p class="text-center">No files found.</p>
{% endifempty %}
</div>
<div id="newFileModal" class="modal hide fade" tabindex="-1" role="dialog" aria-labelledby="newFileModalLabel" aria-hidden="true">
<div class="modal-header">