fix : 언어팩 추가 및 내용 추가

This commit is contained in:
2025-08-25 17:26:20 +09:00
parent fe7d761bf6
commit 6307fdc1dc
4 changed files with 159 additions and 4 deletions

35
lang/en/error.php Normal file
View File

@@ -0,0 +1,35 @@
<?php
declare(strict_types=1);
/**
* System/Domain error messages (client-facing, fixed strings)
* - Not DB-driven
* - Used in global handler/service exceptions
* - Example: throw new NotFoundHttpException(__('error.not_found'));
*/
return [
// 4xx Common
'not_found' => 'The requested URI or data was not found.', // 404
'tenant_id' => 'No active tenant is set.', // 400 (Service::tenantId() missing)
'unauthenticated' => 'Authentication failed.', // 401
'forbidden' => 'You do not have permission for this request.', // 403
'bad_request' => 'Invalid request.', // 400
// Validation / Parameters
'validation_failed' => 'Request data validation failed.', // 422
'missing_parameter' => 'A required parameter is missing.', // 400
// Resource-specific (optional, with :resource placeholder)
'not_found_resource' => ':resource could not be found.', // 404
// Business rules
'duplicate' => 'Duplicate data exists.',
'conflict' => 'The request conflicts with the current state.', // 409
'state_invalid' => 'The current state does not allow this operation.', // 400/409
// Server errors
'server_error' => 'An internal server error occurred.', // 5xx
];