BathHacked/energy-sparks

View on GitHub
app/views/admin/consent_statements/show.html.erb

Summary

Maintainability
Test Coverage
<h1>Consent Statement</h1>

<p><%= link_to 'All consent statements', admin_consent_statements_path %></p>

<h2>Title</h2>

<h3>
  <%= @consent_statement.title %>
</h3>

<% I18n.available_locales.each do |locale| %>
  <h2>Content (<%= t("languages.#{locale}") %>)</h2>
  <p>
    <% if @consent_statement.content(locale: locale).present? %>
      <%= @consent_statement.content(locale: locale)  %>
    <% else %>
      <p><em>No content given</em></p>
    <% end %>
  </p>
<% end %>