powmedia / backbone-forms

Form framework for BackboneJS with nested forms, editable lists and validation
MIT License
2.17k stars 413 forks source link

Form inside master view(master view is having submit button) #341

Closed hiddenl00p closed 10 years ago

hiddenl00p commented 10 years ago

I have a collection view and on add New I render backbone form following is the code

newrecord:function(){

      var form = new Backbone.Form({
       model: task

  });
     $('#form', this.el).append(form.render().el);  

} and here is my template:

and on click of submit button i am getting following error ``` Uncaught TypeError: Object # has no method 'getValue' ``` submit:function(){ ``` var data = form.getValue(); } ``` This is happening only when i insert my form inside collection view.If i append form directly then it works fine. But i want to keep it in the collection form. Any ideas???
powmedia commented 10 years ago

Closing as duplicate of #342