You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
|
|
|
|
_.extend(Marionette.TemplateCache.prototype, {
|
|
|
|
|
|
|
|
|
|
loadTemplate: function (templateId) {
|
|
|
|
|
|
|
|
|
|
var template = "<div class='alert alert-error'>TEMPLATE [" + templateId + "] NOT FOUND</div>";
|
|
|
|
|
|
|
|
|
|
jQuery.ajax({
|
|
|
|
|
url: 'Backbone.NzbDrone//' + templateId + '.html',
|
|
|
|
|
async: false
|
|
|
|
|
|
|
|
|
|
}).done(function (data) {
|
|
|
|
|
template = data;
|
|
|
|
|
|
|
|
|
|
}).fail(function (data) {
|
|
|
|
|
console.log("couldn't load template " + this.templateId + " Error: " + data.statusText);
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
return template;
|
|
|
|
|
}
|
|
|
|
|
});
|