contributte / forms-multiplier

:repeat: Form multiplier & replicator for Nette Framework
https://contributte.org/packages/contributte/forms-multiplier.html
MIT License
26 stars 21 forks source link

event onCreate is not called on new container #21

Closed ajaxovic closed 6 years ago

ajaxovic commented 6 years ago

Simple code:

$form['registerConfigForm']->onCreate[] = function (Nette\Forms\Container $container) { $container['item_id']->setValue($id++); };

It fills correctly field item_id, but when you want to add another container with button $multiplier->addCreateButton('Create');, field item_id is not filled.