prefer icon from link-registry over navbar icon

This commit is contained in:
Ralf Becker 2021-03-04 15:29:15 +02:00
parent 58ae23c74c
commit da91b260d5

View File

@ -905,7 +905,16 @@ class calendar_uiviews extends calendar_ui
$app_data = calendar_bo::integration_get_data($app,'icons');
if (is_null($app_data))
{
$icons[] = Api\Html::image($app,'navbar'); // use navbar icon
if (($icon = Api\Link::get_registry($app,'icon')) &&
($icon = explode('/', $icon)))
{
$icons[] = Api\Html::image($icon[0], $icon[1]); // use icon from link registry
}
else
{
$icons[] = Api\Html::image($app,'navbar'); // use navbar icon
}
}
elseif ($app_data)
{