123456789101112131415161718192021222324252627282930313233343536373839404142434445 |
- <?php
- namespace common\models\query;
- use common\enums\StatusEnum;
- class FootprintQuery extends \yii\db\ActiveQuery
- {
- public function active()
- {
- return $this->andWhere(['status' => StatusEnum::STATUS_ON]);
- }
-
- public function my()
- {
- return $this->andWhere(['user_id' => \Yii::$app->user->id]);
- }
-
- public function all($db = null)
- {
- return parent::all($db);
- }
-
- public function one($db = null)
- {
- return parent::one($db);
- }
- }
|