0
渲染我有如下表中沒有骨幹
app.View.FriendRequestTableView = Backbone.View.extend({
tagName: 'table',
className: 'table table-hover',
initialize : function(options) {
this.options = options;
this.render();
},
render: function() {
$(this.el).empty();
this.options.collection.each(function(user){
var row = new app.View.FriendRequestRowView({model:user});
$(this.el).append(row.el);
});
return $(this.el);
}
});
我檢查,我看到該行正確構造,但下面的行不工作
$(this.el).append(row.el);
我還創建了一個動態表已經看到只有表格元素被創建,但表格是空的。 任何想法???