/
githubmirror
/
symfony
Обзор
Документация
Войти
/
githubmirror
/
symfony
Код
Запросы
0
Пакеты
0
Релизы
0
Аналитика
Безопасность
8.2
src/Symfony/Component/Form/SubmitButton.php
49 строк
1 KB
Grégoire Pineau
[CS] Remove @inheritdoc PHPDoc
25 авг 2022, 18:27
25 авг 2022, 18:27
015d501
Код
Авторство
О чём код?
<?php /* * This file is part of the Symfony package. * * (c) Fabien Potencier <fabien@symfony.com> * * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ namespace Symfony\Component\Form; /** * A button that submits the form. * * @author Bernhard Schussek <bschussek@gmail.com> */ class SubmitButton extends Button implements ClickableInterface { private bool $clicked = false; public function isClicked(): bool { return $this->clicked; } /** * Submits data to the button. * * @return $this * * @throws Exception\AlreadySubmittedException if the form has already been submitted */ public function submit(array|string|null $submittedData, bool $clearMissing = true): static { if ($this->getConfig()->getDisabled()) { $this->clicked = false; return $this; } parent::submit($submittedData, $clearMissing); $this->clicked = null !== $submittedData; return $this; } }