From 1300d4640806fffe5884254fbf493e53ab429427 Mon Sep 17 00:00:00 2001
From: Ralf Zimmermann <ralf.zimmermann@tritum.de>
Date: Mon, 5 Oct 2015 01:09:44 +0200
Subject: [PATCH] [BUGFIX] EXT:form - themeName can not be overwritten by
 integrator

It is possible to set a new themeName for a specific form but it is not
possible to set it for the whole plugin via

plugin.tx_form.settings.registeredElements.FORM.themeName = Mytheme

Resolves: #70368
Releases: master
Change-Id: I76e7584dd9b333c56c0dc4c05a7d5e78b0a7c225
Reviewed-on: http://review.typo3.org/43805
Reviewed-by: Wouter Wolters <typo3@wouterwolters.nl>
Tested-by: Wouter Wolters <typo3@wouterwolters.nl>
Reviewed-by: Georg Ringer <georg.ringer@gmail.com>
Tested-by: Georg Ringer <georg.ringer@gmail.com>
---
 typo3/sysext/form/Classes/Domain/Model/Configuration.php | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/typo3/sysext/form/Classes/Domain/Model/Configuration.php b/typo3/sysext/form/Classes/Domain/Model/Configuration.php
index f745a4e1c6b6..3789bfa8383c 100644
--- a/typo3/sysext/form/Classes/Domain/Model/Configuration.php
+++ b/typo3/sysext/form/Classes/Domain/Model/Configuration.php
@@ -184,6 +184,8 @@ class Configuration {
 		// Set the theme name
 		if (!empty($this->typoScript['themeName'])) {
 			$this->setThemeName($this->typoScript['themeName']);
+		} elseif (!empty($this->typoScriptRepository->getModelConfigurationByScope('FORM', 'themeName'))) {
+			$this->setThemeName($this->typoScriptRepository->getModelConfigurationByScope('FORM', 'themeName'));
 		} else {
 			$this->setThemeName(static::DEFAULT_THEME_NAME);
 		}
-- 
GitLab