yiisoft/yii — pull request #1368 by sucotronic (2012-09-10 07:43:38+00:00)
Title: Fix for total item count not providing alias to defaultScopes of a model

When the function calculateTotalItemCount of the CActiveDataProvider is called, it doesn't take into account that the criteria passed to CActiveDataProvider could change the "alias", and in the defaultScope of the target model also could be a call to the function "getTableAlias" and put the wrong alias to a condition.