Browse Source

feat: add new design to scheme page

pull/1003/head
natdeanlewissoftwire 4 years ago
parent
commit
c714a03b4b
  1. 18
      app/views/schemes/_scheme_list.html.erb

18
app/views/schemes/_scheme_list.html.erb

@ -5,31 +5,31 @@
<% end %> <% end %>
<%= table.head do |head| %> <%= table.head do |head| %>
<%= head.row do |row| %> <%= head.row do |row| %>
<% row.cell(header: true, text: "Code", html_attributes: {
scope: "col",
}) %>
<% row.cell(header: true, text: "Scheme", html_attributes: { <% row.cell(header: true, text: "Scheme", html_attributes: {
scope: "col", scope: "col",
}) %> }) %>
<% row.cell(header: true, text: "Locations", html_attributes: { <% row.cell(header: true, text: "Code", html_attributes: {
scope: "col", scope: "col",
}) %> }) %>
<% row.cell(header: true, text: "Support provided by", html_attributes: { <% row.cell(header: true, text: "Locations", html_attributes: {
scope: "col", scope: "col",
}) %> }) %>
<% row.cell(header: true, text: "Created", html_attributes: { <% if FeatureToggle.scheme_toggle_enabled? %>
<% row.cell(header: true, text: "Status", html_attributes: {
scope: "col", scope: "col",
}) %> }) %>
<% end %> <% end %>
<% end %> <% end %>
<% end %>
<% @schemes.each do |scheme| %> <% @schemes.each do |scheme| %>
<%= table.body do |body| %> <%= table.body do |body| %>
<%= body.row do |row| %> <%= body.row do |row| %>
<% row.cell(text: scheme.id_to_display) %>
<% row.cell(text: simple_format(scheme_cell(scheme), { class: "govuk-!-font-weight-bold" }, wrapper_tag: "div")) %> <% row.cell(text: simple_format(scheme_cell(scheme), { class: "govuk-!-font-weight-bold" }, wrapper_tag: "div")) %>
<% row.cell(text: scheme.id_to_display) %>
<% row.cell(text: scheme.locations&.count) %> <% row.cell(text: scheme.locations&.count) %>
<% row.cell(text: scheme.managing_organisation&.name) %> <% if FeatureToggle.scheme_toggle_enabled? %>
<% row.cell(text: scheme.confirmed? ? scheme.created_at.to_formatted_s(:govuk_date) : govuk_tag(colour: "grey", text: "Incomplete")) %> <% row.cell(text: status_tag(scheme.status)) %>
<% end %>
<% end %> <% end %>
<% end %> <% end %>
<% end %> <% end %>

Loading…
Cancel
Save