maccman/spine.todos — Issue #5: Missing jQuery selector in javascript version
Author: CaptainQuirk
Created: 2011-11-30 16:00:09+00:00
State: open

The TaskApp::create() function should be like this :

create : function(e){
e.preventDefault();
console.log ( this ) ;
Task.create({name:this.$("input").val()});
this.$("input").val("");
} ,

rather than

create : function(e){
e.preventDefault();
console.log ( this ) ;
Task.create({name:this.input.val()});
this.input.val("");
} ,

where the jQuery selector is missing causing an error to be thrown when trying to access undefined "input" property of this