Subversion Repositories SmartDukaan

Rev

Rev 11508 | Rev 15927 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 11508 Rev 11520
Line 12... Line 12...
12
		// if(!isset($admin) || empty($admin)) {
12
		// if(!isset($admin) || empty($admin)) {
13
		// 	redirect(base_url().'authorize');
13
		// 	redirect(base_url().'authorize');
14
		// }
14
		// }
15
		$authorized = $this->session->userdata('authorized');
15
		$authorized = $this->session->userdata('authorized');
16
		if(!isset($authorized) || empty($authorized)){
16
		if(!isset($authorized) || empty($authorized)){
-
 
17
			$method = $this->router->fetch_method();
-
 
18
			if(strcasecmp($method, 'wallet') == 0){
-
 
19
				$this->session->set_userdata('location','my-wallet');
-
 
20
			}elseif(strcasecmp($method, 'recharges') == 0){
-
 
21
				$this->session->set_userdata('location','my-recharges');
-
 
22
			}
17
			redirect(base_url().'auth/login');
23
			redirect(base_url().'auth/login');
18
		}
24
		}
19
		$this->layout->setlayout('layout/layout_main');
25
		$this->layout->setlayout('layout/layout_main');
20
		$this->load->model('myaccount_model');
26
		$this->load->model('myaccount_model');
21
		$this->layoutName= $this->layout->getLayout();
27
		$this->layoutName= $this->layout->getLayout();