uploads: autorefresh /uploads/:id page if upload is still processing.

Fixes an issue where if you were uploading a multi-image source, and you
clicked on a thumbnail that was still processing, then the page wouldn't
refresh when the processing was complete.
This commit is contained in:
evazion
2022-02-16 01:18:37 -06:00
parent 9a5a04d74e
commit 70f8d3d0c0
2 changed files with 9 additions and 3 deletions

View File

@@ -6,6 +6,10 @@
<p>Error: <%= @upload.error %>.</p>
<% elsif @upload.media_asset_count == 0 %>
<p>Processing upload...</p>
<% content_for(:html_header) do %>
<meta http-equiv="refresh" content="1">
<% end %>
<% elsif @upload.media_asset_count > 1 %>
<div id="p-multiple-asset-upload">
<%= render "multiple_asset_upload", upload: @upload %>