class School extends ActiveRecord\Model }
class Person extends ActiveRecord\Model {
static $belongs_to = array(
array('school')
);
}
Example using options:
class School extends ActiveRecord\Model }
class Person extends ActiveRecord\Model {
static $belongs_to = array(
array('school', 'primary_key' => 'school_id')
);
}
파일 보기
프로젝트 열기: jpfuentes2/php-activerecord
메소드 | 설명 | |
---|---|---|
__construct ( $options = [] ) | ||
__get ( $name ) | ||
load ( activerecord\Model $model ) | ||
load_eagerly ( $models = [], $attributes, $includes, |
public load_eagerly ( $models = [], $attributes, $includes, |
||
$table |