/** * @return \yii\db\ActiveQuery */ public function getNote() { return $this->hasOne(DeliveryNote::className(), ['id' => 'note_id']); }
/** * @return \yii\db\ActiveQuery */ public function getDeliveryNotes() { return $this->hasMany(DeliveryNote::className(), ['prepare_id' => 'id']); }
/** * @return \yii\db\ActiveQuery */ public function getDeliveryNotes() { return $this->hasMany(DeliveryNote::className(), ['work_order_id' => 'id']); }
/** * @return Delivery Note */ public function getDeliveryNotes() { return $this->hasMany(DeliveryNote::className(), ['prepare_id' => 'id'])->via('orderPreparations'); }