Sha256: 70966f693aa816191caab98a2479e55a732eecdfb70bd1cba927d16c1b59a4d7

Contents?: true

Size: 1.38 KB

Versions: 3

Compression:

Stored size: 1.38 KB

Contents

<%= render 'backend/breadcrumbs' %>
<%= render 'filter' %>

<p class="text-right">
  <%= link_to icon(:plus, t('b.add')), new_backend_asset_path, class: 'btn btn-primary btn-sm' %>
</p>

<% if @assets.any? %>
  <table class="table table-striped table-hover">
    <thead class="thead-inverse">
      <tr>
        <th><%= t 'b.file' %></th>
        <th><%= t 'b.type' %></th>
        <th><%= t 'b.size' %></th>
        <th><%= t 'b.description' %></th>
        <th><%= t 'b.last_changed_at' %></th>
        <th>&nbsp;</th>
      </tr>
    </thead>

    <tbody>
      <% @assets.each do |a| %>
        <tr>
          <td>
            <% if a.image? %>
              <%= image_tag a.image.url(150, 150), alt: '', class: 'img-fluid' %>
            <% else %>
              <%= link_to icon(:download, t('b.download')), a.filename.url %>
            <% end %>
          </td>
          <td><%= a.actual_filename.split('.').last.upcase %></td>
          <td><%= number_to_human_size a.filesize %></td>
          <td><%= simple_format a.description %></td>
          <td><%= l a.updated_at, format: :short %></td>
          <td class="text-right">
            <%= link_to_edit [:backend, a] %>
            <%= link_to_delete [:backend, a] if a.deletable? %>
          </td>
        </tr>
      <% end %>
    </tbody>
  </table>

  <%= udongo_paginate @assets %>

<% else %>
  <p><%= t 'b.msg.no_items' %></p>
<% end %>

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
udongo-6.2.1 app/views/backend/assets/index.html.erb
udongo-6.2.0 app/views/backend/assets/index.html.erb
udongo-6.1.0 app/views/backend/assets/index.html.erb