목록reset (1)
반응형
반응형
Eungene's Imaginations...
[Backbone.js] Collection, add models and remove(reset)
var Book = Backbone.Model.extend({ initialize: function () { this.on("invalid", function (model, error) { console.log("**Validation Error : " + error + "**"); }); this.on("change", function (a) { // 로그를 남기는 여러가지 방법 console.log('Model Changed'); if (this.hasChanged('name')) { console.log('The name has changed'); } if (this.hasChanged('author')) { console.log('The author has changed'); } console.l..
Programming/Backbone.js
2015. 10. 6. 10:48