?? GreyFile — Mystic File Browser

Current path: home/webdevt/cryptoimpot.fr/module/Application/src/Form/



?? Go up: /home/webdevt/cryptoimpot.fr/module/Application/src

?? Viewing: ExchangeFieldset.php

<?php

namespace Application\Form;

use Application\Entity\Exchange;
use Laminas\Form\Fieldset;
use Laminas\InputFilter\InputFilterProviderInterface;
use Laminas\Hydrator\ClassMethods as ClassMethodsHydrator;

class ExchangeFieldset extends Fieldset implements InputFilterProviderInterface
{
    public function __construct()
    {
        parent::__construct('exchange');

        $this->setHydrator(new ClassMethodsHydrator(false));
        $this->setObject(c);

        $this->setLabel('Exchange');

        $this->add([
            'name' => 'name',
            'options' => [
                'label' => 'Name of the exchange',
            ],
            'attributes' => [
                'required' => 'required',
            ],
        ]);
    }

    /**
     * @return array
     */
    public function getInputFilterSpecification()
    {
        return [
            'name' => [
                'required' => true,
            ],
        ];
    }
}


??

??