Attribute::relations PHP Method

relations() public method

public relations ( ) : array
return array
    public function relations()
    {
        return ['options' => [self::HAS_MANY, 'AttributeOption', 'attribute_id', 'order' => 'options.position ASC'], 'group' => [self::BELONGS_TO, 'AttributeGroup', 'group_id'], 'value' => [self::BELONGS_TO, 'AttributeValue', 'attribute_id'], 'types' => [self::HAS_MANY, 'TypeAttribute', 'attribute_id']];
    }