mirror of
https://github.com/jellyfin/jellyfin-kodi.git
synced 2024-11-10 12:16:12 +00:00
Generators
For episodes
This commit is contained in:
parent
4cd270a9d2
commit
7ded39d580
1 changed files with 5 additions and 4 deletions
|
@ -6,6 +6,7 @@ import logging
|
||||||
from ntpath import dirname
|
from ntpath import dirname
|
||||||
|
|
||||||
import api
|
import api
|
||||||
|
import emby as mb
|
||||||
import embydb_functions as embydb
|
import embydb_functions as embydb
|
||||||
import _kodi_tvshows
|
import _kodi_tvshows
|
||||||
from _common import Items, catch_except
|
from _common import Items, catch_except
|
||||||
|
@ -202,8 +203,8 @@ class TVShows(Items):
|
||||||
for item in self.added(items, total):
|
for item in self.added(items, total):
|
||||||
if self.add_update(item, view):
|
if self.add_update(item, view):
|
||||||
# Add episodes
|
# Add episodes
|
||||||
all_episodes = self.emby.getEpisodesbyShow(item['Id'])
|
for all_episodes in mb.get_items(item['Id'], "Episode"):
|
||||||
self.add_episodes(all_episodes['Items'])
|
self.add_episodes(all_episodes['Items'])
|
||||||
|
|
||||||
def add_seasons(self, items, total=None, view=None):
|
def add_seasons(self, items, total=None, view=None):
|
||||||
|
|
||||||
|
@ -214,8 +215,8 @@ class TVShows(Items):
|
||||||
|
|
||||||
if self.add_updateSeason(item):
|
if self.add_updateSeason(item):
|
||||||
# Add episodes
|
# Add episodes
|
||||||
all_episodes = self.emby.getEpisodesbySeason(item['Id'])
|
for all_episodes in mb.get_items(item['Id'], "Episode"):
|
||||||
self.add_episodes(all_episodes['Items'])
|
self.add_episodes(all_episodes['Items'])
|
||||||
|
|
||||||
def add_episodes(self, items, total=None, view=None):
|
def add_episodes(self, items, total=None, view=None):
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue