|
|
@ -1,48 +1,43 @@ |
|
|
|
<div class="govuk-grid-row"> |
|
|
|
<div class="govuk-grid-row"> |
|
|
|
<div class="govuk-width-container"> |
|
|
|
<div class="govuk-width-container"> |
|
|
|
<div class="govuk-grid-column-two-thirds"> |
|
|
|
|
|
|
|
<div class="govuk-grid-row govuk-!-margin-bottom-7"> |
|
|
|
<div class="govuk-grid-row govuk-!-margin-bottom-7"> |
|
|
|
<span class="govuk-body-l"><%= "Welcome back, #{@current_user.name}" %></span> |
|
|
|
<span class="govuk-body-l"><%= "Welcome back, #{@current_user.name}" %></span> |
|
|
|
<h1 class="govuk-heading-l"><%= heading_for_user_role(@current_user) %></h1> |
|
|
|
<h1 class="govuk-heading-l"><%= heading_for_user_role(@current_user) %></h1> |
|
|
|
</div> |
|
|
|
</div> |
|
|
|
<div class="govuk-grid-row"> |
|
|
|
<div class="govuk-grid-row"> |
|
|
|
<div class="app-data-box-group"> |
|
|
|
<div class="govuk-grid-column-three-quarters-from-desktop govuk-!-padding-left-0 govuk-!-padding-right-0"> |
|
|
|
<% if @current_user.support? || (@current_user.data_coordinator? && @current_user.sales_logs.present?) %> |
|
|
|
<% if @current_user.support? || (@current_user.data_coordinator? && @current_user.sales_logs.present?) %> |
|
|
|
<div class="app-data-box-group-one-third"> |
|
|
|
<div class="govuk-grid-column-one-third govuk-!-padding-left-0"> |
|
|
|
<div class="app-data-box-one-third"> |
|
|
|
<span><%= render partial: "home/data_box", locals: { type: "lettings" } %></span> |
|
|
|
<span><%= render partial: "home/data_box", locals: { type: "lettings" } %></span> |
|
|
|
</div> |
|
|
|
|
|
|
|
<div class="govuk-grid-column-one-third govuk-!-padding-left-0"> |
|
|
|
|
|
|
|
<span><%= render partial: "home/data_box", locals: { type: "sales" } %></span> |
|
|
|
|
|
|
|
</div> |
|
|
|
|
|
|
|
<div class="govuk-grid-column-one-third govuk-!-padding-left-0"> |
|
|
|
|
|
|
|
<span><%= render partial: "home/data_box", locals: { type: "schemes" } %></span> |
|
|
|
|
|
|
|
</div> |
|
|
|
|
|
|
|
<% else %> |
|
|
|
|
|
|
|
<div class="govuk-grid-column-one-half govuk-!-padding-left-0"> |
|
|
|
|
|
|
|
<span><%= render partial: "home/data_box", locals: { type: "lettings" } %></span> |
|
|
|
|
|
|
|
</div> |
|
|
|
|
|
|
|
<% if @current_user.data_coordinator? %> |
|
|
|
|
|
|
|
<div class="govuk-grid-column-one-half govuk-!-padding-left-0"> |
|
|
|
|
|
|
|
<span><%= render partial: "home/data_box", locals: { type: "schemes" } %></span> |
|
|
|
</div> |
|
|
|
</div> |
|
|
|
<div class="app-data-box-one-third"> |
|
|
|
<% elsif @current_user.sales_logs.present? %> |
|
|
|
|
|
|
|
<div class="govuk-grid-column-one-half govuk-!-padding-left-0"> |
|
|
|
<span><%= render partial: "home/data_box", locals: { type: "sales" } %></span> |
|
|
|
<span><%= render partial: "home/data_box", locals: { type: "sales" } %></span> |
|
|
|
</div> |
|
|
|
</div> |
|
|
|
<div class="app-data-box-one-third"> |
|
|
|
<% else %> |
|
|
|
<span><%= render partial: "home/data_box", locals: { type: "schemes" } %></span> |
|
|
|
<div class="govuk-grid-column-one-half govuk-!-padding-left-0"> |
|
|
|
|
|
|
|
<span><%= render partial: "home/data_box", locals: { type: "misc" } %></span> |
|
|
|
</div> |
|
|
|
</div> |
|
|
|
</div> |
|
|
|
<% end %> |
|
|
|
<% else %> |
|
|
|
|
|
|
|
<div class="app-data-box-group-one-half"> |
|
|
|
|
|
|
|
<div class="app-data-box-one-half"> |
|
|
|
|
|
|
|
<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 %> |
|
|
|
|
|
|
|
</div> |
|
|
|
|
|
|
|
<% end %> |
|
|
|
<% end %> |
|
|
|
</div> |
|
|
|
</div> |
|
|
|
</div> |
|
|
|
</div> |
|
|
|
<div class="govuk-grid-row"> |
|
|
|
<div class="govuk-grid-row"> |
|
|
|
<div class="app-data-box__underline"> |
|
|
|
<div class="govuk-grid-column-three-quarters-from-desktop govuk-!-padding-left-0"> |
|
|
|
<hr class="govuk-section-break govuk-section-break--visible govuk-section-break--m"> |
|
|
|
<hr class="govuk-section-break govuk-section-break--visible govuk-section-break--m"> |
|
|
|
</div> |
|
|
|
</div> |
|
|
|
</div> |
|
|
|
</div> |
|
|
|