Browse Source

暂时取消IP限制

sandm 2 days ago
parent
commit
e99434fa94

+ 5 - 5
libs/repositories/laravel-admin/src/Controllers/AuthController.php

@@ -56,11 +56,11 @@ class AuthController extends Controller
         $credentials = $request->only([$this->username(), 'password']);
         $remember = $request->get('remember', false);
 
-        if($credentials[$this->username()] == 'jjhc' && request()->ip() != '59.57.98.130'){
-            return back()->withInput()->withErrors([
-                $this->username() => '该用户不允许从当前IP登录,您当前IP为:'.request()->ip(),
-            ]);
-        }
+//        if($credentials[$this->username()] == 'jjhc' && request()->ip() != '59.57.98.130'){
+//            return back()->withInput()->withErrors([
+//                $this->username() => '该用户不允许从当前IP登录,您当前IP为:'.request()->ip(),
+//            ]);
+//        }
 
         /** @var \Illuminate\Validation\Validator $validator */
         $validator = Validator::make(