Initial commit
This commit is contained in:
+26
@@ -0,0 +1,26 @@
|
||||
var Backbone = require('backbone');
|
||||
|
||||
/*
|
||||
* List item model
|
||||
*
|
||||
*/
|
||||
|
||||
module.exports = Backbone.Model.extend({
|
||||
|
||||
defaults: {
|
||||
selected: false,
|
||||
label: '',
|
||||
template: function () {
|
||||
return '';
|
||||
}
|
||||
},
|
||||
|
||||
getName: function () {
|
||||
return this.get('label') || this.getValue();
|
||||
},
|
||||
|
||||
getValue: function () {
|
||||
return this.get('val');
|
||||
}
|
||||
|
||||
});
|
||||
Reference in New Issue
Block a user