Project

General

Profile

« Previous | Next » 

Revision 1790

Added by Dietmar about 12 years ago

! update group permission,

View differences:

class.login.php
204 204
				if( ($results_array['system_permissions'] != '') ) {
205 205
                    switch ($cur_group_id) :
206 206
                        case 1:
207
                            if($bOnlyAdminGroup) {
208
                                $_SESSION['SYSTEM_PERMISSIONS'] = array_merge($_SESSION['SYSTEM_PERMISSIONS'], explode(',', $results_array['system_permissions']));
207
                            if( $this->user_id == 1) {
208
               					$_SESSION['SYSTEM_PERMISSIONS'] = array_merge($_SESSION['SYSTEM_PERMISSIONS'], explode(',', $results_array['system_permissions']));
209
                            } else {
210
                                $_SESSION['SYSTEM_PERMISSIONS'] = explode(',', $results_array['system_permissions']);
209 211
                            }
212

  
210 213
                            break;
211 214
                        default:
212 215
        					$_SESSION['SYSTEM_PERMISSIONS'] = array_merge($_SESSION['SYSTEM_PERMISSIONS'], explode(',', $results_array['system_permissions']));
......
232 235
				$first_group = false;
233 236
			}
234 237

  
235
            if( $$bOnlyAdminGroup ) {
236
    			$_SESSION['MODULE_PERMISSIONS'] = array();
237
    			$_SESSION['TEMPLATE_PERMISSIONS'] = array();
238
            }
238
//            if( $$bOnlyAdminGroup ) {
239
//    			$_SESSION['MODULE_PERMISSIONS'] = array();
240
//    			$_SESSION['TEMPLATE_PERMISSIONS'] = array();
241
//            }
239 242

  
240 243
			// Update the users table with current ip and timestamp
241 244
			$get_ts = time();

Also available in: Unified diff