From f01bd61692e05b8a789bea40f429bc0dd8225c53 Mon Sep 17 00:00:00 2001 From: Romain Quetiez Date: Mon, 4 Apr 2016 10:00:54 +0000 Subject: [PATCH] CustomFields: suppressed a warning when editing an object with a custom field being read-only SVN:trunk[3976] --- application/cmdbabstract.class.inc.php | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/application/cmdbabstract.class.inc.php b/application/cmdbabstract.class.inc.php index 5f922fc08..2b4dc196e 100644 --- a/application/cmdbabstract.class.inc.php +++ b/application/cmdbabstract.class.inc.php @@ -657,7 +657,12 @@ EOF // Attribute is read-only $sHTMLValue = "".$this->GetAsHTML($sAttCode); - $sHTMLValue .= ''; + $value = $this->Get($sAttCode); + if (is_object($value)) + { + $value = ''; + } + $sHTMLValue .= ''; $aFieldsMap[$sAttCode] = $sInputId; $sComments = $sSynchroIcon; }