git-svn-id: https://msi/svn/firstRepo/WebClient/branches/NewRelease@59 0f545695-f87b-41b6-9a03-7f16563b5454
This commit is contained in:
@@ -1,6 +1,6 @@
|
||||
define(['jquery', 'underscore', 'backbone', 'text!modules/category/categoryViewTemplate.html',
|
||||
'text!modules/category/categoryItemTemplate.html', 'modules/base/baseView', 'libs/fastclick', 'classes/debug'],
|
||||
function ($, _, Backbone, categoryViewTemplate, categoryItemTemplate, BaseView, FastClick, Debug) {
|
||||
'text!modules/category/categoryItemTemplate.html', 'modules/base/baseView', 'libs/fastclick', 'classes/debug', 'classes/images'],
|
||||
function ($, _, Backbone, categoryViewTemplate, categoryItemTemplate, BaseView, FastClick, Debug, Images) {
|
||||
|
||||
var CategoryView = BaseView.extend({
|
||||
collection: null,
|
||||
@@ -20,7 +20,7 @@ define(['jquery', 'underscore', 'backbone', 'text!modules/category/categoryViewT
|
||||
this.$el.find('#allRicette').length === 0){
|
||||
this.collection.fetch({
|
||||
success: function (data, textStatus, jqXHR) {
|
||||
self.renderItem();
|
||||
setTimeout(self.renderItem(), 0);
|
||||
}
|
||||
});
|
||||
}
|
||||
@@ -37,9 +37,12 @@ define(['jquery', 'underscore', 'backbone', 'text!modules/category/categoryViewT
|
||||
/*_.each(this.collection.toJSON(), function (d) {
|
||||
html += self.itemtemplate(d);
|
||||
});*/
|
||||
html = this.itemtemplate(this.collection.toJSON());
|
||||
html = this.itemtemplate({
|
||||
items: this.collection.toJSON(),
|
||||
images: Images
|
||||
});
|
||||
|
||||
$ul.html(html);
|
||||
$(html).appendTo($ul).enhanceWithin();
|
||||
$ul.listview("refresh");
|
||||
//$ul.trigger("updatelayout");
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user