- 마이그레이션: barobill_settings, tax_invoices 테이블 생성 - 모델: BarobillSetting (인증서 암호화), TaxInvoice (상태/유형 상수) - 서비스: BarobillService (API 연동), TaxInvoiceService (CRUD, 발행/취소) - 컨트롤러: BarobillSettingController, TaxInvoiceController - FormRequest: 6개 요청 검증 클래스 - Swagger: API 문서 완성 (BarobillSettingApi, TaxInvoiceApi)
32 lines
1.1 KiB
PHP
32 lines
1.1 KiB
PHP
<?php
|
|
|
|
namespace App\Http\Requests\TaxInvoice;
|
|
|
|
use App\Models\Tenants\TaxInvoice;
|
|
use Illuminate\Foundation\Http\FormRequest;
|
|
use Illuminate\Validation\Rule;
|
|
|
|
class TaxInvoiceListRequest extends FormRequest
|
|
{
|
|
public function authorize(): bool
|
|
{
|
|
return true;
|
|
}
|
|
|
|
public function rules(): array
|
|
{
|
|
return [
|
|
'per_page' => ['nullable', 'integer', 'min:1', 'max:100'],
|
|
'direction' => ['nullable', 'string', Rule::in(TaxInvoice::DIRECTIONS)],
|
|
'status' => ['nullable', 'string', Rule::in(TaxInvoice::STATUSES)],
|
|
'invoice_type' => ['nullable', 'string', Rule::in(TaxInvoice::INVOICE_TYPES)],
|
|
'issue_type' => ['nullable', 'string', Rule::in(TaxInvoice::ISSUE_TYPES)],
|
|
'issue_date_from' => ['nullable', 'date'],
|
|
'issue_date_to' => ['nullable', 'date', 'after_or_equal:issue_date_from'],
|
|
'corp_num' => ['nullable', 'string', 'max:20'],
|
|
'corp_name' => ['nullable', 'string', 'max:100'],
|
|
'nts_confirm_num' => ['nullable', 'string', 'max:24'],
|
|
];
|
|
}
|
|
}
|