Changeset 3359 for branches


Ignore:
Timestamp:
10/14/10 15:55:28 (14 years ago)
Author:
eduardoalex
Message:

Ticket #1226 - Correcao do erro narrado no ticket em questão

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/2.2/expressoAdmin1_2/inc/class.uisectors.inc.php

    r1991 r3359  
    4747 
    4848                        // Verifica se o administrador tem acesso. 
    49                         if (!$this->functions->check_acl($manager_lid,'list_sectors')) 
    50                         { 
    51                                 $GLOBALS['phpgw']->redirect($GLOBALS['phpgw']->link('/expressoAdmin1_2/inc/access_denied.php')); 
    52                         } 
     49 
    5350                         
    5451                        unset($GLOBALS['phpgw_info']['flags']['noheader']); 
     
    10299                                                'sector_name'  => $sector['display'], 
    103100                                                'cota_link' => $this->row_action('view','cota',$sector['dn']), 
    104                                                 'add_link' => $this->row_action('add','sector',$sector['dn']) 
    105                                         );                                       
     101                                        );       
     102                                         
     103                                        if ($this->functions->check_acl($manager_lid,'create_sectors')) 
     104                                                $p->set_var('add_link',$this->row_action('add','sector',$sector['dn'])); 
     105                                        else 
     106                                                $p->set_var('add_link',' '); 
     107                                                                         
    106108                                        if(isset($GLOBALS['phpgw_info']['server']['time_to_account_expires'])) 
    107109                                                $var['inactives_link'] = $this->row_action('list_inactive','users',$sector['dn'],'uiaccounts'); 
     
    136138                        ); 
    137139                        $p->set_var($var); 
    138                         $p->set_var('input_add','<input type="submit" value="' . lang('Add Sectors') . '">'); 
     140                         
     141                        if ($this->functions->check_acl($manager_lid,'create_sectors')) { 
     142                                $p->set_var('input_add','<input type="submit" value="' . lang('Add Sectors') . '">'); 
     143                        } 
     144                        else { 
     145                                $p->set_var('input_add',' '); 
     146                        } 
    139147                         
    140148                        $p->parse('rows','row_empty',True); 
Note: See TracChangeset for help on using the changeset viewer.