Commit Graph

47 Commits

Author SHA1 Message Date
fce8879994 Searching with adult parameter is now handled and also cached correctly. 2020-04-08 23:08:42 +02:00
505b126043 Cleanup, removed comments and logs. 2020-04-08 23:07:09 +02:00
2b25397253 Misc updates to caching from plex and tmdb. 2020-04-08 23:01:33 +02:00
815aaedffb Changed tmdb constructor to have apiKey as first parameter. If cache is not defined we use redis. 2020-04-08 22:54:19 +02:00
2672266908 Simplified every function towards tmdb by having the shared functionality separated into a function. 2020-02-21 21:47:00 +01:00
b802a7b62b Moved, renamed, re-did and added a lot of stuff. Getting ready for the v2 upgrade 2019-11-03 20:33:30 +01:00
879a02b388 Finished movie credits and release dates 2019-11-03 16:01:19 +01:00
bc3d4881bd New release_dates endpoint for movie 2019-11-03 15:43:35 +01:00
d2d396bb7a Set cache TTL for credits to 1 day 2019-11-03 15:07:11 +01:00
500b75eaf6 We know there could be a 401 response so we handle it 2019-11-03 15:04:14 +01:00
9308d4ea9b Credits endpoint for movies 2019-11-03 15:02:45 +01:00
6c2c81a1a1 Updated movieInfo controller to also handle requesting release_dates as query parameter 2019-10-04 22:36:39 +02:00
8e23ae5a27 Added babel for ES6 functionality. In this case the new import statements 2019-07-27 01:28:41 +02:00
3b27af1f83 Error handling for themoviedb api response codes that are not 200. Started with 401 and 404. See issue #116 for info. 2019-07-26 21:52:20 +02:00
99bab3fb73 Movie and show can also return credits for a item. Enabled by query parameter credits=true 2019-06-04 23:32:38 +02:00
7cb55ce054 Fetchall uses promises smarter. Now the utils functions also return promises to be able to nicely chain the steps a request needs to go through. Promise all lets us wait for all items return in the map function. Without the map function would return immidiately and resolve before the map operation completed. 2018-11-10 20:26:28 +01:00
d80386da40 Implementing lists lookups for movie and shows. Add new cachetags for the lists & created a helper function for returning response with convertFunction as parameter. 2018-11-01 00:15:49 +01:00
4250b1bd17 request endpoint finds type by body not query. Better error handling on what goes wrong if incorrect type or missing body parameter. 2018-10-30 20:34:26 +01:00
5d8869e042 Rewrote every function for searching and looking up items from tmdb library. Now there are separate functions for the four categories of search and three for info (multi, movie, show & person). Each function now has its own endpoint and matching controller. Converting tmdb results into a class has been alterted from using three classes; movie, show & person, and each have each their own convertTmdbTo function. Now the structure of the three types are more structured and no longer a single "seasoned" class object. 2018-10-29 20:55:18 +01:00
41d6bba743 v2 endpoints added for clearer intent in endpoints. Two new controller categories; info and search. 2018-10-28 12:21:47 +01:00
5b49216c9d Fixed linting issues for json objects and tailing semicolon. 2018-05-09 10:52:08 +02:00
18359f442c Mapped results in tmdb now returns the complete json object so not needed to be created before sent. When getting all requested movies and shows it is now possible to only get one page at a time. 2018-03-20 21:17:41 +01:00
42b8b5ea0e Removed a ) 2018-03-20 20:15:28 +01:00
9e145f7068 When testing we dont have api access so we create cache entries before each request. The cache key changed so this is now updated in the tests and tmdb. 2018-03-20 20:12:49 +01:00
528cbed30f Wasn't getting all the items because some elements do not have a media_type 2018-02-07 15:53:27 +01:00
ad4fa9d95a Fixed issue with types not being upheld when converting from tmdb objects. 2018-02-07 15:40:39 +01:00
3ca3c06824 Removed static tag in tmdb functions. 2018-02-07 14:13:50 +01:00
6fd65fdb23 Refactoring where now we can search lists and lookup movies or shows by using the new tmdbMethod function which takes the api endpoint variable and type to return the appropriate tmdbMethod name for the matching api call to tmdb. Removed a lot of the globally defined variables. 2018-02-07 13:42:46 +01:00
d8b2cef18f Removed filtering of items when searching tmdb. Also added total_results object to all return statements. 2018-02-05 22:46:10 +01:00
0c3ad3a95e Fixed a issue where the tmdb type was not being selected correctly. (movie/show) 2018-02-02 11:51:13 +01:00
1bdf89b69f Merge pull request #55 from KevinMidboe/api_tuning
Lowered the tollerance for what objects we choose to look at by tmdb.…
2017-10-23 15:39:57 +02:00
498bd13a1f Lowered the tollerance for what objects we choose to look at by tmdb. That is we only accept items that have some value of vote or popularity. 2017-10-23 15:39:28 +02:00
6f12d0ca49 Added docstring to new functions in tmdb 2017-10-23 15:14:16 +02:00
c48db517ac Created one function for searching for different tmdb lists. This replaces 4 endpoints so we have a single way of searching for lists. 2017-10-23 14:58:52 +02:00
7952e6015a Added caching for all tmdb requests. 2017-10-22 17:41:12 +02:00
b82efddeba Now tmdb searches also check cache for a matching query request, if so returns it. 2017-10-22 14:08:36 +02:00
5ceb19f449 Merge branch 'update/frontend_logic' of github.com:kevinmidboe/seasonedShows into update/frontend_logic 2017-09-27 13:51:07 +02:00
8b5b8bb0b7 Reduced the filter values to return more results. 2017-09-27 13:49:49 +02:00
98dafe56c4 Merge branch 'master' into update/frontend_logic 2017-09-27 00:45:49 +02:00
d787fba024 Changed a smellingerror (reponse -> response). Also now pass the type of the search request when converting to seasoned object. Fixed issue where number_of_items_on_page was not set to the length of the list. 2017-09-27 00:22:22 +02:00
6b4daf140a Change a grammar error 2017-09-21 16:58:44 +02:00
e281e73293 Now the type is checked and passed to convertTmdbToSeasoned if it is movie or show and not multiwq 2017-09-21 16:37:53 +02:00
72d50209a5 Rewrote the search function in tmdb to now return a JSON object with results: (all movie/show objects), number_of_items: (count of result objects), page and total page. Split up the filtering and converting of the result from tmdb api to finished seasoned objects for better readability. 2017-09-20 10:21:57 +02:00
e81f5c8057 Added functions for discover, upcoming, nowplaying, popular and similar. Also documented better and some finer error handling with more logical responses. 2017-09-03 17:04:59 +02:00
dacd44a8f5 Changed the value of the filter to be vote_count >= 80 or popularity > 18 2017-09-02 22:53:04 +02:00
101dc7d570 Changed the filter cutoff to be based on, if the show/movie has popularity over 2, vote_count over 20 and has a defined release_date/first_air_date. Also changed so that it now uses the new convertTmdbToSeaonsed insted of the old (convertTmdbToMovie) 2017-09-02 20:49:09 +02:00
47aa638fd8 Moved eveything related to the api to a seperate folder seasoned_api. 2017-08-06 16:45:02 +02:00