limit id type for tv episode and performance production
This commit is contained in:
parent
ac202a8e7e
commit
dcdb21ec04
5 changed files with 18 additions and 3 deletions
|
@ -364,6 +364,13 @@ class PerformanceProduction(Item):
|
|||
def set_parent_item(self, value):
|
||||
self.show = value
|
||||
|
||||
@classmethod
|
||||
def lookup_id_type_choices(cls):
|
||||
id_types = [
|
||||
IdType.DoubanDramaVersion,
|
||||
]
|
||||
return [(i.value, i.label) for i in id_types]
|
||||
|
||||
@property
|
||||
def display_title(self):
|
||||
return f"{self.show.title if self.show else '♢'} {self.title}"
|
||||
|
|
|
@ -451,6 +451,14 @@ class TVEpisode(Item):
|
|||
def set_parent_item(self, value):
|
||||
self.season = value
|
||||
|
||||
@classmethod
|
||||
def lookup_id_type_choices(cls):
|
||||
id_types = [
|
||||
IdType.IMDB,
|
||||
IdType.TMDB_TVEpisode,
|
||||
]
|
||||
return [(i.value, i.label) for i in id_types]
|
||||
|
||||
def update_linked_items_from_external_resource(self, resource):
|
||||
for w in resource.required_resources:
|
||||
if w["model"] == "TVSeason":
|
||||
|
|
|
@ -20,7 +20,7 @@
|
|||
<main class="container">
|
||||
<article class="error">
|
||||
<header>
|
||||
<h3>🤦🏻 无效的请求</h3>
|
||||
<h3>🤷🏻 无效的请求</h3>
|
||||
</header>
|
||||
您可能提交了无效的数据,或者相关内容已被作者删除。如果您确信这是我们的错误,请通过页面底部的链接联系我们。
|
||||
<section>
|
||||
|
|
|
@ -20,7 +20,7 @@
|
|||
<main class="container">
|
||||
<article class="error">
|
||||
<header>
|
||||
<h3>🤦🏻 权限不符</h3>
|
||||
<h3>🙅🏻 权限不符</h3>
|
||||
</header>
|
||||
{{ exception }}
|
||||
您可能访问了错误的网址,或者相关内容已被作者删除。如果您确信这是我们的错误,请通过页面底部的链接联系我们。
|
||||
|
|
|
@ -20,7 +20,7 @@
|
|||
<main class="container">
|
||||
<article class="error">
|
||||
<header>
|
||||
<h3>🤦🏻 条目未找到</h3>
|
||||
<h3>🤷🏻 条目未找到</h3>
|
||||
</header>
|
||||
您可能输入了一个无效的网址,或者相关内容已被作者删除。如果您确信这是我们的错误,请通过页面底部的链接联系我们。
|
||||
</article>
|
||||
|
|
Loading…
Add table
Reference in a new issue