From 7ed0db10cbf2f2080665c8f829f8beecaeb1eda9 Mon Sep 17 00:00:00 2001 From: Leonardo Galli Date: Tue, 9 May 2017 22:28:15 +0200 Subject: [PATCH] 10 Movies are now shown on discover as well as search results. Show more should also be more consistent now. --- src/UI/AddMovies/AddMoviesView.js | 3 +++ src/UI/AddMovies/SearchResultCollectionView.js | 4 ++-- 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/src/UI/AddMovies/AddMoviesView.js b/src/UI/AddMovies/AddMoviesView.js index 97aad1c04..57ec4288b 100644 --- a/src/UI/AddMovies/AddMoviesView.js +++ b/src/UI/AddMovies/AddMoviesView.js @@ -123,6 +123,8 @@ module.exports = Marionette.Layout.extend({ onShow : function() { this.ui.discoverBefore.hide(); this.ui.moviesSearch.focus(); + this.ui.loadMore.hide(); + if (this.isDiscover) { this.ui.discoverBefore.show(); } @@ -189,6 +191,7 @@ module.exports = Marionette.Layout.extend({ _showResults : function() { if (!this.isClosed) { if (this.collection.length === 0) { + this.ui.loadMore.hide(); if (this.isDiscover) { this.searchResult.show(new DiscoverEmptyView()); } else { diff --git a/src/UI/AddMovies/SearchResultCollectionView.js b/src/UI/AddMovies/SearchResultCollectionView.js index bc10395ac..a270ad35c 100644 --- a/src/UI/AddMovies/SearchResultCollectionView.js +++ b/src/UI/AddMovies/SearchResultCollectionView.js @@ -10,7 +10,7 @@ module.exports = Marionette.CollectionView.extend({ initialize : function(options) { this.showExisting = true; this.isExisting = options.isExisting; - this.showing = 5; + this.showing = 10; if (this.isExisting) { this.showing = 1; } @@ -30,7 +30,7 @@ module.exports = Marionette.CollectionView.extend({ showMore : function() { var pos = $(window).scrollTop(); - this.showing += 5; + this.showing += 10; this.render(); $(window).scrollTop(pos); return this.showing >= this.collection.length;