2015-09-17 20:26:06 +00:00
|
|
|
{{ define "content" }}{{ $path := .Path }}
|
2015-09-17 16:41:31 +00:00
|
|
|
|
2016-01-31 22:14:17 +00:00
|
|
|
<div class="container">
|
|
|
|
<h1>{{ $path }}</h1>
|
2015-09-18 18:12:47 +00:00
|
|
|
|
|
|
|
<main class="browse">
|
2015-09-19 21:17:38 +00:00
|
|
|
<div class="actions">
|
|
|
|
<div class="container">
|
2015-09-20 20:03:18 +00:00
|
|
|
{{if .CanGoUp}}<a data-pjax href=".." class="up" title="Up one level"><i class="fa fa-arrow-left fa-lg"></i></a>{{end}}
|
2015-09-19 21:17:38 +00:00
|
|
|
<div class="go-right">
|
2015-09-26 11:34:53 +00:00
|
|
|
<input type="file" value="Upload" multiple>
|
2015-09-19 21:17:38 +00:00
|
|
|
<button id="upload">Upload <i class="fa fa-cloud-upload"></i></button>
|
2016-01-31 22:14:17 +00:00
|
|
|
<button class="default new">New +</button>
|
2015-09-20 13:43:41 +00:00
|
|
|
<div id="new-file">
|
2015-10-18 17:28:51 +00:00
|
|
|
Write the name of the new file. If you want to use an archetype, add ':archetype' in the end, replacing 'archetype' by its name.
|
2015-09-20 13:43:41 +00:00
|
|
|
<input id="new-file-name" type="text">
|
|
|
|
</div>
|
2015-09-19 21:17:38 +00:00
|
|
|
</div>
|
2015-09-18 18:12:47 +00:00
|
|
|
</div>
|
2015-09-19 21:17:38 +00:00
|
|
|
</div>
|
2015-09-17 16:41:31 +00:00
|
|
|
|
2016-01-31 22:14:17 +00:00
|
|
|
<table>
|
|
|
|
<tr>
|
|
|
|
<th class="left">
|
|
|
|
{{if and (eq .Sort "name") (ne .Order "desc")}}
|
|
|
|
<a data-pjax href="?sort=name&order=desc">Name <i class="fa fa-arrow-up"></i></a> {{else if and (eq .Sort "name") (ne .Order "asc")}}
|
|
|
|
<a data-pjax href="?sort=name&order=asc">Name <i class="fa fa-arrow-down"></i></a> {{else}}
|
|
|
|
<a data-pjax href="?sort=name&order=asc">Name</a> {{end}}
|
|
|
|
</th>
|
|
|
|
<th class="right hideable">
|
|
|
|
{{if and (eq .Sort "size") (ne .Order "desc")}}
|
|
|
|
<a data-pjax href="?sort=size&order=desc">Size <i class="fa fa-arrow-up"></i></a> {{else if and (eq .Sort "size") (ne .Order "asc")}}
|
|
|
|
<a data-pjax href="?sort=size&order=asc">Size <i class="fa fa-arrow-down"></i></a> {{else}}
|
|
|
|
<a data-pjax href="?sort=size&order=asc">Size</a> {{end}}
|
|
|
|
</th>
|
|
|
|
<th class="hideable right">
|
|
|
|
{{if and (eq .Sort "time") (ne .Order "desc")}}
|
|
|
|
<a href="?sort=time&order=desc">Modified <i class="fa fa-arrow-up"></i></a> {{else if and (eq .Sort "time") (ne .Order "asc")}}
|
|
|
|
<a href="?sort=time&order=asc">Modified <i class="fa fa-arrow-down"></i></a> {{else}}
|
|
|
|
<a href="?sort=time&order=asc">Modified</a> {{end}}
|
|
|
|
</th>
|
|
|
|
<th class="right"></th>
|
|
|
|
<th class="right"></th>
|
|
|
|
</tr>
|
|
|
|
{{range .Items}}
|
|
|
|
<tr>
|
|
|
|
<td>
|
|
|
|
{{if .IsDir}}
|
|
|
|
<i class="fa fa-folder"></i> <a data-pjax href="{{.URL}}">{{.Name}}</a> {{else}} {{ if CanBeEdited .URL }}
|
|
|
|
<i class="fa fa-file"></i> <a data-pjax class="file" href="/admin/edit{{ $path }}{{.URL}}">{{.Name}}</a> {{ else }}
|
|
|
|
<i class="fa fa-file"></i> {{.Name}} {{ end }} {{ end }}
|
|
|
|
</td>
|
|
|
|
<td class="right hideable">{{.HumanSize}}</td>
|
|
|
|
<td class="right hideable">{{.HumanModTime "01/02/2006 3:04:05 PM"}}</td>
|
|
|
|
<td class="right"><button data-file="/admin/browse{{ $path }}{{.URL}}" data-message="File renamed." class="rename">✎</button></td>
|
|
|
|
<td class="right"><button data-file="/admin/browse{{ $path }}{{.URL}}" data-message="File deleted." class="delete">✖</button></td>
|
|
|
|
</tr>
|
|
|
|
{{end}}
|
|
|
|
</table>
|
2015-09-18 18:12:47 +00:00
|
|
|
</main>
|
|
|
|
</div>
|
2015-09-15 20:47:12 +00:00
|
|
|
{{ end }}
|