[s]hi there,
I hope that working with scopes and find/findAll can more flexible together with dbcriteria. When did a test on these codes, it seems like the criteria in scopes and the criteria parameterize in findAll are not merged when querying. Please tell me if there is a way to be done.
Thank you.
Example:
In CActiveRecord:
public function scopes() {
return array(
'published' => array(
'condition' => 't.deleted IS NULL',
'limit' => 100,
'order' => 'name DESC',
),
);
}
$criteria = new CDbCriteria();
$criteria->offset = 10;
$records = Post::model()->published()->findAll($criteria);
[/s]