Browse Source

refactor fileupload in dashboard & storage-index (#153 & #154).

I've kept the old versions commented out for now until I'm comfortable I've not
missed an obvious edge-case.
unstable
Craig Oates 8 months ago
parent
commit
a10272b28d
  1. 37
      templates/dashboard.html
  2. 38
      templates/storage-index.html

37
templates/dashboard.html

@ -21,24 +21,25 @@
</p>
</div>
<form action="/storage/multi-upload"
method="POST"
enctype="multipart/form-data">
<input required
type="hidden"
name="AUTHENTICITY-TOKEN"
value="{{token}}">
<input required
type="file"
name="STORAGE-FILES"
multiple>
<button class="be-gui-button-no-text"
title="Click to upload files to storage"
type="submit">
<img alt="Upload to Storage"
src="/images/icons/up-arrow.png">
</button>
</form>
<!-- <form action="/storage/multi-upload" -->
<!-- method="POST" -->
<!-- enctype="multipart/form-data"> -->
<!-- <input required -->
<!-- type="hidden" -->
<!-- name="AUTHENTICITY-TOKEN" -->
<!-- value="{{token}}"> -->
<!-- <input required -->
<!-- type="file" -->
<!-- name="STORAGE-FILES" -->
<!-- multiple> -->
<!-- <button class="be-gui-button-no-text" -->
<!-- title="Click to upload files to storage" -->
<!-- type="submit"> -->
<!-- <img alt="Upload to Storage" -->
<!-- src="/images/icons/up-arrow.png"> -->
<!-- </button> -->
<!-- </form> -->
{% include "layouts/storage-multiupload.html" %}
{% endif %}
<ul>

38
templates/storage-index.html

@ -3,24 +3,26 @@
{% block content %}
<h2>Storage</h2>
<form action="/storage/multi-upload"
method="POST"
enctype="multipart/form-data">
<input required
type="hidden"
name="AUTHENTICITY-TOKEN"
value="{{token}}">
<input required
type="file"
name="STORAGE-FILES"
multiple>
<button class="be-gui-button-no-text"
title="Click to upload files to storage"
type="submit">
<img alt="Upload to Storage"
src="/images/icons/up-arrow.png">
</button>
</form>
<!-- <form action="/storage/multi-upload" -->
<!-- method="POST" -->
<!-- enctype="multipart/form-data"> -->
<!-- <input required -->
<!-- type="hidden" -->
<!-- name="AUTHENTICITY-TOKEN" -->
<!-- value="{{token}}"> -->
<!-- <input required -->
<!-- type="file" -->
<!-- name="STORAGE-FILES" -->
<!-- multiple> -->
<!-- <button class="be-gui-button-no-text" -->
<!-- title="Click to upload files to storage" -->
<!-- type="submit"> -->
<!-- <img alt="Upload to Storage" -->
<!-- src="/images/icons/up-arrow.png"> -->
<!-- </button> -->
<!-- </form> -->
{% include "layouts/storage-multiupload.html" %}
<input type="text"
id="search-filter"

Loading…
Cancel
Save