#feature: add ip operation log & sql generator
This commit is contained in:
@@ -13,12 +13,19 @@ return Application::configure(basePath: dirname(__DIR__))
|
||||
health: '/up',
|
||||
)
|
||||
->withMiddleware(function (Middleware $middleware): void {
|
||||
$middleware->alias([
|
||||
'admin.ip' => \App\Http\Middleware\AdminIpMiddleware::class,
|
||||
]);
|
||||
|
||||
$middleware->appendToGroup('api', \App\Http\Middleware\OperationLogMiddleware::class);
|
||||
|
||||
// 为 API 路由添加 CSRF 豁免
|
||||
$middleware->validateCsrfTokens(except: [
|
||||
'api/jira/*',
|
||||
'api/env/*',
|
||||
'api/message-sync/*',
|
||||
'api/message-dispatch/*'
|
||||
'api/message-dispatch/*',
|
||||
'api/admin/*',
|
||||
]);
|
||||
})
|
||||
->withExceptions(function (Exceptions $exceptions): void {
|
||||
|
||||
Reference in New Issue
Block a user