Gesion des séries
This commit is contained in:
parent
3788f4147a
commit
45f97936f0
3 changed files with 126 additions and 40 deletions
6
file.py
6
file.py
|
@ -13,7 +13,7 @@ class File:
|
|||
self.markers = {}
|
||||
self.api_id = api_id
|
||||
self.api_fileid = api_fileid
|
||||
self.fileable_type = {None: None, 'App//Film':'film', 'App//Episode':'episode'}[api_fileable_type]
|
||||
self.fileable_type = {None: None, 'App\\Film':'film', 'App\\Episode':'episode'}[api_fileable_type]
|
||||
|
||||
def get_ext(self):
|
||||
_, ext = posixpath.splitext(self.name)
|
||||
|
@ -64,9 +64,9 @@ class File:
|
|||
# 7) type: épisode / film
|
||||
if not self.fileable_type:
|
||||
for m in ['SERIE', 'EPISODE_NUM', 'SEASON_NUM']:
|
||||
if m in self.markers:
|
||||
if m in self.info:
|
||||
self.fileable_type = 'episode'
|
||||
if not self.fileable_type and 'TITLE' in self.markers:
|
||||
if (not self.fileable_type) and 'TITLE' in self.info:
|
||||
self.fileable_type = 'film'
|
||||
|
||||
def filename_same(self, other):
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue