Commit e281b402 by Qiang Xue

...

parent ed513b4d
......@@ -16,7 +16,7 @@ namespace yii\db\dao;
* @author Qiang Xue <qiang.xue@gmail.com>
* @since 2.0
*/
class BaseQuery extends \yii\base\Object
class BaseQuery extends \yii\base\Component
{
/**
* @var string|array the columns being selected. This refers to the SELECT clause in a SQL
......
......@@ -25,7 +25,7 @@ class Customer extends ActiveRecord
{
return array(
'active' => function($q) {
return $q->andWhere('@.`status` = ' . Customer::STATUS_ACTIVE);
return $q->andWhere('@.`status` = ' . self::STATUS_ACTIVE);
},
);
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment