[ Index ]
 

Code source de eGroupWare 1.2.106-2

Accédez au Source d'autres logiciels libresSoutenez Angelica Josefina !

title

Body

[fermer]

/addressbook/inc/ -> hook_sidebox_menu.inc.php (source)

   1  <?php
   2    /**************************************************************************\
   3    * eGroupWare - Calendar's Sidebox-Menu for idots-template                  *
   4    * http://www.egroupware.org                                                *
   5    * Written by Pim Snel <pim@lingewoud.nl>                                   *
   6    * --------------------------------------------                             *
   7    *  This program is free software; you can redistribute it and/or modify it *
   8    *  under the terms of the GNU General Public License as published by the   *
   9    *  Free Software Foundation; either version 2 of the License, or (at your  *
  10    *  option) any later version.                                              *
  11    \**************************************************************************/
  12  
  13    /* $Id: hook_sidebox_menu.inc.php 20295 2006-02-15 12:31:25Z  $ */
  14  {
  15  
  16   /*
  17      This hookfile is for generating an app-specific side menu used in the idots
  18      template set.
  19  
  20      $menu_title speaks for itself
  21      $file is the array with link to app functions
  22  
  23      display_sidebox can be called as much as you like
  24   */
  25  
  26      $menu_title = $GLOBALS['egw_info']['apps'][$appname]['title'];
  27      
  28      $file = Array(
  29          array(
  30              'text' => '<a class="textSidebox" href="'.$GLOBALS['egw']->link('/index.php',array('menuaction' => 'addressbook.uicontacts.edit')).
  31                  '" onclick="window.open(this.href,\'_blank\',\'dependent=yes,width=850,height=440,scrollbars=yes,status=yes\'); 
  32                  return false;">'.lang('Add').'</a>',
  33              'no_lang' => true,
  34              'link' => false
  35          ),
  36  //         'Add'=>$GLOBALS['egw']->link('/index.php','menuaction=addressbook.uiaddressbook.add'),
  37          'Advanced search'=>$GLOBALS['egw']->link('/index.php','menuaction=addressbook.uicontacts.search'),
  38          '_NewLine_', // give a newline
  39          'import contacts' => $GLOBALS['egw']->link('/index.php','menuaction=addressbook.uiXport.import'),
  40          'export contacts' => $GLOBALS['egw']->link('/index.php','menuaction=addressbook.uiXport.export')
  41      );
  42      display_sidebox($appname,$menu_title,$file);
  43  
  44      if($GLOBALS['egw_info']['user']['apps']['preferences'])
  45      {
  46          $menu_title = lang('Preferences');
  47          $file                  = array();
  48          $file['Addressbook preferences'] = $GLOBALS['egw']->link('/index.php','menuaction=addressbook.uiaddressbook.preferences');
  49          if(!$GLOBALS['egw_info']['server']['deny_user_grants_access'])
  50              $file['Grant Access']     = $GLOBALS['egw']->link('/index.php','menuaction=preferences.uiaclprefs.index&acl_app=addressbook');
  51          $file['Edit Categories']      = $GLOBALS['egw']->link('/index.php','menuaction=preferences.uicategories.index&cats_app=addressbook&cats_level=True&global_cats=True');
  52  
  53          display_sidebox($appname,$menu_title,$file);
  54      }
  55  
  56      if ($GLOBALS['egw_info']['user']['apps']['admin'])
  57      {
  58          $menu_title = lang('Administration');
  59          $file = Array(
  60              'Configuration'=>$GLOBALS['egw']->link('/index.php','menuaction=admin.uiconfig.index&appname=addressbook'),
  61              'Custom Fields'=>$GLOBALS['egw']->link('/index.php','menuaction=admin.customfields.edit&appname=addressbook'),
  62              'Global Categories' =>$GLOBALS['egw']->link('/index.php','menuaction=admin.uicategories.index&appname=addressbook')
  63          );
  64          display_sidebox($appname,$menu_title,$file);
  65      }
  66  }
  67  ?>


Généré le : Sun Feb 25 17:20:01 2007 par Balluche grâce à PHPXref 0.7