summaryrefslogtreecommitdiff
path: root/StoneIsland/www/js/lib/products/CollectionView.js
diff options
context:
space:
mode:
Diffstat (limited to 'StoneIsland/www/js/lib/products/CollectionView.js')
-rw-r--r--StoneIsland/www/js/lib/products/CollectionView.js25
1 files changed, 13 insertions, 12 deletions
diff --git a/StoneIsland/www/js/lib/products/CollectionView.js b/StoneIsland/www/js/lib/products/CollectionView.js
index 1377277a..490b10fe 100644
--- a/StoneIsland/www/js/lib/products/CollectionView.js
+++ b/StoneIsland/www/js/lib/products/CollectionView.js
@@ -46,19 +46,20 @@ var CollectionView = ScrollableView.extend({
else {
this.data = data
}
- this.loaded = true
- this.$loader.hide()
- this.$content.empty()
- // DefaultCode10
- data.SearchResponseFull.Results.Items.forEach(function(item){
- this.items[ item['Code8'] ] = item
- var t = this.template.replace(/{{image}}/, sdk.image(item['DefaultCode10'], '11_f'))
- .replace(/{{code8}}/, item['Code8'])
- this.$content.append(t)
- }.bind(this))
-
- this.deferScrollToTop()
+ if (! this.loaded) {
+ this.loaded = true
+ this.$loader.hide()
+ this.$content.empty()
+ // DefaultCode10
+ data.SearchResponseFull.Results.Items.forEach(function(item){
+ this.items[ item['Code8'] ] = item
+ var t = this.template.replace(/{{image}}/, sdk.image(item['DefaultCode10'], '11_f'))
+ .replace(/{{code8}}/, item['Code8'])
+ this.$content.append(t)
+ }.bind(this))
+ this.deferScrollToTop()
+ }
this.afterFetchCallback && this.afterFetchCallback()
},