Project

General

Profile

Task #80319

Updated by Patrick Broens over 7 years ago

We have a booking form where a customer can add persons. For a person there is a page defined, with all fields. We do not know how many persons will be added, but at least one. For this we made a conditional page, where we look at a button value. If this button is clicked (instead of the regular submit button), a page will be added to the form, which is a copy of the "person" page. We already have a page with all the fields, so copying would be the best.  

 However, copying pages and elements is not possible, because the form element identifier can't be changed. It's protected and there is no method to change it, only to get it.  

 Although there are many constructs possible to get this done (subclassing all elements for instance) it is desired to do this at the most simple way. 

 Adding a public method @setIdentifier()@ to the @AbstractRenderable@ would be sufficient. 

Back