From 82d2ac66d6db835e0130c3f08e8689396970d82e Mon Sep 17 00:00:00 2001 From: Pierre Goiffon Date: Mon, 20 Mar 2023 16:44:28 +0100 Subject: [PATCH] :art: Fix argument of \ormCustomFieldsValue::GetForm --- application/cmdbabstract.class.inc.php | 1 + core/ormcustomfieldsvalue.class.inc.php | 5 +++-- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/application/cmdbabstract.class.inc.php b/application/cmdbabstract.class.inc.php index 56472199a..e90be12ba 100644 --- a/application/cmdbabstract.class.inc.php +++ b/application/cmdbabstract.class.inc.php @@ -2508,6 +2508,7 @@ HTML; $sHTMLValue .= '
'.$sReloadSpan.'
'; // No validation span for this one: it does handle its own validation! $sHTMLValue .= "\n"; + /** @var \ormCustomFieldsValue $value */ $oForm = $value->GetForm($sFormPrefix); $oPredefQueryRenderer = new ConsoleFormRenderer($oForm); $aRenderRes = $oPredefQueryRenderer->Render(); diff --git a/core/ormcustomfieldsvalue.class.inc.php b/core/ormcustomfieldsvalue.class.inc.php index 4ca0c25f0..c669fde60 100644 --- a/core/ormcustomfieldsvalue.class.inc.php +++ b/core/ormcustomfieldsvalue.class.inc.php @@ -50,10 +50,11 @@ class ormCustomFieldsValue * Wrapper used when the only thing you have is the value... * @return \Combodo\iTop\Form\Form */ - public function GetForm() + public function GetForm($sFormPrefix = null) { $oAttDef = MetaModel::GetAttributeDef(get_class($this->oHostObject), $this->sAttCode); - return $oAttDef->GetForm($this->oHostObject); + + return $oAttDef->GetForm($this->oHostObject, $sFormPrefix); } public function GetAsHTML($bLocalize = true)