Merge remote-tracking branch 'origin/support/3.0' into develop

# Conflicts:
#	application/cmdbabstract.class.inc.php
This commit is contained in:
acognet
2022-08-12 18:17:00 +02:00
6 changed files with 42 additions and 22 deletions

View File

@@ -1930,7 +1930,7 @@ abstract class DBObject implements iDisplay
/** @var \AttributeExternalKey $oAtt */
$sTargetClass = $oAtt->GetTargetClass();
if (false === MetaModel::IsObjectInDB($sTargetClass, $toCheck)) {
return "Target object not found (".utils::HtmlEntities($sTargetClass).".::".utils::HtmlEntities($toCheck).")";
return "Target object not found (".$sTargetClass.".::".$toCheck.")";
}
}
if ($oAtt->IsHierarchicalKey())
@@ -1939,7 +1939,7 @@ abstract class DBObject implements iDisplay
$aValues = $oAtt->GetAllowedValues(array('this' => $this));
if (!array_key_exists($toCheck, $aValues))
{
return "Value not allowed [". utils::HtmlEntities($toCheck)."]";
return "Value not allowed [$toCheck]";
}
}
}
@@ -1953,7 +1953,7 @@ abstract class DBObject implements iDisplay
$oTag->SetValues(explode(' ', $toCheck));
} catch (Exception $e)
{
return "Tag value [". utils::HtmlEntities($toCheck)."] is not a valid tag list";
return "Tag value '$toCheck' is not a valid tag list";
}
return true;
@@ -1981,7 +1981,7 @@ abstract class DBObject implements iDisplay
$oTag->SetValues($aValues);
} catch (Exception $e)
{
return "Set value[". utils::HtmlEntities($toCheck)."] is not a valid set";
return "Set value '$toCheck' is not a valid set";
}
return true;
@@ -2001,7 +2001,7 @@ abstract class DBObject implements iDisplay
{
if (!array_key_exists($toCheck, $aValues))
{
return "Value not allowed [". utils::HtmlEntities($toCheck)."]";
return "Value not allowed [$toCheck]";
}
}
if (!is_null($iMaxSize = $oAtt->GetMaxSize()))
@@ -2014,7 +2014,7 @@ abstract class DBObject implements iDisplay
}
if (!$oAtt->CheckFormat($toCheck))
{
return "Wrong format [". utils::HtmlEntities($toCheck)."]";
return "Wrong format [$toCheck]";
}
}
else