Wiki

Articles tagged with "scopes", sorted by date (updated)X
Displaying 1-2 of 2 result(s).

Using updateAll and deleteAll with scopes

Updated 4 months ago by le_topHow-tos4 comments – viewed 6,569 times – ( +5 ) – version 1.1
Using CActiveRecord->updateAll() and CActiveRecord->deleteAll() with scopes and criteria requires some tricks that are explained in this article. While findAll() , find() and some other methods use scopes automatically, updateAll() and deleteAll() do not.

An easy way to use escopes and CActiveDataProvider

Updated 3 years ago by Rafael GarciaTips8 comments – viewed 22,352 times – ( +1 / -1 ) – version 1.1
Often used scopes to define criteria in our models. This is a very useful feature as it ensures that in any part of application applying the criteria defined by the scope when called it.