Subversion Repositories SmartDukaan

Rev

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

Rev 20012 Rev 20015
Line 414... Line 414...
414
		$page = $this->request->query('page');
414
		$page = $this->request->query('page');
415
		if(!isset($page)){
415
		if(!isset($page)){
416
			$page = 1;
416
			$page = 1;
417
		}
417
		}
418
		if($filtertype == 'below1000'){
418
		if($filtertype == 'below1000'){
419
			$url = $this->apihost."deals/".$user_id."?categoryId=".$id."&limit=20&offset=0&filterData=priceFilter:0^1000&direction=1";
419
			$url = $this->apihost."deals/".$user_id."?categoryId=".$id."&limit=20&offset=0&filterData=priceFilter:0^1000&sort=available_price&direction=1";
420
		}elseif($filtertype == 'exclusive'){
420
		}elseif($filtertype == 'exclusive'){
421
			$url = $this->apihost."getDealsByType?categoryId=".$id."&offset=0&limit=20&type=".$filtertype;
421
			$url = $this->apihost."getDealsByType?categoryId=".$id."&offset=0&limit=20&type=".$filtertype;
422
		}
422
		}
423
		
423
		
424
		$response = $this->make_request($url,null);
424
		$response = $this->make_request($url,null);
Line 471... Line 471...
471
		$limit = 20;
471
		$limit = 20;
472
		$offset = ($page - 1)*$limit;
472
		$offset = ($page - 1)*$limit;
473
		
473
		
474
		$likedDeals = $disLikedDeals = array();
474
		$likedDeals = $disLikedDeals = array();
475
		if($filtertype == 'below1000'){
475
		if($filtertype == 'below1000'){
476
			$url = $this->apihost."deals/".$user_id."?categoryId=".$id."&limit=".$limit."&offset=".$offset."&filterData=priceFilter:0^1000&direction=1";
476
			$url = $this->apihost."deals/".$user_id."?categoryId=".$id."&limit=".$limit."&offset=".$offset."&filterData=priceFilter:0^1000&sort=available_price&direction=1";
477
		}elseif($filtertype == 'exclusive'){
477
		}elseif($filtertype == 'exclusive'){
478
			$url = $this->apihost."getDealsByType?categoryId=".$id."&type=".$filtertype."&limit=".$limit."&offset=".$offset;
478
			$url = $this->apihost."getDealsByType?categoryId=".$id."&type=".$filtertype."&limit=".$limit."&offset=".$offset;
479
		}
479
		}
480
// 		$url = $this->apihost."getDealsByType?categoryId=".$id."&type=".$filtertype."&limit=".$limit."&offset=".$offset;
480
// 		$url = $this->apihost."getDealsByType?categoryId=".$id."&type=".$filtertype."&limit=".$limit."&offset=".$offset;
481
		$response = $this->make_request($url,null);
481
		$response = $this->make_request($url,null);