Merge pull request #925 from croneter/fix-directories
Provide more metadata for unsynced directory-like items like a tv show
This commit is contained in:
commit
7c5c91b590
1 changed files with 28 additions and 18 deletions
|
@ -79,7 +79,6 @@ def generate_item(api):
|
||||||
|
|
||||||
def _generate_folder(api):
|
def _generate_folder(api):
|
||||||
'''Generates "folder"/"directory" items that user can further navigate'''
|
'''Generates "folder"/"directory" items that user can further navigate'''
|
||||||
art = api.artwork()
|
|
||||||
typus = ''
|
typus = ''
|
||||||
if api.plex_type == v.PLEX_TYPE_GENRE:
|
if api.plex_type == v.PLEX_TYPE_GENRE:
|
||||||
# Unfortunately, 'genre' is not yet supported by Kodi
|
# Unfortunately, 'genre' is not yet supported by Kodi
|
||||||
|
@ -95,6 +94,17 @@ def _generate_folder(api):
|
||||||
typus = v.KODI_TYPE_ALBUM
|
typus = v.KODI_TYPE_ALBUM
|
||||||
elif api.fast_key and '?collection=' in api.fast_key:
|
elif api.fast_key and '?collection=' in api.fast_key:
|
||||||
typus = v.KODI_TYPE_SET
|
typus = v.KODI_TYPE_SET
|
||||||
|
if typus and typus != v.KODI_TYPE_SET:
|
||||||
|
content = _generate_content(api)
|
||||||
|
content['type'] = typus
|
||||||
|
content['file'] = api.directory_path(section_id=SECTION_ID,
|
||||||
|
plex_type=PLEX_TYPE,
|
||||||
|
old_key=KEY)
|
||||||
|
content['isFolder'] = True
|
||||||
|
content['IsPlayable'] = 'false'
|
||||||
|
return content
|
||||||
|
else:
|
||||||
|
art = api.artwork()
|
||||||
return {
|
return {
|
||||||
'title': api.title(),
|
'title': api.title(),
|
||||||
'label': api.title(),
|
'label': api.title(),
|
||||||
|
|
Loading…
Reference in a new issue