diff --git a/app/controllers/evaluation/application_controller.rb b/app/controllers/evaluation/application_controller.rb index 7920515ab..32a70b16e 100644 --- a/app/controllers/evaluation/application_controller.rb +++ b/app/controllers/evaluation/application_controller.rb @@ -1,4 +1,17 @@ module Evaluation class ApplicationController < ::ApplicationController + protected + + def authenticate_user! + return unless current_user.guest? + + session.delete(:dfe_sign_in_uid) + + if params[:controller] == "evaluation/tasks" && params[:action] == "edit" + session[:email_evaluator_link] = evaluation_task_path(id: params[:id], host: request.host) + end + + redirect_to root_path, notice: I18n.t("banner.session.visitor") + end end end diff --git a/app/views/specify/home/_default.html.erb b/app/views/specify/home/_default.html.erb new file mode 100644 index 000000000..3944c74cc --- /dev/null +++ b/app/views/specify/home/_default.html.erb @@ -0,0 +1,52 @@ +<%= content_for :title, I18n.t("specifying.start_page.page_title") %> + +

+ <%= I18n.t("specifying.start_page.page_title") %> +

+ +

+ <%= I18n.t("specifying.start_page.overview_purpose") %> +

+ + + +

+ <%= I18n.t("specifying.start_page.overview_download") %> +

+ +

<%= I18n.t("specifying.start_page.who_can_use_body") %>

+ + +<% if PagesController.bypass_dsi? %> + <%= button_to "/auth/developer", class: "govuk-button govuk-!-margin-top-2 govuk-!-margin-bottom-8 govuk-button--start" do %> + <%= "#{I18n.t("generic.button.start")} (bypass DSI)" %> + + <% end %> +<% else %> + <%= button_to @start_now_button_route, + :method => @start_now_button_method, + class: "govuk-button govuk-!-margin-top-2 govuk-!-margin-bottom-8 govuk-button--start" do %> + <%= I18n.t("generic.button.start") %> + + <% end %> +<% end %> + +

+ <%= I18n.t("specifying.start_page.before_you_start_title") %> +

+ +<% I18n.t("specifying.start_page.before_you_start_body").each do |paragraph| %> +

<%= paragraph %>

+<% end %> diff --git a/app/views/specify/home/_evaluation.html.erb b/app/views/specify/home/_evaluation.html.erb new file mode 100644 index 000000000..38c7d1487 --- /dev/null +++ b/app/views/specify/home/_evaluation.html.erb @@ -0,0 +1,53 @@ +<%= content_for :title, I18n.t("specifying.start_page.page_title") %> + +

+ <%= I18n.t("specifying.evaluation_page.page_title")%> +

+ +

+ <%= I18n.t("specifying.evaluation_page.overview_purpose") %> +

+ + + +

+ <%= I18n.t("specifying.evaluation_page.overview_declaration") %> +

+ +

+ <%= I18n.t("specifying.evaluation_page.watch_video") %> + <%= govuk_link_to I18n.t("specifying.evaluation_page.watch_video_link"), "https://www.youtube.com/watch?v=cbL65QlOas4", no_visited_state: true, target: "_blank" %> +

+

<%= I18n.t("specifying.evaluation_page.evaluate_independently") %>

+

<%= I18n.t("specifying.evaluation_page.justification") %>

+ + +<% if PagesController.bypass_dsi? %> + <%= button_to "/auth/developer", class: "govuk-button govuk-!-margin-top-2 govuk-!-margin-bottom-8 govuk-button--start" do %> + <%= "#{I18n.t("generic.button.start")} (bypass DSI)" %> + + <% end %> +<% else %> + <%= button_to @start_now_button_route, + :method => @start_now_button_method, + class: "govuk-button govuk-!-margin-top-2 govuk-!-margin-bottom-8 govuk-button--start" do %> + <%= I18n.t("generic.button.start") %> + + <% end %> +<% end %> + +

+ <%= I18n.t("specifying.start_page.before_you_start_title") %> +

+ +<% I18n.t("specifying.evaluation_page.before_you_start_body").each do |paragraph| %> +

<%= paragraph %>

+<% end %> diff --git a/app/views/specify/home/show.html.erb b/app/views/specify/home/show.html.erb index 3944c74cc..bf8f7ade4 100644 --- a/app/views/specify/home/show.html.erb +++ b/app/views/specify/home/show.html.erb @@ -1,52 +1,7 @@ <%= content_for :title, I18n.t("specifying.start_page.page_title") %> -

- <%= I18n.t("specifying.start_page.page_title") %> -

- -

- <%= I18n.t("specifying.start_page.overview_purpose") %> -

- - - -

- <%= I18n.t("specifying.start_page.overview_download") %> -

- -

<%= I18n.t("specifying.start_page.who_can_use_body") %>

- - -<% if PagesController.bypass_dsi? %> - <%= button_to "/auth/developer", class: "govuk-button govuk-!-margin-top-2 govuk-!-margin-bottom-8 govuk-button--start" do %> - <%= "#{I18n.t("generic.button.start")} (bypass DSI)" %> - - <% end %> +<% if session[:email_evaluator_link].present? %> + <%= render 'evaluation'%> <% else %> - <%= button_to @start_now_button_route, - :method => @start_now_button_method, - class: "govuk-button govuk-!-margin-top-2 govuk-!-margin-bottom-8 govuk-button--start" do %> - <%= I18n.t("generic.button.start") %> - - <% end %> -<% end %> - -

- <%= I18n.t("specifying.start_page.before_you_start_title") %> -

- -<% I18n.t("specifying.start_page.before_you_start_body").each do |paragraph| %> -

<%= paragraph %>

+ <%= render 'default'%> <% end %> diff --git a/config/locales/en.yml b/config/locales/en.yml index d6170901b..48a40c000 100644 --- a/config/locales/en.yml +++ b/config/locales/en.yml @@ -914,6 +914,20 @@ en: who_can_use_list: - are procuring for a single school in England - either a local authority maintained school or an academy in a single or multi-academy trust - are procuring a single contract + evaluation_page: + page_title: Complete procurement evaluation + overview_purpose: 'Use this service to complete the supplier evaluation stage of the procurement. You will be able to:' + overview_supported_category_list: + - view bids from potential suppliers + - evaluate bids using a pre-populated evaluation sheet + - complete the evaluation tasks + overview_declaration: Before starting the evaluation, you must complete the declaration of interest form attached to the email inviting you to complete the procurement evaluation. + watch_video: You can watch the + watch_video_link: Evaluation Guidance training video on YouTube (opens in new tab) + evaluate_independently: Bids must be evaluated independently of each other and other evaluators. + justification: Insufficient justification for scores will result in evaluations being returned, which could delay the procurement. + before_you_start_body: + - The service will guide you through what information to provide. Standard regulations and requirements that suppliers must comply with will be added automatically. step: button: skip: Skip for now