genieblog.ch
Setting the default value of a Symfony FormType nested in CollectionType
There are a few proposed ways to hack a default value to form fields. The problen gets bigger when handling CollectionTypes, as the underlying objects don’t get constructed automatically. Workarounds are numerous, e.g. simply setting prototype_data on the CollectionType to an instantiated object. Unfortunately, for me, not one of these worked out when working with […]