Closed TudorStoica closed 10 years ago
Not sure if this is just me but for model.save() the success callback is not called.
Here is my model
var BookModel = Alloy.createModel("Book"); BookModel.set('name','test Book'); BookModel.save({ success : function(){ Ti.API.info('Success'); }, error : function(){ Ti.API.error("hmm - this is not good!"); } });
Thanks
You need to add a empty object as the first parameter
BookModel({}, {success: function(), error:function() });
That did it. Thanks
great :)
Not sure if this is just me but for model.save() the success callback is not called.
Here is my model
var BookModel = Alloy.createModel("Book"); BookModel.set('name','test Book'); BookModel.save({ success : function(){ Ti.API.info('Success'); }, error : function(){ Ti.API.error("hmm - this is not good!"); } });
Thanks