Subversion Repositories SmartDukaan

Rev

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

Rev 18246 Rev 18322
Line 1054... Line 1054...
1054
				}
1054
				}
1055
				$this->set(compact('cartskus'));
1055
				$this->set(compact('cartskus'));
1056
			}
1056
			}
1057
		}else{
1057
		}else{
1058
			$userId = $this->request->query('user_id');
1058
			$userId = $this->request->query('user_id');
-
 
1059
			$disable = $this->request->query('disable');
-
 
1060
			$disablePage = false;
-
 
1061
			if(isset($disable)){
-
 
1062
				$disablePage = true;
-
 
1063
			}
1059
			if(!(isset($_COOKIE['s_cart']))) {
1064
			if(!(isset($_COOKIE['s_cart']))) {
1060
				$this->loadModel('UserAccount');
1065
				$this->loadModel('UserAccount');
1061
				$options = array('conditions'=>array('user_id'=>$userId,'account_type'=>'cartId'),'recursive'=>-1,'fields'=>'account_key');
1066
				$options = array('conditions'=>array('user_id'=>$userId,'account_type'=>'cartId'),'recursive'=>-1,'fields'=>'account_key');
1062
				$cartId = $this->UserAccount->find('first',$options);
1067
				$cartId = $this->UserAccount->find('first',$options);
1063
				$scartId = $cartId['UserAccount']['account_key'];
1068
				$scartId = $cartId['UserAccount']['account_key'];
Line 1110... Line 1115...
1110
			}else{
1115
			}else{
1111
				if(strpos($cartskus['estimateString'],"Can't ship here")===false){
1116
				if(strpos($cartskus['estimateString'],"Can't ship here")===false){
1112
					setcookie('s_pincode', base64_encode($cartskus['pincode']), -1, '/');
1117
					setcookie('s_pincode', base64_encode($cartskus['pincode']), -1, '/');
1113
				}
1118
				}
1114
				$this->set(compact('cartskus'));
1119
				$this->set(compact('cartskus'));
-
 
1120
				if($disablePage){
-
 
1121
					$this->set('disablePage',$disablePage);
-
 
1122
					$this->render('/Users/cartdetails_disabled');
-
 
1123
				}
1115
			}
1124
			}
1116
		}
1125
		}
1117
		
1126
		
1118
	}
1127
	}
1119
}
1128
}