예제 #1
0
파일: ORM.php 프로젝트: techart/tao
 public function __construct(DB_ORM_Mapper $parent = null)
 {
     parent::__construct($parent);
     CMS_ORM_Entity::$db = $this;
     CMS_Controller_Base::$db = $this;
     $this->cache = WS::env()->cache;
 }
예제 #2
0
파일: Controller.php 프로젝트: techart/tao
 /**
  * @return CMS_Controller
  */
 public function setup()
 {
     $name = CMS::$current_component_name;
     $this->name = $name;
     $this->mapper = CMS::$current_mapper;
     parent::setup()->use_urls_from(CMS::$current_mapper)->use_views_from("../app/components/{$name}/views")->use_views_from("../app/components/{$name}/app/views")->use_layout(CMS::$layouts[$name]);
     if (CMS::$print_version || is_object($this->env->pdf) && $this->env->pdf->active) {
         $this->use_layout(CMS::$print_layout);
     }
     return $this;
 }
예제 #3
0
파일: Index.php 프로젝트: techart/tao
 /**
  * @return CMS_Controller_Index
  */
 public function setup()
 {
     return parent::setup()->use_views_from(CMS::app_path('views'));
 }
예제 #4
0
파일: AdminIndex.php 프로젝트: techart/tao
 /**
  * @return CMS_Controller_Index
  */
 public function setup()
 {
     $this->auth_realm = CMS::$admin_realm;
     return parent::setup()->use_views_from('../app/views');
 }