This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Backbone.Marionette.TemplateCache.preloadTemplate = function (templateId, context) { | |
// preload a single template | |
var loader = $.Deferred(); | |
var that = this; | |
var msg; | |
var err; | |
if (!templateId || templateId.length == 0) { | |
err = new Error('No templateId was specified - please provide a valid template id or filename.'); | |
err.name = "NoTemplateSpecified"; | |
throw err; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
//This is my 'Save' handler in a view... | |
saveRequested: function () { | |
this.model.save({ | |
success: function () { | |
put('saved'); <-- never gets here, even when response is 200/OK | |
this.close(); | |
}, | |
error: function () { | |
put('error'); | |
} |
NewerOlder