Problems <%== render :partial => 'narrative_block', :locals => {:entries => entries, :section => 'conditions'} %> <% entries.each_with_index do |entry, i| -%> <% if entry.status.eql? 'resolved' -%> <% else -%> <% end -%> <%== code_display(entry, 'value', 'xsi:type="CD"') %> <% if entry.status -%> <% end -%> <% end -%>