* Preload organization, not user * Preload users only when needed * Pre-load podcasts for podcast episodes in API * Avoid eager loading error by loading rating votes separately * Preload associations for moderation * Preload user comments in trees * Preload organization for non org dashboard and cleanup queries * Optimize ArticleSuggester to only load N articles at need * Remove eager loading and pass variables to partials for easier debug * Reorganize tags validation code and ignore actsastaggableon eager loading issues * Remove unused eager loading and bring up comments relation * Preload podcasts when loading podcast episodes * Fix views specs * Make sure ArticleSuggester never returns duplicates * Remove commented code * Re-trigger build * Move suggested articles back to view to respect fragment caching
31 lines
1.4 KiB
Text
31 lines
1.4 KiB
Text
<% title "Edit Post" %>
|
|
|
|
<% if @article.video.present? %>
|
|
<div class="article-form-video-preview">
|
|
<% if @article.video_state == "PROGRESSING" %>
|
|
<h1 style="color:#062144;margin-top:1.1em">⏳ Video Transcoding In Progress ⏳</h1>
|
|
<img src="https://media.giphy.com/media/tXL4FHPSnVJ0A/giphy.gif" style="border-radius:12px;height:317px" alt="Bored kid incessantly tapping his fingers">
|
|
<div style="max-width:500px;margin:18px auto 0px;font-size:0.8em;">
|
|
<p>
|
|
<strong>You'll get an email when this process finishes.</strong>
|
|
</p>
|
|
<p>
|
|
<em>This is an ordinary unpublished post. Add title/tags/body/etc, and then mark as published after the video
|
|
is done processing.</em>
|
|
</p>
|
|
</div>
|
|
<% elsif @article.video_state == "COMPLETED" %>
|
|
<br /><br />
|
|
<%= render "articles/video_player", meta_tags: false, article: @article %>
|
|
<div class="article-form-video-image-url">
|
|
<%= form_for(@article) do |f| %>
|
|
Preview Image URL: <%= f.text_field :video_thumbnail_url, placeholder: "New Thumbnail URL" %>
|
|
<%= f.submit "Submit Change", class: "cta" %>
|
|
<% end %>
|
|
</div>
|
|
<% end %>
|
|
</div>
|
|
<% end %>
|
|
|
|
<%= javascript_pack_tag "articleForm", defer: true %>
|
|
<%= render "articles/v2_form", article: @article, organization: @organization, version: @version %>
|