mirror of
https://github.com/Tautulli/Tautulli.git
synced 2025-07-16 02:02:58 -07:00
Add file_size_bytes notification parameter
* Change type of file_size parameter and update description to indicate it is in human readable format.
This commit is contained in:
parent
98c363f559
commit
380cbd232c
2 changed files with 3 additions and 1 deletions
|
@ -604,7 +604,8 @@ NOTIFICATION_PARAMETERS = [
|
|||
{'name': 'Subtitle Language Code', 'type': 'str', 'value': 'subtitle_language_code', 'description': 'The subtitle language code of the original media.'},
|
||||
{'name': 'File', 'type': 'str', 'value': 'file', 'description': 'The file path to the item.'},
|
||||
{'name': 'Filename', 'type': 'str', 'value': 'filename', 'description': 'The file name of the item.'},
|
||||
{'name': 'File Size', 'type': 'int', 'value': 'file_size', 'description': 'The file size of the item.'},
|
||||
{'name': 'File Size', 'type': 'str', 'value': 'file_size', 'description': 'The file size of the item in human readable format.', 'example': '1.2 GB'},
|
||||
{'name': 'File Size Bytes', 'type': 'int', 'value': 'file_size_bytes', 'description': 'The file size of the item in bytes.'},
|
||||
{'name': 'Guid', 'type': 'str', 'value': 'guid', 'description': 'The full guid for the item.'},
|
||||
{'name': 'Section ID', 'type': 'int', 'value': 'section_id', 'description': 'The unique identifier for the library.'},
|
||||
{'name': 'Rating Key', 'type': 'int', 'value': 'rating_key', 'description': 'The unique identifier for the movie, episode, or track.'},
|
||||
|
|
|
@ -1215,6 +1215,7 @@ def build_media_notify_params(notify_action=None, session=None, timeline=None, m
|
|||
'file': notify_params['file'],
|
||||
'filename': os.path.basename(notify_params['file'].replace('\\', os.sep)),
|
||||
'file_size': helpers.human_file_size(notify_params['file_size']),
|
||||
'file_size_bytes': notify_params['file_size'],
|
||||
'indexes': notify_params['indexes'],
|
||||
'guid': notify_params['guid'],
|
||||
'section_id': notify_params['section_id'],
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue