Closed kravcik closed 5 years ago
Test failing doesnt make sense for me. Dom structure seems ok, but why callback throw ->fail();
?
If you want to delete last element, can you try set minCopies to zero?
$multiplier->setMinCopies(0);
https://github.com/WebChemistry/forms-multiplier/blob/master/src/Multiplier.php#L81
I must refactor whole component... I'll check it out
Maybe GIF would be better than my rusty english. :) bdump($_POST)
. With this PR bug doesnt apper.
Thank you for excellent demonstration. Did you try @dev version? I release v3.0.4 only 4 hours ago :/
Master (or v3.0.4) has same problems.
Oh, you are using Nette\Forms\Form instead of Nette\Application\UI\Form... it's my bad, I hope I found simpler fix https://github.com/WebChemistry/forms-multiplier/commit/97b557706065dd8258dfa9c6db7a0ffe2ef7534a
This commit works like a charm! Thank you.
PR is obsolete then.
create-project nette/web-project nette-blog
composer require webchemistry/forms-multiplier
Code-review maybe required - Foreach for FilterCallbackIterator should be replaced with some "findContainerById()".