<?php

namespace App\Classes\Modules\Banks\Standards\Validators;

use App\Classes\General\Abstracts\AbstractValidation;
use App\Classes\Modules\Banks\DataTransferObjects\BankObject;

class BankValidation extends AbstractValidation
{
    /**
     * @param BankObject $object
     * @return array
     */
    protected function data($object): array 
    {
        return [
            'country_id' => $object->getCountryId(),
            'company_id' => $object->getCompanyId(),
            'bank_name' => $object->getBankName(),
            'holder_name' => $object->getHolderName(),
            'account_no' => $object->getAccountNo()
        ];
    }

    /**
     * @return array
     */
    protected function rules(): array 
    {
        return [
            'country_id' => 'required',
            'company_id' => 'required',
            'bank_name' => 'required',
            'holder_name' => 'required',
            'account_no' => 'required'
        ];
    }

    /**
     * @return array
     */
    protected function messages(): array 
    {
        return [];
    }
}