mirror of
https://github.com/pkkid/python-plexapi
synced 2024-11-29 07:00:19 +00:00
adding fields attribute to audio.Audio
docstring update
This commit is contained in:
parent
de47470a43
commit
a12fd18e54
1 changed files with 3 additions and 1 deletions
|
@ -11,6 +11,7 @@ class Audio(PlexPartialObject):
|
|||
|
||||
Attributes:
|
||||
addedAt (datetime): Datetime this item was added to the library.
|
||||
fields (list): List of :class:`~plexapi.media.Field`.
|
||||
index (sting): Index Number (often the track number).
|
||||
key (str): API URL (/library/metadata/<ratingkey>).
|
||||
lastViewedAt (datetime): Datetime item was last accessed.
|
||||
|
@ -33,6 +34,7 @@ class Audio(PlexPartialObject):
|
|||
self._data = data
|
||||
self.listType = 'audio'
|
||||
self.addedAt = utils.toDatetime(data.attrib.get('addedAt'))
|
||||
self.fields = self.findItems(data, etag='Field')
|
||||
self.index = data.attrib.get('index')
|
||||
self.key = data.attrib.get('key')
|
||||
self.lastViewedAt = utils.toDatetime(data.attrib.get('lastViewedAt'))
|
||||
|
|
Loading…
Reference in a new issue