<?php

namespace App\Http\Requests\V1\Company;

use Illuminate\Foundation\Http\FormRequest;

class CompanyRequestStoreRequest extends FormRequest
{
    public function authorize(): bool
    {
        return true;
    }

    public function rules(): array
    {
        return [
            'business_number' => 'required|string|min:10|max:13',
            'company_name' => 'required|string|max:200',
            'ceo_name' => 'nullable|string|max:50',
            'address' => 'nullable|string|max:300',
            'phone' => 'nullable|string|max:30',
            'email' => 'nullable|email|max:100',
            'message' => 'nullable|string|max:1000',
        ];
    }

    public function messages(): array
    {
        return [
            'business_number.required' => __('validation.required', ['attribute' => '사업자등록번호']),
            'company_name.required' => __('validation.required', ['attribute' => '회사명']),
        ];
    }
}
