From 13430d89778e3c171c9de44b38ac829118811991 Mon Sep 17 00:00:00 2001 From: "Marco A. Nina" Date: Thu, 31 Oct 2024 11:32:37 -0400 Subject: [PATCH] Add option advanced forms --- ProcessMaker/Http/Resources/V1_1/TaskScreen.php | 2 +- ProcessMaker/Traits/TaskResourceIncludes.php | 2 +- .../js/processes/screens/components/ScreenTypeDropdown.vue | 7 ++++++- 3 files changed, 8 insertions(+), 3 deletions(-) diff --git a/ProcessMaker/Http/Resources/V1_1/TaskScreen.php b/ProcessMaker/Http/Resources/V1_1/TaskScreen.php index cc42e5a106..c5334adf42 100644 --- a/ProcessMaker/Http/Resources/V1_1/TaskScreen.php +++ b/ProcessMaker/Http/Resources/V1_1/TaskScreen.php @@ -39,7 +39,7 @@ private function includeScreen($request) $array['screen'] = null; } - if ($array['screen']) { + if (is_array($array['screen']) && $array['screen']) { // Apply translations to screen $screenTranslation = new ScreenTranslation(); $array['screen']['config'] = $screenTranslation->applyTranslations($array['screen']); diff --git a/ProcessMaker/Traits/TaskResourceIncludes.php b/ProcessMaker/Traits/TaskResourceIncludes.php index bfb7841622..f7ca2b4ee0 100644 --- a/ProcessMaker/Traits/TaskResourceIncludes.php +++ b/ProcessMaker/Traits/TaskResourceIncludes.php @@ -85,7 +85,7 @@ private function includeScreen($request) $array['screen'] = null; } - if ($array['screen']) { + if (is_array($array['screen']) && $array['screen']) { // Apply translations to screen $screenTranslation = new ScreenTranslation(); $array['screen']['config'] = $screenTranslation->applyTranslations($array['screen']); diff --git a/resources/js/processes/screens/components/ScreenTypeDropdown.vue b/resources/js/processes/screens/components/ScreenTypeDropdown.vue index 2b92f029a7..0444cea2d3 100644 --- a/resources/js/processes/screens/components/ScreenTypeDropdown.vue +++ b/resources/js/processes/screens/components/ScreenTypeDropdown.vue @@ -111,7 +111,12 @@ export default { icon = "fas fa-comment"; description = this.$t("Design functional rule-based modern chat style experiences."); break; - + case "ADVANCED": + type = "ADVANCED"; + typeHuman = "Advanced"; + icon = "fa fa-book"; + description = this.$t("Design Advanced interactive and complex multi-page forms."); + break; default: type = "FORM"; typeHuman = this.$t("Form");