mirror of
https://github.com/Combodo/iTop.git
synced 2026-04-25 11:38:44 +02:00
N°2847 - Global Search: Fix class images URL, rename internal variable
This commit is contained in:
@@ -101,19 +101,26 @@ class GlobalSearchHelper
|
||||
* @throws \CoreException
|
||||
* @throws \CoreUnexpectedValue
|
||||
* @throws \MySQLException
|
||||
* @throws \Exception
|
||||
*/
|
||||
public static function GetLastQueries()
|
||||
{
|
||||
/** @var array $aHistoryEntries */
|
||||
$aHistoryEntries = appUserPreferences::GetPref(static::USER_PREF_CODE, []);
|
||||
|
||||
// Add HTML label if missing
|
||||
for($iIdx = 0; $iIdx < count($aHistoryEntries); $iIdx++)
|
||||
{
|
||||
// Add HTML label if missing
|
||||
if(!isset($aHistoryEntries[$iIdx]['label_html']))
|
||||
{
|
||||
$aHistoryEntries[$iIdx]['label_html'] = utils::HtmlEntities($aHistoryEntries[$iIdx]['query']);
|
||||
}
|
||||
|
||||
// Set absolute URL
|
||||
if(isset($aHistoryEntries[$iIdx]['icon_url']))
|
||||
{
|
||||
$aHistoryEntries[$iIdx]['icon_url'] = utils::GetAbsoluteUrlAppRoot().$aHistoryEntries[$iIdx]['icon_url'];
|
||||
}
|
||||
}
|
||||
|
||||
return $aHistoryEntries;
|
||||
|
||||
Reference in New Issue
Block a user