Subversion Repositories SmartDukaan

Rev

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

Rev 13946 Rev 14098
Line 26... Line 26...
26
 * admin_index method
26
 * admin_index method
27
 *
27
 *
28
 * @return void
28
 * @return void
29
 */
29
 */
30
	public function admin_index() {
30
	public function admin_index() {
-
 
31
		$page = $this->request->query('page');
-
 
32
		if(!isset($page)){
-
 
33
			$page = 1;
-
 
34
		}
-
 
35
		$limit = Configure::read('admindashboardlimit');
-
 
36
		$offset = ($page - 1)*$limit;
31
		$url = $this->apihost."discountInfo/getAllSkuSchemeDetails";
37
		$url = $this->apihost."discountInfo/getAllSkuSchemeDetails/?limit=$limit&offset=$offset";
32
		$response = $this->make_request($url,null);
38
		$response = $this->make_request($url,null);
33
		$this->set('skuschemes',$response);
39
		$this->set('skuschemes',$response);
-
 
40
		$this->set('page',$page);
34
		// $this->Skuscheme->recursive = 0;
41
		// $this->Skuscheme->recursive = 0;
35
		// $this->set('skuschemes', $this->Paginator->paginate());
42
		// $this->set('skuschemes', $this->Paginator->paginate());
36
	}
43
	}
37
 
44
 
38
/**
45
/**