diff options
| author | Jules Laplace <jules@okfoc.us> | 2015-11-05 01:02:20 -0500 |
|---|---|---|
| committer | Jules Laplace <jules@okfoc.us> | 2015-11-05 01:02:20 -0500 |
| commit | 4a04a1129fffd1e128e53ba7886777c8d7b36b55 (patch) | |
| tree | 79d394f2e14909e234ce8ffb9e1dfe5244678d23 /StoneIsland/www/js/lib/blogs/HubView.js | |
| parent | 83517eb8d489cfceda8e6b7ab1b104a8f0b1f3a8 (diff) | |
populate product view
Diffstat (limited to 'StoneIsland/www/js/lib/blogs/HubView.js')
| -rw-r--r-- | StoneIsland/www/js/lib/blogs/HubView.js | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/StoneIsland/www/js/lib/blogs/HubView.js b/StoneIsland/www/js/lib/blogs/HubView.js index 95cdef3f..62e8d10f 100644 --- a/StoneIsland/www/js/lib/blogs/HubView.js +++ b/StoneIsland/www/js/lib/blogs/HubView.js @@ -20,14 +20,15 @@ var HubView = View.extend({ this.data = data this.$loader.hide() this.$content.empty() + // id date subtitle body link image[uri caption] this.data.forEach(function(row){ - var t = this.template.replace(/{{image}}/, row.image.url) + var t = this.template.replace(/{{image}}/, row.images[0].uri) .replace(/{{date}}/, row.date) .replace(/{{code}}/, row.code) .replace(/{{title}}/, row.title) .replace(/{{subtitle}}/, row.subtitle) .replace(/{{link}}/, row.link) - .replace(/{{body}}/, row.body) + .replace(/{{body}}/, row.body.replace(/\n/g, "<br>")) this.$content.append(t) }.bind(this)) }, |
