<%= record.title %>
<%= record.first %>
<%= record.last %>
<% record.addresses.each do |address| %>
<%== render partial: "address", locals: {address: address} %>
<% end %>
<% record.telecoms.each do |tele| %>
<%== render partial: "telecom", locals: {telecom: tele} %>
<% end %>
<%= time_if_not_nil(record.birthdate) %>
<% if record.deathdate %>
<%= time_if_not_nil(record.deathdate) %>
<% end %>
<% if record.marital_status && record.marital_status[:code] %>
<% end %>
<% if record.religious_affiliation && record.religious_affiliation[:code] %>
<% end %>
<% if record.race && record.race[:code] %>
<% end %>
<% if record.ethnicity && record.race[:code] %>
<% end %>
<% record.languages.each do |l| %>
<%=l%>
<% end%>
<% record.allergies.each do |a| %>
<%== render partial: "allergy", locals: {allergy: a} %>
<% end %>
<% record.conditions.each do |c| %>
<%== render partial: "condition", locals: {condition: c} %>
<% end %>
<% record.encounters.each do |e| %>
<%== render partial: 'encounter', locals: {encounter: e} %>
<% end %>
<% record.immunizations.each do |i| %>
<%== render partial: "immunization", locals: {immunization: i} %>
<% end %>
<% record.insurance_providers.each do |ip| %>
<%== render partial: "insurance_provider", locals: {insurance_provider: ip} %>
<% end %>
<% record.medical_equipment.each do |me| %>
<%== render partial: "medical_equipment", locals: {medical_equipment: me} %>
<% end %>
<% record.medications.each do |m| %>
<%== render partial: "medication", locals: {medication: m} %>
<% end %>
<% record.procedures.each do |pr| %>
<%== render partial: "procedure", locals: {procedure: pr} %>
<% end %>
<% record.results.each do |r| %>
<%== render partial: "result", locals: {result: r} %>
<% end %>
<% record.social_history.each do |sh| %>
<%== render partial: "social_history", locals: {social_history: sh} %>
<% end %>
<% record.support.each do |s| %>
<%== render partial: "support", locals: {support: s}%>
<% end %>
<% record.vital_signs.each do |vs| %>
<%== render partial: "vital_sign", locals: {vital_sign: vs} %>
<% end %>