how to create list of object at client side and render in list view.

0
Hello,   i want to create multiple object at client side as follows.       when i click on add more button it create one form below the existing form, and when i click on save button to save all objects in database.   add more button create new object each time on client side, close button show on second object not the first object and click on close button object remove from the list.   any one having idea behind this how can i implement this
asked
1 answers
1

Hi Hiamnshu,

 

You can use a non-persistable entity with a many-to-many reference to the Address entity:

 

 

On the page you can use a listview to show all the objects.

When you add an address: Create an object and add it to the list

When you remove an address: Delete the object from the list

When you save the addresses: Retrieve all the address objects connected to the non-persistable entity and commit the list.

 

Hope this helps!

answered