From 0b47d9a89275c071fe5ef9e5808f7a7a6ef5c39f Mon Sep 17 00:00:00 2001 From: Alexandr <258428@mail.ru> Date: Tue, 11 Mar 2014 12:22:31 +0700 Subject: [PATCH] small doc fix in active-record --- docs/guide/active-record.md | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/docs/guide/active-record.md b/docs/guide/active-record.md index 6a3df60..82d45aa 100644 --- a/docs/guide/active-record.md +++ b/docs/guide/active-record.md @@ -437,7 +437,7 @@ class Customer extends ActiveRecord .... public function getOrders() { - return $this->hasMany(Order::className, ['customer_id' => 'id']); + return $this->hasMany(Order::className(), ['customer_id' => 'id']); } } @@ -446,7 +446,7 @@ class Order extends ActiveRecord .... public function getCustomer() { - return $this->hasOne(Customer::className, ['id' => 'customer_id']); + return $this->hasOne(Customer::className(), ['id' => 'customer_id']); } } ``` @@ -477,7 +477,7 @@ class Customer extends ActiveRecord .... public function getOrders() { - return $this->hasMany(Order::className, ['customer_id' => 'id'])->inverseOf('customer'); + return $this->hasMany(Order::className(), ['customer_id' => 'id'])->inverseOf('customer'); } } ```