| 1 | <?php |
||
| 15 | trait RelationshipTrait |
||
| 16 | { |
||
| 17 | /** |
||
| 18 | * Defines an inverse one-to-one or many relationship. |
||
| 19 | * |
||
| 20 | * @var array |
||
| 21 | */ |
||
| 22 | protected $belongs_to = []; |
||
| 23 | |||
| 24 | /** |
||
| 25 | * @var array |
||
| 26 | */ |
||
| 27 | private $_with = []; |
||
| 28 | |||
| 29 | /** |
||
| 30 | * Returns the values from the model's properties. |
||
| 31 | * |
||
| 32 | * @param array $properties |
||
| 33 | * @return array |
||
| 34 | */ |
||
| 35 | 30 | public function getRelationshipProperties(array $properties) |
|
| 57 | |||
| 58 | /** |
||
| 59 | * Adds relationship/s to the model. |
||
| 60 | * |
||
| 61 | * @param string|array $relationships |
||
| 62 | * @return self |
||
| 63 | */ |
||
| 64 | 3 | public function with($relationships) |
|
| 76 | } |
||
| 77 |
An attempt at access to an undefined property has been detected. This may either be a typographical error or the property has been renamed but there are still references to its old name.
If you really want to allow access to undefined properties, you can define magic methods to allow access. See the php core documentation on Overloading.