natdeanlewissoftwire
12 months ago
4 changed files with 114 additions and 52 deletions
@ -1,9 +1,7 @@
|
||||
<div class="app-data-box__pair"> |
||||
<div class="app-data-box__upper"> |
||||
<div class="app-data-box__count"><%= in_progress_count(@current_user, type) %></div> |
||||
<a><%= govuk_link_to in_progress_subheading(@current_user, type), in_progress_path(type), class: "govuk-link--no-visited-state" %></a> |
||||
</div> |
||||
<div class="app-data-box__lower"> |
||||
<%= govuk_link_to "View all #{type}", clear_filter_path_for_type(type), class: "govuk-link--inverse" %> |
||||
</div> |
||||
<div class="app-data-box__upper "> |
||||
<div class="app-data-box__count"><%= data_count(@current_user, type) %></div> |
||||
<a><%= govuk_link_to data_subheading(@current_user, type), data_path(@current_user, type), class: "govuk-link--no-visited-state" %></a> |
||||
</div> |
||||
<div class="app-data-box__lower"> |
||||
<%= govuk_link_to view_all_text(type), view_all_path(type), class: "govuk-link--inverse" %> |
||||
</div> |
||||
|
@ -1,28 +1,45 @@
|
||||
<div class="govuk-grid-row"> |
||||
<div class="govuk-grid-column-two-thirds"> |
||||
<div class="govuk-!-margin-bottom-7"> |
||||
<span class="govuk-body-l"><%= "Welcome back, #{@current_user.name}" %></span> |
||||
<h1 class="govuk-heading-l"><%= heading_for_user_role(@current_user) %></h1> |
||||
</div> |
||||
<div class="govuk-grid-row"> |
||||
<% if @current_user.support? %> |
||||
<div class="govuk-grid-column-one-third"> |
||||
<span><%= render partial: "home/data_box", locals: {type: "lettings"} %></span> |
||||
</div> |
||||
<div class="govuk-grid-column-one-third"> |
||||
<span><%= render partial: "home/data_box", locals: {type: "sales"} %></span> |
||||
</div> |
||||
<div class="govuk-grid-column-one-third"> |
||||
<span><%= render partial: "home/data_box", locals: {type: "schemes"} %></span> |
||||
</div> |
||||
<% else %> |
||||
<div class="govuk-grid-column-one-half"> |
||||
<span><%= render partial: "home/data_box", locals: {type: "lettings"} %></span> |
||||
</div> |
||||
<div class="govuk-grid-column-one-half"> |
||||
<span><%= render partial: "home/data_box", locals: {type: "sales"} %></span> |
||||
</div> |
||||
<% end %> |
||||
<div class="govuk-width-container"> |
||||
<div class="govuk-grid-column-two-thirds"> |
||||
<div class="govuk-grid-row govuk-!-margin-bottom-7"> |
||||
<span class="govuk-body-l"><%= "Welcome back, #{@current_user.name}" %></span> |
||||
<h1 class="govuk-heading-l"><%= heading_for_user_role(@current_user) %></h1> |
||||
</div> |
||||
<div class="govuk-grid-row"> |
||||
<div class="app-data-box-group"> |
||||
<% if @current_user.support? || (@current_user.data_coordinator? && @current_user.sales_logs.present?)%> |
||||
<div class="app-data-box-one-third app-data-box__margin_right"> |
||||
<span><%= render partial: "home/data_box", locals: {type: "lettings"} %></span> |
||||
</div> |
||||
<div class="app-data-box-one-third app-data-box__margin_right"> |
||||
<span><%= render partial: "home/data_box", locals: {type: "sales"} %></span> |
||||
</div> |
||||
<div class="app-data-box-one-third"> |
||||
<span><%= render partial: "home/data_box", locals: {type: "schemes"} %></span> |
||||
</div> |
||||
<% else %> |
||||
<div class="app-data-box-one-half app-data-box__margin_right"> |
||||
<span><%= render partial: "home/data_box", locals: {type: "lettings"} %></span> |
||||
</div> |
||||
<% if @current_user.data_coordinator? %> |
||||
<div class="app-data-box-one-half"> |
||||
<span><%= render partial: "home/data_box", locals: {type: "schemes"} %></span> |
||||
</div> |
||||
<% elsif @current_user.sales_logs.present? %> |
||||
<div class="app-data-box-one-half"> |
||||
<span><%= render partial: "home/data_box", locals: {type: "sales"} %></span> |
||||
</div> |
||||
<% else %> |
||||
<div class="app-data-box-one-half"> |
||||
<span><%= render partial: "home/data_box", locals: {type: "misc"} %></span> |
||||
</div> |
||||
<% end %> |
||||
<% end %> |
||||
</div> |
||||
</div> |
||||
<div class="govuk-grid-row"> |
||||
<hr class="govuk-section-break govuk-section-break--visible govuk-section-break--m"> |
||||
</div> |
||||
</div> |
||||
</div> |
||||
</div> |
||||
|
Loading…
Reference in new issue