<?php
namespace App\Http\Requests;use Illuminate\Foundation\Http\FormRequest;
class PayoutRequest extends FormRequest {public function authorize():bool{return $this->user()?->can('payout.process')??false;}public function rules():array{return ['code'=>['required','string','max:255'],'recipient_presented_name'=>['required','string','min:3','max:80','regex:/^[\pL\s\'\-]+$/u'],'recipient_id_type'=>['required','string','max:30'],'recipient_id_number'=>['required','alpha_num','min:5','max:30'],'recipient_phone'=>['nullable','string','regex:/^\+[1-9]\d{7,14}$/'],'note'=>['nullable','string','max:500'],'confirm'=>['required','accepted']];}}
