Skip to content

Instantly share code, notes, and snippets.

@cfitz
Created November 18, 2010 20:06
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save cfitz/705521 to your computer and use it in GitHub Desktop.
Save cfitz/705521 to your computer and use it in GitHub Desktop.
_index.html.erb
<tr class="document" class="<%= cycle("even","odd") %>">
<td>
<%= link_to_document(document, :label => Blacklight.config[:show][:heading].to_sym, :counter => (counter + 1 + @response.params[:start].to_i)) %>
</td>
<td>
<% creator = get_person_from_role(document, "Creator") %>
<%= [creator[:last], creator[:first]].join(", ") unless creator.nil? %>
</td>
<td>
<%= DateTime.parse(document.get(:system_create_dt)).to_time %>
</td>
<td>
<%= (document.get(:medium_t) || document_type(document)).gsub("Hydrangea","") %>
</td>
<td>
<%= document[:has_collection_member_s] ? document[:has_collection_member_s].length : 0 %>
</td>
<td>
Created
</td>
</tr>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment