mirror of
https://github.com/Combodo/iTop.git
synced 2026-03-02 15:44:11 +01:00
🐛 Fix notifications tab in objects no longer displaying items (regression introduced by a9bd5a8)
This commit is contained in:
@@ -678,7 +678,8 @@ EOF
|
||||
foreach($aNotificationClasses as $sNotifClass)
|
||||
{
|
||||
$aNotifSearches[$sNotifClass] = DBObjectSearch::FromOQL("SELECT $sNotifClass AS Ev JOIN Trigger AS T ON Ev.trigger_id = T.id WHERE T.id IN (:triggers) AND Ev.object_id = :id");
|
||||
$oNotifSet = new DBObjectSet($aNotifSearches[$sNotifClass], array(), $aParams);
|
||||
$aNotifSearches[$sNotifClass]->SetInternalParams($aParams);
|
||||
$oNotifSet = new DBObjectSet($aNotifSearches[$sNotifClass], array());
|
||||
$iNotifsCount += $oNotifSet->Count();
|
||||
}
|
||||
// Display notifications regarding the object: on block per subclass to have the intersting columns
|
||||
|
||||
@@ -249,7 +249,7 @@ class DisplayBlock
|
||||
$sHtml .= $this->GetRenderContent($oPage, $aExtraParams, $sId);
|
||||
} catch (Exception $e)
|
||||
{
|
||||
|
||||
IssueLog::Error('Exception during GetDisplay: ' . $e->getMessage());
|
||||
}
|
||||
$sHtml .= "</div>\n";
|
||||
}
|
||||
|
||||
@@ -1536,7 +1536,19 @@ class VariableExpression extends UnaryExpression
|
||||
$oRet = null;
|
||||
if (array_key_exists($this->m_sName, $aArgs))
|
||||
{
|
||||
$oRet = new ScalarExpression($aArgs[$this->m_sName]);
|
||||
if(is_array($aArgs[$this->m_sName]))
|
||||
{
|
||||
$aExpressions = array();
|
||||
foreach($aArgs[$this->m_sName] as $sValue)
|
||||
{
|
||||
$aExpressions[] = new ScalarExpression($sValue);
|
||||
}
|
||||
$oRet = new ListExpression($aExpressions);
|
||||
}
|
||||
else
|
||||
{
|
||||
$oRet = new ScalarExpression($aArgs[$this->m_sName]);
|
||||
}
|
||||
}
|
||||
elseif (($iPos = strpos($this->m_sName, '->')) !== false)
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user