Sha256: df2db5bf5477e423c542bc919854afca07bc9a8541b54a8ab7ad0a550173d969
Contents?: true
Size: 1.32 KB
Versions: 11
Compression:
Stored size: 1.32 KB
Contents
<table class="table table-condensed table-striped table-hover"> <thead> <tr> <th class="shrink user"> <%= t("admin.table_headers.username") %> </th> <th class="shrink items"> <%= t("admin.table_headers.item") %> </th> <th class="changes"> <%= t("admin.table_headers.changes") %> </th> </tr> </thead> <tbody class="table-group-divider"> <% @history.each do |t| %> <% abstract_model = RailsAdmin.config(t.table).abstract_model %> <tr> <td> <%= t.try :username %> </td> <% if o = abstract_model.try(:get, t.item) %> <% label = o.send(abstract_model.config.object_label_method) %> <% if show_action = action(:show, abstract_model, o) %> <td> <%= link_to(label, url_for(action: show_action.action_name, model_name: abstract_model.to_param, id: o.id)) %> </td> <% else %> <td> <%= label %> </td> <% end %> <% else %> <% label = Object.const_defined?(t.table) ? t.table.constantize.model_name.human : t.table %> <td> <%= "#{label} ##{t.item}" %> </td> <% end %> <td> <%= t.message %> </td> </tr> <% end %> </tbody> </table>
Version data entries
11 entries across 11 versions & 1 rubygems