I am working on an web app which contains form page.
mandi_detail:[{
name: String,
mandi_correspondent_detail:[{
name:String,
contact:[Number]
}]
}]
this is the model of a schema, i have made a ui page, in which in mandi_detail i can add multiple mandi dynamically .
In each mandi, we have name and mandi_correspondent_detail. we can add multiple mandi_correspondent_detail dynamically.
Each mandi_correspondent_detail consist name and contact number and we can add multiple numbers by number field dynamically.
how to get the posted data in controller so that i am able to insert it in schema in mongodb.
Your view should be build according to your controller's data. This way you'll use
two way binding
and everything will be up to dateExample:
In your
controller
In your
view
This way you can use
myData
array to store everything in yourDB