123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051 |
- <?php
- namespace api\modules\v1\controllers;
- use abei2017\wx\Application;
- use abei2017\wx\mini\qrcode\Qrcode;
- use api\common\behaviors\QueryParamAuth;
- use api\common\controllers\Controller;
- use api\common\models\User;
- use api\modules\v1\models\UserEditForm;
- use common\enums\CodeEnum;
- use common\models\Store;
- use common\models\Voice;
- use common\modules\attachment\models\Attachment;
- use Yii;
- use yii\base\Exception;
- use yii\helpers\ArrayHelper;
- use yii\web\NotFoundHttpException;
- use yii\web\ServerErrorHttpException;
- class UserController extends Controller
- {
- public function behaviors()
- {
- return ArrayHelper::merge(parent::behaviors(), [
- [
- 'class' => QueryParamAuth::className(),
- 'tokenParam' => 'token',
- ]
- ]);
- }
-
- public function actionRefresh()
- {
- return ['data' => User::findOne(Yii::$app->user->id)];
- }
- }
|