From b227c4b2d7b2f0ddefd41535a311c905d803ab09 Mon Sep 17 00:00:00 2001 From: barton Date: Mon, 29 Oct 2018 13:19:09 +0100 Subject: [PATCH] Validation scope for create button --- src/Container.php | 1 + 1 file changed, 1 insertion(+) diff --git a/src/Container.php b/src/Container.php index bf5f190..7c27703 100644 --- a/src/Container.php +++ b/src/Container.php @@ -487,6 +487,7 @@ public static function register(string $methodName = 'addDynamic') }); SubmitButton::extensionMethod('addCreateOnClick', function (SubmitButton $_this, bool $allowEmpty = false, $callback = null, array $snippets = []) { + $_this->setValidationScope(false); $_this->onClick[] = function (SubmitButton $button) use ($allowEmpty, $callback, $snippets) { /** @var Container $replicator */ $replicator = $button->lookup(__NAMESPACE__ . '\Container');