From 7f8eed89b6e6a504dc1cee4059f69540fed135c4 Mon Sep 17 00:00:00 2001 From: Joonas Date: Thu, 11 Apr 2024 11:36:47 +0300 Subject: [PATCH] Disable map-type question if maps are not provided --- .../app/packs/src/decidim/forms/admin/forms.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/decidim-module-forms_locations/app/packs/src/decidim/forms/admin/forms.js b/decidim-module-forms_locations/app/packs/src/decidim/forms/admin/forms.js index 9b831ef..cfa4c16 100644 --- a/decidim-module-forms_locations/app/packs/src/decidim/forms/admin/forms.js +++ b/decidim-module-forms_locations/app/packs/src/decidim/forms/admin/forms.js @@ -160,7 +160,7 @@ export default function createEditableForm() { $target.find(".question--collapse").data("toggle", toggleAttr); } if ($("[data-decidim-map]").length === 0) { - $target.find("option[value='select_locations']").prop("disabled", true); + $target.find("option[value='select_locations'], option[value='map_locations']").prop("disabled", true); } };