Subversion Repositories SmartDukaan

Rev

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

Rev 14825 Rev 14891
Line 28... Line 28...
28
		$this->set('title_for_layout','Profittill Bookmarklet');
28
		$this->set('title_for_layout','Profittill Bookmarklet');
29
	}
29
	}
30
 
30
 
31
	public function mywallet() {
31
	public function mywallet() {
32
		$userId = $this->request->query('user_id');
32
		$userId = $this->request->query('user_id');
-
 
33
		$tokenValidated = $this->checkToken();
33
		if(isset($userId) && !empty($userId)){	
34
		if(isset($userId) && !empty($userId) && $tokenValidated){	
34
			$next = "/my-wallet";					
35
			$next = "/my-wallet";					
35
			$redirectUrl = $this->getAutoLoginUrl($userId,$next);
36
			$redirectUrl = $this->getAutoLoginUrl($userId,$next);
36
			header('location:'.$redirectUrl);
37
			header('location:'.$redirectUrl);
37
			exit();
38
			exit();
-
 
39
		}else{
-
 
40
			$this->redirect(array('controller'=>'special','action'=>'native','login'));
38
		}
41
		}
39
	}
42
	}
40
 
43
 
41
	public function socialauth() {
44
	public function socialauth() {
42
		$this->layout = "ajax";
45
		$this->layout = "ajax";