OEModule\OphCoCvi\models\Element_OphCoCvi_Demographics::relations PHP Method

relations() public method

public relations ( ) : array
return array relational rules.
    public function relations()
    {
        return array('element_type' => array(self::HAS_ONE, 'ElementType', 'id', 'on' => "element_type.class_name='" . get_class($this) . "'"), 'eventType' => array(self::BELONGS_TO, 'EventType', 'event_type_id'), 'event' => array(self::BELONGS_TO, 'Event', 'event_id'), 'user' => array(self::BELONGS_TO, 'User', 'created_user_id'), 'usermodified' => array(self::BELONGS_TO, 'User', 'last_modified_user_id'), 'gender' => array(self::BELONGS_TO, 'Gender', 'gender_id'), 'ethnic_group' => array(self::BELONGS_TO, 'EthnicGroup', 'ethnic_group_id'));
    }