scinote-web/app/views/results/_result_asset.html.erb
Matej Zrimšek e3a7f45fdf Merge branch 'master' into mz_file_upload_and_client_side_upgrade
Conflicts:
	app/assets/javascripts/application.js
	app/views/results/_result_asset.html.erb
	app/views/steps/_step.html.erb
2016-08-26 11:13:40 +02:00

9 lines
447 B
Text

<% if can_view_or_download_result_assets(result.my_module) %>
<%= link_to download_asset_path(result.asset), data: {no_turbolink: true} do %>
<%= image_tag(preview_asset_path result.asset) if result.asset.is_image? %>
<p><%= truncate(result.asset.file_file_name, length: 50) %></p>
<% end %>
<% else %>
<%= image_tag(preview_asset_path result.asset) if result.asset.is_image? %>
<p><%= result.asset.file_file_name %></p>
<% end %>