Yii framework reset defaultScope

798 views Asked by At

In Yii framework, how can I disable defaultScope ?

I tried with resetScope(false) and resetScope(true) but to no avail.

Any help would be really appreciated.

1

There are 1 answers

2
turutosiya On

you can disable defaultScode by overriding defaultScope() method and returning empty array.

public function defaultScope()
{
    return array();
}