From cd4c07acd88b9ec9354fe95121a512cd96134004 Mon Sep 17 00:00:00 2001 From: Emiel Date: Thu, 14 Nov 2024 13:40:00 +0100 Subject: [PATCH] #997 Add possibility to skip finished page --- core/systems/assignment/external_panel_controller.ex | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/core/systems/assignment/external_panel_controller.ex b/core/systems/assignment/external_panel_controller.ex index 5ad747d63..f54580322 100644 --- a/core/systems/assignment/external_panel_controller.ex +++ b/core/systems/assignment/external_panel_controller.ex @@ -54,6 +54,9 @@ defmodule Systems.Assignment.ExternalPanelController do String.length(id) <= @id_max_lenght and Regex.match?(@id_valid_regex, id) end + # FIXME: This is a temporary solution to allow embeds to work + defp has_no_access?(_, %{"embed" => "true"}), do: false + defp has_no_access?(%{external_panel: external_panel}, params) do external_panel = Atom.to_string(external_panel) external_panel != get_panel(params) @@ -117,5 +120,6 @@ defmodule Systems.Assignment.ExternalPanelController do defp get_participant(_), do: nil defp embedded?(%{"entry" => "liss"}), do: true + defp embedded?(%{"embed" => "true"}), do: true defp embedded?(_), do: false end