Sha256: 3efbc9677b9d8d908b88bfd03207ea991e87c042d2927114f3b3ab8a726bafa0

Contents?: true

Size: 1.78 KB

Versions: 5

Compression:

Stored size: 1.78 KB

Contents

<tr class="<%= cycle('even', 'odd') %>">
  <td class="icon">
    <%= render_icon attachment.icon_css_class %>
  </td>
  <td class="name">
    <%- if permitted_to?(:show, :attachments) -%>
    <%= link_to(
      attachment.name,
      alchemy.admin_attachment_path(attachment),
      :target => '_blank',
      :title => t('View File')
    ) %>
    <%- else -%>
    <%= attachment.name %>
    <%- end -%>
  </td>
  <td class="file_name"><%= attachment.filename %></td>
  <td class="file_type"><%= mime_to_human(attachment.content_type) %></td>
  <td class="file_size"><%= number_to_human_size(attachment.size) %></td>
  <td class="date"><%= l(attachment.created_at, :format => :short) %></td>
  <td class="tools long">
    <%- permitted_to?(:download, :attachments) do -%>
    <%= link_to(
      "",
      alchemy.download_admin_attachment_path(attachment),
      :title => t("download_file", :filename => attachment.filename),
      :class => "icon file_download"
    ) %>
    <%- end -%>
    <%- permitted_to?(:destroy, :alchemy_admin_attachments) do -%>
    <%= link_to_confirmation_window(
      "",
      t("confirm_to_delete_file"),
      alchemy.admin_attachment_path(
        :id => attachment,
        :query => params[:query],
        :page => params[:page],
        :per_page => params[:per_page]
      ),
      {
        :class => 'icon file_delete',
        :title => t('delete_file')
      }
    ) -%>
    <%- end -%>
    <%- permitted_to?(:edit, :alchemy_admin_attachments) do -%>
    <%= link_to_overlay_window("",
      alchemy.edit_admin_attachment_path(attachment, :query => params[:query], :page => params[:page]),
      {
        :title => t('rename_file'),
        :size => '410x180'
      },
      :class => 'icon file_edit',
      :title => t('rename_file')
    ) -%>
    <%- end -%>
  </td>
</tr>

Version data entries

5 entries across 5 versions & 1 rubygems

Version Path
alchemy_cms-2.3.2 app/views/alchemy/admin/attachments/_attachment.html.erb
alchemy_cms-2.3.1 app/views/alchemy/admin/attachments/_attachment.html.erb
alchemy_cms-2.4.beta2 app/views/alchemy/admin/attachments/_attachment.html.erb
alchemy_cms-2.3.0 app/views/alchemy/admin/attachments/_attachment.html.erb
alchemy_cms-2.3.rc5 app/views/alchemy/admin/attachments/_attachment.html.erb