Skip to content

Commit

Permalink
Merge pull request #171 from hudmol/40848483-notes-display
Browse files Browse the repository at this point in the history
Add Notes to the component sidebar and readonly views.

Delivers: https://www.pivotaltracker.com/story/show/40848483
  • Loading branch information
payten committed Dec 7, 2012
2 parents 49dc53f + 5861afa commit 2eaccf4
Show file tree
Hide file tree
Showing 4 changed files with 16 additions and 0 deletions.
4 changes: 4 additions & 0 deletions frontend/app/views/archival_objects/_show_inline.html.erb
Expand Up @@ -33,6 +33,10 @@
<%= render :partial => "linked_agents/show", :locals => { :linked_agents => @archival_object.linked_agents, :section_id => "archival_object_linked_agents_" } %>
<% end %>
<% if @archival_object.notes.length > 0 %>
<%= render :partial => "notes/show", :locals => { :notes => @archival_object.notes, :context => readonly } %>
<% end %>
<% if @archival_object.extents.length > 0 %>
<%= render :partial => "extents/show", :locals => { :extents => @archival_object.extents, :section_id => "archival_object_extents_" } %>
<% end %>
Expand Down
4 changes: 4 additions & 0 deletions frontend/app/views/archival_objects/_sidebar.html.erb
Expand Up @@ -5,6 +5,10 @@
<% if controller.action_name != "show" || @archival_object.linked_agents.length > 0 %>
<li><a href="#archival_object_linked_agents_">Agent Links <span class="icon-chevron-right"></span></a></li>
<% end %>
<% if not controller.action_name === "show" or @archival_object.notes.length > 0 %>
<li><a href="#notes">Notes <span class="icon-chevron-right"></span></a></li>
<% end %>
<% if controller.action_name != "show" || @archival_object.extents.length > 0 %>
<li><a href="#archival_object_extents_">Extents <span class="icon-chevron-right"></span></a></li>
Expand Down
Expand Up @@ -33,6 +33,10 @@
<% if @digital_object_component.linked_agents.length > 0 %>
<%= render :partial => "linked_agents/show", :locals => { :linked_agents => @digital_object_component.linked_agents, :section_id => "digital_object_component_linked_agents_" } %>
<% end %>
<% if @digital_object_component.notes.length > 0 %>
<%= render :partial => "notes/show", :locals => { :notes => @digital_object_component.notes, :context => readonly } %>
<% end %>
<% if @digital_object_component.extents.length > 0 %>
<%= render :partial => "extents/show", :locals => { :extents => @digital_object_component.extents, :section_id => "digital_object_component_extents_" } %>
Expand Down
Expand Up @@ -5,6 +5,10 @@
<% if controller.action_name != "show" || @digital_object_component.linked_agents.length > 0 %>
<li><a href="#digital_object_component_linked_agents_">Agent Links <span class="icon-chevron-right"></span></a></li>
<% end %>
<% if not controller.action_name === "show" or @digital_object_component.notes.length > 0 %>
<li><a href="#notes">Notes <span class="icon-chevron-right"></span></a></li>
<% end %>
<% if controller.action_name != "show" || @digital_object_component.extents.length > 0 %>
<li><a href="#digital_object_component_extents_">Extents <span class="icon-chevron-right"></span></a></li>
Expand Down

0 comments on commit 2eaccf4

Please sign in to comment.