示例#1
0
文件: MPT.php 项目: techart/tao
 protected function setup()
 {
     $this->enable_dispatch()->dispatcher->add_subscriber(Tree_DB_MPT::EntitySubscriber($this));
     return parent::setup();
 }
示例#2
0
文件: ORM.php 项目: techart/tao
 public function setup()
 {
     parent::setup();
     if ($this->mapper) {
         $fields = $this->mapper->fields();
         if (is_array($fields)) {
             foreach ($fields as $field => $data) {
                 CMS_Fields::type($data)->init_value($field, $data, $this);
             }
         }
     }
     return $this;
 }