def get_dropdown(): global booleanGenre, booleanSearch, booleanPlaying, booleanUpcoming, booleanActor, booleanPopular, result if booleanGenre: result = recommend2.genre_info(genreSelected) booleanGenre = False elif booleanSearch: result = recommend2.movie_info(wordSelected) booleanSearch = False elif booleanPlaying: print booleanPlaying result = recommend2.now_playing_info() booleanPlaying = False elif booleanUpcoming: result = recommend2.upcoming_info() booleanUpcoming = False elif booleanPopular: result = recommend2.popular_info() booleanPopular = False return json.dumps(result)
def get_similar(): booleanSearch = True movie_id=request.args.get('movie_id','') wordSelected = recommend2.get_info(movie_id)['title'] return json.dumps(recommend2.movie_info(wordSelected))