phpgroupware-cvs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Phpgroupware-cvs] CVS: phpgwapi/inc class.common.inc.php,1.193,1.194 fu


From: Ralf Becker <address@hidden>
Subject: [Phpgroupware-cvs] CVS: phpgwapi/inc class.common.inc.php,1.193,1.194 functions.inc.php,1.165,1.166
Date: Fri, 28 Mar 2003 11:19:49 -0500

Update of /cvsroot/phpgroupware/phpgwapi/inc
In directory subversions:/tmp/cvs-serv3029

Modified Files:
        class.common.inc.php functions.inc.php 
Log Message:
now admin can enable/disable the preferences as any other app, fix for bug#2967


Index: class.common.inc.php
===================================================================
RCS file: /cvsroot/phpgroupware/phpgwapi/inc/class.common.inc.php,v
retrieving revision 1.193
retrieving revision 1.194
diff -C2 -r1.193 -r1.194
*** class.common.inc.php        22 Mar 2003 12:29:23 -0000      1.193
--- class.common.inc.php        28 Mar 2003 16:19:46 -0000      1.194
***************
*** 1347,1357 ****
                        $GLOBALS['phpgw_info']['navbar']['home']['icon_hover']  
= $this->image_on('phpgwapi',Array('home','nonav'),'-over');
  
!                       reset($GLOBALS['phpgw_info']['user']['apps']);
!                       /* ksort($GLOBALS['phpgw_info']['user']['apps']); */
! 
!                       
if(is_array($GLOBALS['phpgw_info']['user']['apps']['admin']))
                        {
                                $newarray['admin'] = 
$GLOBALS['phpgw_info']['user']['apps']['admin'];
!                               while(list($index,$value) = 
each($GLOBALS['phpgw_info']['user']['apps']))
                                {
                                        if($index != 'admin')
--- 1347,1355 ----
                        $GLOBALS['phpgw_info']['navbar']['home']['icon_hover']  
= $this->image_on('phpgwapi',Array('home','nonav'),'-over');
  
!                       list($first) = 
each($GLOBALS['phpgw_info']['user']['apps']);
!                       
if(is_array($GLOBALS['phpgw_info']['user']['apps']['admin']) && $first != 
'admin')
                        {
                                $newarray['admin'] = 
$GLOBALS['phpgw_info']['user']['apps']['admin'];
!                               foreach($GLOBALS['phpgw_info']['user']['apps'] 
as $index => $value)
                                {
                                        if($index != 'admin')
***************
*** 1376,1380 ****
                        }
  
!                       while (list($app,$data) = 
each($GLOBALS['phpgw_info']['user']['apps']))
                        {
                                if (is_long($app))
--- 1374,1378 ----
                        }
  
!                       foreach($GLOBALS['phpgw_info']['user']['apps'] as $app 
=> $data)
                        {
                                if (is_long($app))
***************
*** 1383,1387 ****
                                }
  
!                               if 
($GLOBALS['phpgw_info']['apps'][$app]['status'] != 2 && 
$GLOBALS['phpgw_info']['apps'][$app]['status'] != 3)
                                {
                                        
$GLOBALS['phpgw_info']['navbar'][$app]['title'] = $data['title'];
--- 1381,1385 ----
                                }
  
!                               if ($app == 'preferences' || 
$GLOBALS['phpgw_info']['apps'][$app]['status'] != 2 && 
$GLOBALS['phpgw_info']['apps'][$app]['status'] != 3)
                                {
                                        
$GLOBALS['phpgw_info']['navbar'][$app]['title'] = $data['title'];
***************
*** 1403,1411 ****
  
                        /* apps for the top menu */
-                       
$GLOBALS['phpgw_info']['navbar']['preferences']['title']                = 
lang('preferences');
-                       $GLOBALS['phpgw_info']['navbar']['preferences']['url']  
                = $GLOBALS['phpgw']->link('/preferences/index.php');
-                       $GLOBALS['phpgw_info']['navbar']['preferences']['icon'] 
                = $this->image('preferences',Array('navbar','nonav'));
-                       
$GLOBALS['phpgw_info']['navbar']['preferences']['icon_hover']   = 
$this->image_on('preferences',Array('navbar','nonav'),'-over');
- 
                        $GLOBALS['phpgw_info']['navbar']['help']['title']       
                        = lang('manual');
                        $GLOBALS['phpgw_info']['navbar']['help']['url']         
                        = $GLOBALS['phpgw']->link('/help.php');
--- 1401,1404 ----
***************
*** 1413,1423 ****
                        $GLOBALS['phpgw_info']['navbar']['help']['icon_hover']  
                = $this->image_on('phpgwapi',Array('help','nonav'),'-over');
  
!                       if ($GLOBALS['phpgw_info']['flags']['currentapp'] == 
'home') //|| $GLOBALS['phpgw_info']['flags']['currentapp'] == 'preferences')
                        {
!                               $app = 'phpGroupWare';
                        }
                        else
                        {
                                $app = 
$GLOBALS['phpgw_info']['flags']['currentapp'];
                        }
  
--- 1406,1424 ----
                        $GLOBALS['phpgw_info']['navbar']['help']['icon_hover']  
                = $this->image_on('phpgwapi',Array('help','nonav'),'-over');
  
!                       if ($GLOBALS['phpgw_info']['flags']['currentapp'] == 
'home')
                        {
!                               $app = $app_title = 'phpGroupWare';
                        }
                        else
                        {
                                $app = 
$GLOBALS['phpgw_info']['flags']['currentapp'];
+                               $app_title = 
$GLOBALS['phpgw_info']['apps'][$app]['title'];
+                       }
+ 
+                       if 
($GLOBALS['phpgw_info']['user']['apps']['preferences'])      // preferences last
+                       {
+                               $prefs = 
$GLOBALS['phpgw_info']['navbar']['preferences'];
+                               
unset($GLOBALS['phpgw_info']['navbar']['preferences']);
+                               $GLOBALS['phpgw_info']['navbar']['preferences'] 
= $prefs;
                        }
  

Index: functions.inc.php
===================================================================
RCS file: /cvsroot/phpgroupware/phpgwapi/inc/functions.inc.php,v
retrieving revision 1.165
retrieving revision 1.166
diff -C2 -r1.165 -r1.166
*** functions.inc.php   22 Mar 2003 12:29:23 -0000      1.165
--- functions.inc.php   28 Mar 2003 16:19:46 -0000      1.166
***************
*** 371,375 ****
                $continue_app_data = True;
                if ($GLOBALS['phpgw_info']['flags']['currentapp'] != 'home' &&
-                       $GLOBALS['phpgw_info']['flags']['currentapp'] != 
'preferences' &&
                        $GLOBALS['phpgw_info']['flags']['currentapp'] != 
'about' &&
                        $GLOBALS['phpgw_info']['flags']['currentapp'] != 'help')
--- 371,374 ----





reply via email to

[Prev in Thread] Current Thread [Next in Thread]