kelp404 / angular-form-builder

Drag and drop to build bootstrap forms in AngularJS.
http://kelp404.github.io/angular-form-builder/
MIT License
599 stars 340 forks source link

Binding the values to the form #102

Open vikaswizorbit opened 7 years ago

vikaswizorbit commented 7 years ago

Hello

I am able to create a form using the form builder. I have save the form in the db.

Now I am able to open up the saved form and enter the response in those fields. I am also able save the response also in the db.

Now I want to bind the form with the saved values.

I have create a API to get the form definition json as well as response JSON.

Please Let me know how to bind the values to the form

Check the attached file for the details of the form definition json as well as response json SampleJSON.txt

ghost commented 7 years ago

@vikaswizorbit I am able to create the form using the form builder and got the json out for that form

[{"component":"textInput","editable":true,"index":0,"label":"Label","description":"description","placeholder":"Enter Label For Metered Data","options":[],"required":false,"validation":"/.*/"},{"component":"textInput","editable":true,"index":1,"label":"Value","description":"description","placeholder":"Enter Value","options":[],"required":false,"validation":"/.*/"},{"component":"select","editable":true,"index":2,"label":"Select","description":"description","placeholder":"placeholder","options":["KB","MB","GB"],"required":false,"validation":"/.*/"}]

can you please share the code for displaying the form again with this data

delchev commented 3 years ago

https://github.com/kelp404/angular-form-builder/issues/91