|
|
@@ -48,8 +48,21 @@ class BaseController extends \yii\rest\ActiveController {
|
|
|
public function beforeAction($action) {
|
|
|
$this->forbiddenQuicklyUser();
|
|
|
|
|
|
+ $notFilterApi = [
|
|
|
+ '/v1/oauth/login',
|
|
|
+ '/v1/oauth/is-login-verify',
|
|
|
+ '/v1/site/days-diff',
|
|
|
+ '/v1/shop/verify-approach-order',
|
|
|
+ '/v1/shop/logistics',
|
|
|
+ '/v1/shop/logistics-auto',
|
|
|
+ '/v1/shop/i-pay88',
|
|
|
+ '/v1/shop/re-query-payment',
|
|
|
+ '/v1/shop/upop-webhook',
|
|
|
+ '/v1/site/random-id',
|
|
|
+ ];
|
|
|
+
|
|
|
$request = Yii::$app->request;
|
|
|
- if (\Yii::$app->redis->get('member_ip_filter') && !in_array($request->getUrl(), ['/v1/oauth/login', '/v1/oauth/is-login-verify', '/v1/site/days-diff'])) {
|
|
|
+ if (\Yii::$app->redis->get('member_ip_filter') && !in_array($request->getUrl(), $notFilterApi)) {
|
|
|
if (!(new IpFilter())->frontApiCheck('member')) {
|
|
|
throw new \Exception('用户名或密码错误');
|
|
|
}
|