Sha256: 52e2ad93fe1ea59fb32e44ce191e0a4c28186b2c55b7d2e8c6821bcafa0a3f63

Contents?: true

Size: 857 Bytes

Versions: 4

Compression:

Stored size: 857 Bytes

Contents

<% attached = (controller.action_name == 'attach' or controller.controller_name != 'assets') %>
<%= link_to_function truncate(asset.filename,{:length => 50}), "AssetBrowser.openInfo(#{asset.id}, this)" %> - <%= asset.description %>
<div>
<%= link_to_function "View Info", "AssetBrowser.openInfo(#{asset.id}, this)" %><br/>

<% if for_content or attached %>
  <%= link_to_function "Insert", "addAsset(#{asset.id})" %><br />
<% end -%>
<br/>
<% if for_content %>
  <%= link_to_function "Attach", "AssetBrowser.addAssetToContentNode(#{asset.to_json}.#{asset.class.name.demodulize.underscore})" %>
<% elsif attached %>
  <%= link_to_function "Detach", "AssetBrowser.removeAssetFromContentNode(#{asset.id})" %>
<% else %>
  <%= link_to_function "Delete", "AssetBrowser.assetAction(#{asset.to_json}.#{asset.class.name.demodulize.underscore})" %>
<% end -%>
</div>

Version data entries

4 entries across 4 versions & 1 rubygems

Version Path
beef-has_assets-0.7.6 app/views/admin/assets/_document.html.erb
beef-has_assets-0.7.5 app/views/admin/assets/_document.html.erb
beef-has_assets-0.7.4 app/views/admin/assets/_document.html.erb
beef-has_assets-0.7.3 app/views/admin/assets/_document.html.erb