diff --git a/resources/lib/itemtypes/movies.py b/resources/lib/itemtypes/movies.py index 2c5d1636..4fc93348 100644 --- a/resources/lib/itemtypes/movies.py +++ b/resources/lib/itemtypes/movies.py @@ -65,6 +65,7 @@ class Movie(ItemBase): content='movies', scraper='metadata.local') path = library_path + kodi_parent_pathid = kodi_pathid else: # Plex library contains folders named identical to the # video file, e.g. @@ -81,6 +82,7 @@ class Movie(ItemBase): path = video_path else: kodi_pathid = self.kodidb.get_path(path) + kodi_parent_pathid = kodi_pathid if update_item: LOG.info('UPDATE movie plex_id: %s - %s', plex_id, api.title()) @@ -145,7 +147,7 @@ class Movie(ItemBase): api.trailer(), api.list_to_string(api.countries()), path, - kodi_pathid, + kodi_parent_pathid, api.premiere_date(), api.userrating()) diff --git a/resources/lib/kodi_db/video.py b/resources/lib/kodi_db/video.py index 47fc9559..2c3e8a74 100644 --- a/resources/lib/kodi_db/video.py +++ b/resources/lib/kodi_db/video.py @@ -45,13 +45,15 @@ class KodiVideoDB(common.KodiDBBase): strContent, strScraper, noUpdate, - exclude) - VALUES (?, ?, ?, ?, ?) + exclude, + allAudio) + VALUES (?, ?, ?, ?, ?, ?) ''' self.cursor.execute(query, (path, kind, 'metadata.local', 1, + 0, 0)) @db.catch_operationalerrors @@ -108,11 +110,13 @@ class KodiVideoDB(common.KodiDBBase): idParentPath, strContent, strScraper, - noUpdate) - VALUES (?, ?, ?, ?, ?, ?) + noUpdate, + exclude, + allAudio) + VALUES (?, ?, ?, ?, ?, ?, ?, ?) ''', (path, date_added, id_parent_path, content, - scraper, 1)) + scraper, 1, 0, 0)) pathid = self.cursor.lastrowid return pathid diff --git a/resources/lib/variables.py b/resources/lib/variables.py index 28282959..cc298705 100644 --- a/resources/lib/variables.py +++ b/resources/lib/variables.py @@ -84,7 +84,7 @@ COMPANION_PORT = int(_ADDON.getSetting('companionPort')) PKC_MACHINE_IDENTIFIER = None # Minimal PKC version needed for the Kodi database - otherwise need to recreate -MIN_DB_VERSION = '3.1.1' +MIN_DB_VERSION = '3.1.3' # Supported databases - version numbers in tuples should decrease SUPPORTED_VIDEO_DB = {