Fixed alignment issues and better rendering for add cards

pull/4/head
Mark McDowall 12 years ago
parent 6522b38584
commit 224ef64e6e

@ -14,8 +14,8 @@ define(['app',
'click .x-add-card': '_openSchemaModal' 'click .x-add-card': '_openSchemaModal'
}, },
onAfterItemAdded: function () { onRender: function () {
this.$itemViewContainer.find('.x-add-card').parent('li').remove(); this.listenTo(this.collection, 'add', this.render);
this.templateFunction = Marionette.TemplateCache.get('Settings/Indexers/AddCardTemplate'); this.templateFunction = Marionette.TemplateCache.get('Settings/Indexers/AddCardTemplate');
var html = this.templateFunction(); var html = this.templateFunction();

@ -14,8 +14,8 @@ define([
'click .x-add-card': '_openSchemaModal' 'click .x-add-card': '_openSchemaModal'
}, },
onAfterItemAdded: function () { onRender: function () {
this.$itemViewContainer.find('.x-add-card').parent('li').remove(); this.listenTo(this.collection, 'add', this.render);
this.templateFunction = Marionette.TemplateCache.get('Settings/Notifications/AddCardTemplate'); this.templateFunction = Marionette.TemplateCache.get('Settings/Notifications/AddCardTemplate');
var html = this.templateFunction(); var html = this.templateFunction();

@ -16,8 +16,8 @@ define(['app',
'click .x-add-card': '_addProfile' 'click .x-add-card': '_addProfile'
}, },
onAfterItemAdded: function () { onRender: function () {
this.$itemViewContainer.find('.x-add-card').parent('li').remove(); this.listenTo(this.collection, 'add', this.render);
this.templateFunction = Marionette.TemplateCache.get('Settings/Quality/Profile/AddCardTemplate'); this.templateFunction = Marionette.TemplateCache.get('Settings/Quality/Profile/AddCardTemplate');
var html = this.templateFunction(); var html = this.templateFunction();

Loading…
Cancel
Save