Show
Ignore:
Timestamp:
05/21/08 01:02:56 (8 months ago)
Author:
aarkerio
Message:

New Try

Files:
1 modified

Legend:

Unmodified
Added
Removed
  • trunk/app/controllers/categories_controller.php

    r526 r538  
    2121   parent::beforeFilter(); 
    2222 } 
    23     
    24  public function isAuthorized() 
    25  {      
     23  
     24 public function isAuthorized()  
     25 {       
    2626   if (isset( $this->params[Configure::read('Routing.admin')] )): 
    27             if ($this->Auth->user('group_id') == 1 || $this->Auth->user('group_id') == 2 ):  // admin and teachers 
    28                  return true; 
    29             endif; 
     27       if ($this->Auth->user('group_id') == 1 || $this->Auth->user('group_id') == 2 ):  // admin and teachers 
     28         return true; 
     29       else: 
     30             return false; 
     31       endif;    
    3032   endif; 
    31    return false;  // go away !! 
    32   } 
    3333 
    34   public function index($order = null) 
    35   { 
     34   return true; 
     35 }   
     36 
     37 public function index($order = null) 
     38 { 
    3639        $this->layout    = 'admin'; 
    3740        $this->pageTitle = 'Categories';