style: Laravel Pint 코드 포맷팅 적용
- PSR-12 스타일 가이드 준수 - 302개 파일 스타일 이슈 자동 수정 - 코드 로직 변경 없음 (포맷팅만)
This commit is contained in:
@@ -1,19 +1,23 @@
|
||||
<?php
|
||||
|
||||
namespace App\Http\Requests\Common;
|
||||
|
||||
use Illuminate\Foundation\Http\FormRequest;
|
||||
|
||||
class PaginateRequest extends FormRequest
|
||||
{
|
||||
public function authorize(): bool { return true; }
|
||||
public function authorize(): bool
|
||||
{
|
||||
return true;
|
||||
}
|
||||
|
||||
public function rules(): array
|
||||
{
|
||||
return [
|
||||
'page' => 'nullable|integer|min:1',
|
||||
'size' => 'nullable|integer|min:1|max:100',
|
||||
'q' => 'nullable|string|max:100',
|
||||
'sort' => 'nullable|string|in:id,code,name,created_at',
|
||||
'page' => 'nullable|integer|min:1',
|
||||
'size' => 'nullable|integer|min:1|max:100',
|
||||
'q' => 'nullable|string|max:100',
|
||||
'sort' => 'nullable|string|in:id,code,name,created_at',
|
||||
'order' => 'nullable|string|in:asc,desc',
|
||||
];
|
||||
}
|
||||
@@ -21,9 +25,10 @@ public function rules(): array
|
||||
public function validatedOrDefaults(): array
|
||||
{
|
||||
$v = $this->validated();
|
||||
$v['page'] = $v['page'] ?? 1;
|
||||
$v['size'] = $v['size'] ?? 20;
|
||||
$v['page'] = $v['page'] ?? 1;
|
||||
$v['size'] = $v['size'] ?? 20;
|
||||
$v['order'] = $v['order'] ?? 'desc';
|
||||
|
||||
return $v;
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user