<%= "Welcome back, #{@current_user.name}" %>

<%= heading_for_user_role(@current_user) %>

<% if @current_user.support? || (@current_user.data_coordinator? && @current_user.sales_logs.present?) %>
<%= render partial: "home/data_box", locals: { type: "lettings" } %>
<%= render partial: "home/data_box", locals: { type: "sales" } %>
<%= render partial: "home/data_box", locals: { type: "schemes" } %>
<% else %>
<%= render partial: "home/data_box", locals: { type: "lettings" } %>
<% if @current_user.data_coordinator? %>
<%= render partial: "home/data_box", locals: { type: "schemes" } %>
<% elsif @current_user.sales_logs.present? %>
<%= render partial: "home/data_box", locals: { type: "sales" } %>
<% else %>
<%= render partial: "home/data_box", locals: { type: "misc" } %>
<% end %>
<% end %>

<%= render partial: "layouts/collection_resources" %>
<%= render partial: "home/upcoming_deadlines" %>