1
0

提交代码

This commit is contained in:
2020-08-06 14:45:56 +08:00
commit 9d0d5f4be9
361 changed files with 36445 additions and 0 deletions

View File

@@ -0,0 +1,17 @@
<?php
namespace App\Agent\Middleware;
use Auth;
use Closure;
class Authenticate
{
public function handle($request, Closure $next)
{
if (Auth::guard('agent')->guest()) {
return redirect()->route('Agent.login');
}
return $next($request);
}
}

View File

@@ -0,0 +1,24 @@
<?php
namespace App\Agent\Middleware;
use Illuminate\Foundation\Http\Middleware\VerifyCsrfToken as Middleware;
class VerifyCsrfToken extends Middleware
{
/**
* Indicates whether the XSRF-TOKEN cookie should be set on the response.
*
* @var bool
*/
protected $addHttpCookie = true;
/**
* The URIs that should be excluded from CSRF verification.
*
* @var array
*/
protected $except = [
'notify/payment', 'agent/notify/payment',
];
}