/** * @return \yii\db\ActiveQuery */ public function getParent() { return $this->hasOne(CustomerEntity::className(), ['entity_id' => 'parent_id']); }
/** * @return \yii\db\ActiveQuery */ public function getCustomer() { return $this->hasOne(CustomerEntity::className(), ['entity_id' => 'customer_id']); }