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.
|
|
|
|
'use strict';
|
|
|
|
|
|
|
|
|
|
define(
|
|
|
|
|
[
|
|
|
|
|
'marionette'
|
|
|
|
|
], function (Marionette) {
|
|
|
|
|
|
|
|
|
|
return Marionette.ItemView.extend({
|
|
|
|
|
|
|
|
|
|
template: 'AddSeries/RootFolders/RootFolderItemTemplate',
|
|
|
|
|
tagName : 'tr',
|
|
|
|
|
|
|
|
|
|
events: {
|
|
|
|
|
'click .x-delete': 'removeFolder',
|
|
|
|
|
'click .x-folder': 'folderSelected'
|
|
|
|
|
},
|
|
|
|
|
|
|
|
|
|
removeFolder: function () {
|
|
|
|
|
this.model.destroy({ wait: true });
|
|
|
|
|
},
|
|
|
|
|
|
|
|
|
|
folderSelected: function () {
|
|
|
|
|
this.trigger('folderSelected', this.model);
|
|
|
|
|
}
|
|
|
|
|
});
|
|
|
|
|
});
|