Subversion Repositories SmartDukaan

Rev

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

Rev 16591 Rev 16717
Line 10... Line 10...
10
 * @package       app.Controller
10
 * @package       app.Controller
11
 * @link http://book.cakephp.org/2.0/en/controllers.html#the-app-controller
11
 * @link http://book.cakephp.org/2.0/en/controllers.html#the-app-controller
12
 */
12
 */
13
class AppController extends Controller {
13
class AppController extends Controller {
14
 
14
 
15
	public $limit;
-
 
16
	public $apihost;
15
	public $apihost;
17
	public $acls;
-
 
18
 
16
 
19
	public $components = array(
17
	public $components = array(
20
		'Session','Cookie',
18
		'Session','Cookie',
21
		'Auth' => array(
19
		'Auth' => array(
22
			'loginAction' => array('controller' => 'users', 'action' => 'login'),
20
			'loginAction' => array('controller' => 'users', 'action' => 'login'),
Line 42... Line 40...
42
				Configure::load('staging');
40
				Configure::load('staging');
43
				break;
41
				break;
44
			default:
42
			default:
45
			case 'www.apprub.com':
43
			case 'www.apprub.com':
46
			case 'apprub.com':
44
			case 'apprub.com':
47
			case 'api.apprub.com':
-
 
48
				Configure::load('live');
45
				Configure::load('live');
49
				break;
46
				break;
50
		}
47
		}
51
		
48
		
52
		if(isset($this->params['admin'])) {
49
		if(isset($this->params['admin'])) {
53
			$this->layout = 'admin';
50
			$this->layout = 'admin';
54
		}	
51
		}	
55
		$this->apihost = Configure::read('pythonapihost');
52
		$this->apihost = Configure::read('apihost');
56
		$this->limit = Configure::read('dealsperpage');	
53
		// $this->limit = Configure::read('dealsperpage');	
57
		$staticVersion = Configure::read('staticversion');
54
		$staticVersion = Configure::read('staticversion');
58
		$this->set('staticversion',$staticVersion);
55
		$this->set('staticversion',$staticVersion);
59
    }
56
    }
60
	
57
	
61
    function isAuthorized() {
58
    function isAuthorized() {