Skip to content

Commit

Permalink
Added link and icon to asset form
Browse files Browse the repository at this point in the history
  • Loading branch information
Tim Glen committed May 23, 2014
1 parent b9b8615 commit 6c1e34e
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion app/views/smithy/assets/_form.html.erb
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,13 @@
<%= f.input :retained_file, :as => :hidden %>
<% if @asset.file %>
<div>
<img src="<%= @asset.file.thumb("300x300").url %>" alt="">
<%= link_to asset.file.remote_url do %>
<% if asset.file_type == :image %>
<img src="<%= @asset.file.thumb("300x300").url %>" alt="">
<% else %>
<%= image_tag file_type_icon(asset), alt: '' %>
<% end %>
<% end %>
</div>
<% end %>
<% end %>
Expand Down

0 comments on commit 6c1e34e

Please sign in to comment.