fixed bug reported on the german list: infolog priority (color) was not shown on homepage - app.css file was not loaded

This commit is contained in:
Ralf Becker 2005-11-27 18:24:30 +00:00
parent 77193a8839
commit d127e029da

View File

@ -1,6 +1,6 @@
<?php <?php
/**************************************************************************\ /**************************************************************************\
* eGroupWare - Info Log administration * * eGroupWare - Info Log on Homepage *
* http://www.egroupware.org * * http://www.egroupware.org *
* -------------------------------------------- * * -------------------------------------------- *
* This program is free software; you can redistribute it and/or modify it * * This program is free software; you can redistribute it and/or modify it *
@ -10,8 +10,7 @@
\**************************************************************************/ \**************************************************************************/
/* $Id$ */ /* $Id$ */
$showevents = intval($GLOBALS['egw_info']['user']['preferences']['infolog']['homeShowEvents']); if (($showevents = (int) $GLOBALS['egw_info']['user']['preferences']['infolog']['homeShowEvents']) > 0)
if($showevents > 0)
{ {
$save_app = $GLOBALS['egw_info']['flags']['currentapp']; $save_app = $GLOBALS['egw_info']['flags']['currentapp'];
$GLOBALS['egw_info']['flags']['currentapp'] = 'infolog'; $GLOBALS['egw_info']['flags']['currentapp'] = 'infolog';
@ -34,11 +33,8 @@
break; break;
}*/ }*/
$title = lang('InfoLog').' - '.lang($infolog->filters['own-open-today']); $title = lang('InfoLog').' - '.lang($infolog->filters['own-open-today']);
$xslt = $infolog->tmpl->xslt;
unset($infolog); unset($infolog);
if(!$xslt) // .14/6
{
$portalbox =& CreateObject('phpgwapi.listbox',array( $portalbox =& CreateObject('phpgwapi.listbox',array(
'title' => $title, 'title' => $title,
'primary' => $GLOBALS['egw_info']['theme']['navbar_bg'], 'primary' => $GLOBALS['egw_info']['theme']['navbar_bg'],
@ -54,17 +50,20 @@
} }
$portalbox->data = $data; $portalbox->data = $data;
echo "\n<!-- BEGIN InfoLog info -->\n".$portalbox->draw($html)."\n<!-- END InfoLog info -->\n"; if (!file_exists(EGW_SERVER_ROOT.($css_file ='/infolog/templates/'.$GLOBALS['egw_info']['user']['preferences']['common']['template_set'].'/app.css')))
unset($portalbox);
}
else // HEAD / XSLT
{ {
$GLOBALS['egw']->portalbox->set_params(array( $css_file = '/infolog/templates/default/app.css';
'app_id' => $app_id,
'title' => $title
));
$GLOBALS['egw']->portalbox->draw($html);
} }
echo '
<!-- BEGIN InfoLog info -->
<style type="text/css">
<!--
@import url('.$GLOBALS['egw_info']['server']['webserver_url'].$css_file.');
-->
</style>
'. $portalbox->draw($html)."\n<!-- END InfoLog info -->\n";
unset($portalbox);
unset($html); unset($html);
$GLOBALS['egw_info']['flags']['currentapp'] = $save_app; $GLOBALS['egw_info']['flags']['currentapp'] = $save_app;
} }