mirror of
https://github.com/jellyfin/jellyfin-kodi.git
synced 2024-11-10 04:06:11 +00:00
added boxsets to IncrementalSync
This commit is contained in:
parent
da4b99f989
commit
d2a3f316be
1 changed files with 17 additions and 9 deletions
|
@ -557,10 +557,13 @@ class LibrarySync():
|
||||||
if item.get('IsFolder') and item.get('RecursiveItemCount') != 0:
|
if item.get('IsFolder') and item.get('RecursiveItemCount') != 0:
|
||||||
kodiId = WriteKodiVideoDB().addOrUpdateTvShowToKodiLibrary(item["Id"],connection, cursor, view.get('title'))
|
kodiId = WriteKodiVideoDB().addOrUpdateTvShowToKodiLibrary(item["Id"],connection, cursor, view.get('title'))
|
||||||
|
|
||||||
#### PROCESS EPISODES ######
|
|
||||||
|
#### PROCESS OTHERS BY THE ITEMLIST ######
|
||||||
for item in itemList:
|
for item in itemList:
|
||||||
|
|
||||||
MBitem = ReadEmbyDB().getItem(item)
|
MBitem = ReadEmbyDB().getItem(item)
|
||||||
|
|
||||||
|
#### PROCESS EPISODES ######
|
||||||
if MBitem["Type"] == "Episode":
|
if MBitem["Type"] == "Episode":
|
||||||
|
|
||||||
#get the tv show
|
#get the tv show
|
||||||
|
@ -577,14 +580,19 @@ class LibrarySync():
|
||||||
#tv show doesn't exist
|
#tv show doesn't exist
|
||||||
#perform full tvshow sync instead so both the show and episodes get added
|
#perform full tvshow sync instead so both the show and episodes get added
|
||||||
self.TvShowsFullSync(connection,cursor,None)
|
self.TvShowsFullSync(connection,cursor,None)
|
||||||
return
|
|
||||||
|
|
||||||
|
#### PROCESS BOXSETS ######
|
||||||
|
elif MBitem["Type"] == "BoxSet":
|
||||||
|
boxsetMovies = ReadEmbyDB().getMoviesInBoxSet(boxset["Id"])
|
||||||
|
WriteKodiVideoDB().addBoxsetToKodiLibrary(boxset,connection, cursor)
|
||||||
|
|
||||||
|
for boxsetMovie in boxsetMovies:
|
||||||
|
WriteKodiVideoDB().updateBoxsetToKodiLibrary(boxsetMovie,boxset, connection, cursor)
|
||||||
|
|
||||||
#### PROCESS MUSICVIDEOS ####
|
#### PROCESS MUSICVIDEOS ####
|
||||||
allEmbyMusicvideos = ReadEmbyDB().getMusicVideos(itemList)
|
elif MBitem["Type"] == "MusicVideo":
|
||||||
for item in allEmbyMusicvideos:
|
if not MBitem.get('IsFolder'):
|
||||||
if not item.get('IsFolder'):
|
WriteKodiVideoDB().addOrUpdateMusicVideoToKodiLibrary(MBitem["Id"],connection, cursor)
|
||||||
WriteKodiVideoDB().addOrUpdateMusicVideoToKodiLibrary(item["Id"],connection, cursor)
|
|
||||||
|
|
||||||
### commit all changes to database ###
|
### commit all changes to database ###
|
||||||
connection.commit()
|
connection.commit()
|
||||||
|
|
Loading…
Reference in a new issue