Example #1
0
 /**
  * Overrides the method to handle scopes.
  *
  * @inheritdoc
  */
 public function __get($property)
 {
     $method = 'scope_' . $property;
     if (method_exists($this, $method)) {
         return $this->{$method}(new Query($this));
     }
     return parent::__get($property);
 }