forked from extern/egroupware
Formatting
This commit is contained in:
parent
93d581dbbe
commit
63ce5878da
@ -13,39 +13,38 @@
|
|||||||
* option) any later version. *
|
* option) any later version. *
|
||||||
\**************************************************************************/
|
\**************************************************************************/
|
||||||
|
|
||||||
|
/* $Id$ */
|
||||||
|
|
||||||
/*
|
/*
|
||||||
** Provides the status of the eGroupware installation.
|
** Provides the status of the eGroupware installation.
|
||||||
*/
|
*/
|
||||||
class updates {
|
class updates
|
||||||
|
{
|
||||||
/*
|
/*
|
||||||
** @return boolean: are there updates or not
|
** @return boolean: are there updates or not
|
||||||
*/
|
*/
|
||||||
function hasUpdates()
|
function hasUpdates()
|
||||||
{
|
{
|
||||||
if(count($this->showUpdates()) > 0) {
|
if(count($this->showUpdates()) > 0)
|
||||||
|
{
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
** @return array with string-message about status of eGroupware and status of all application
|
** @return array with string-message about status of eGroupware and status of all application
|
||||||
*/
|
*/
|
||||||
function showUpdates() {
|
function showUpdates()
|
||||||
|
{
|
||||||
$updates = array();
|
$updates = array();
|
||||||
|
|
||||||
if (isset($GLOBALS['egw_info']['user']['apps']['admin']) && $GLOBALS['egw_info']['user']['apps']['admin'] &&
|
if (isset($GLOBALS['egw_info']['user']['apps']['admin']) && $GLOBALS['egw_info']['user']['apps']['admin'] &&
|
||||||
isset($GLOBALS['egw_info']['server']['checkfornewversion']) && $GLOBALS['egw_info']['server']['checkfornewversion'])
|
isset($GLOBALS['egw_info']['server']['checkfornewversion']) && $GLOBALS['egw_info']['server']['checkfornewversion'])
|
||||||
{
|
{
|
||||||
|
|
||||||
$GLOBALS['egw']->network =& CreateObject('phpgwapi.network');
|
$GLOBALS['egw']->network =& CreateObject('phpgwapi.network');
|
||||||
|
|
||||||
$GLOBALS['egw']->network->set_addcrlf(False);
|
$GLOBALS['egw']->network->set_addcrlf(False);
|
||||||
|
@ -24,8 +24,8 @@ $GLOBALS['egw_info'] = array(
|
|||||||
'currentapp' => 'home',
|
'currentapp' => 'home',
|
||||||
'enable_network_class' => False,
|
'enable_network_class' => False,
|
||||||
'enable_contacts_class' => False,
|
'enable_contacts_class' => False,
|
||||||
'enable_nextmatchs_class' => False,
|
'enable_nextmatchs_class' => False
|
||||||
),
|
)
|
||||||
);
|
);
|
||||||
|
|
||||||
include('../header.inc.php');
|
include('../header.inc.php');
|
||||||
@ -50,9 +50,6 @@ $GLOBALS['tpl']->set_block('home','begin_row','begin_row');
|
|||||||
$GLOBALS['tpl']->set_block('home','end_row','end_row');
|
$GLOBALS['tpl']->set_block('home','end_row','end_row');
|
||||||
$GLOBALS['tpl']->set_block('home','cell','cell');
|
$GLOBALS['tpl']->set_block('home','cell','cell');
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
// Commented by alpeb: The following prevented anonymous users to get a home page. Perhaps it was done with anonymous users such as the ones
|
// Commented by alpeb: The following prevented anonymous users to get a home page. Perhaps it was done with anonymous users such as the ones
|
||||||
// used by wiki and sitemgr in mind. However, if you mark a normal user as anonymous just to avoid being shown in sessions and access log (like you would for an admin that doesn't want to be noticed), the user won't be able to login anymore. That's why I commented the code.
|
// used by wiki and sitemgr in mind. However, if you mark a normal user as anonymous just to avoid being shown in sessions and access log (like you would for an admin that doesn't want to be noticed), the user won't be able to login anymore. That's why I commented the code.
|
||||||
/*if ($GLOBALS['egw']->session->session_flags == 'A')
|
/*if ($GLOBALS['egw']->session->session_flags == 'A')
|
||||||
@ -69,13 +66,11 @@ $GLOBALS['tpl']->set_block('home','cell','cell');
|
|||||||
exit;
|
exit;
|
||||||
}*/
|
}*/
|
||||||
|
|
||||||
|
|
||||||
/*
|
/*
|
||||||
** Show the updates
|
** Show the updates
|
||||||
*/
|
*/
|
||||||
$GLOBALS['egw']->hooks->single('showUpdates','home');
|
$GLOBALS['egw']->hooks->single('showUpdates','home');
|
||||||
|
|
||||||
|
|
||||||
/*
|
/*
|
||||||
** Display the notification window
|
** Display the notification window
|
||||||
*/
|
*/
|
||||||
@ -87,7 +82,6 @@ if (isset($GLOBALS['egw_info']['user']['apps']['notifywindow']) && $GLOBALS['egw
|
|||||||
$GLOBALS['tpl']->pfp('out','notify_window');
|
$GLOBALS['tpl']->pfp('out','notify_window');
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
/* This initializes the users portal_order preference if it does not exist. */
|
/* This initializes the users portal_order preference if it does not exist. */
|
||||||
if(!is_array($GLOBALS['egw_info']['user']['preferences']['portal_order']) && $GLOBALS['egw_info']['apps'])
|
if(!is_array($GLOBALS['egw_info']['user']['preferences']['portal_order']) && $GLOBALS['egw_info']['apps'])
|
||||||
{
|
{
|
||||||
@ -134,7 +128,6 @@ foreach($GLOBALS['egw_info']['user']['apps'] as $app)
|
|||||||
}
|
}
|
||||||
//$GLOBALS['egw']->hooks->process('home',$sorted_apps);
|
//$GLOBALS['egw']->hooks->process('home',$sorted_apps);
|
||||||
|
|
||||||
|
|
||||||
/*
|
/*
|
||||||
** Migrate preferences
|
** Migrate preferences
|
||||||
** @param $appname, $var_old, $var_new, $type='user'
|
** @param $appname, $var_old, $var_new, $type='user'
|
||||||
@ -194,7 +187,6 @@ if($migrate_oldvarnames)
|
|||||||
$neworder = array();
|
$neworder = array();
|
||||||
$done = array();
|
$done = array();
|
||||||
|
|
||||||
|
|
||||||
/*
|
/*
|
||||||
** Display application hooks
|
** Display application hooks
|
||||||
**
|
**
|
||||||
@ -278,7 +270,6 @@ foreach($sorted_apps as $appname)
|
|||||||
$done[$appname] = 1;
|
$done[$appname] = 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
$GLOBALS['tpl']->pfp('out','end_table');
|
$GLOBALS['tpl']->pfp('out','end_table');
|
||||||
|
|
||||||
// Update stored value of order
|
// Update stored value of order
|
||||||
|
@ -9,6 +9,7 @@
|
|||||||
* option) any later version. *
|
* option) any later version. *
|
||||||
\**************************************************************************/
|
\**************************************************************************/
|
||||||
|
|
||||||
|
/* $Id$ */
|
||||||
|
|
||||||
/* Basic information about this app */
|
/* Basic information about this app */
|
||||||
$setup_info['home']['name'] = 'home';
|
$setup_info['home']['name'] = 'home';
|
||||||
@ -28,5 +29,4 @@
|
|||||||
/* The hooks this app includes, needed for hooks registration */
|
/* The hooks this app includes, needed for hooks registration */
|
||||||
$setup_info['home']['hooks']['hasUpdates'] = 'home.updates.hasUpdates';
|
$setup_info['home']['hooks']['hasUpdates'] = 'home.updates.hasUpdates';
|
||||||
$setup_info['home']['hooks']['showUpdates'] = 'home.updates.showUpdates';
|
$setup_info['home']['hooks']['showUpdates'] = 'home.updates.showUpdates';
|
||||||
|
|
||||||
?>
|
?>
|
||||||
|
Loading…
Reference in New Issue
Block a user