/** * @return \yii\db\ActiveQuery */ public function getContents() { return $this->hasMany(Content::className(), ['product_id' => 'id']); }
/** * @return \yii\db\ActiveQuery */ public function getContentDevices() { return $this->hasMany(Content::className(), ['owner_id' => 'id']); }