mirror of
https://github.com/d0zingcat/MoviePilot-Plugins.git
synced 2026-05-13 23:16:47 +00:00
fix: ui可以取消主辅下载器配置,配置后强制走辅种下载器避免辅种下载不通时走默认导致重复
This commit is contained in:
@@ -186,7 +186,7 @@ class IYUUAutoSeed(_PluginBase):
|
||||
return active_services
|
||||
|
||||
@property
|
||||
def auto_service_info(self) -> Optional[Dict[str, ServiceInfo]]:
|
||||
def auto_service_info(self) -> ServiceInfo | None:
|
||||
"""
|
||||
服务信息
|
||||
"""
|
||||
@@ -376,6 +376,8 @@ class IYUUAutoSeed(_PluginBase):
|
||||
{
|
||||
'component': 'VSelect',
|
||||
'props': {
|
||||
'chips': True,
|
||||
'clearable': True,
|
||||
'model': 'auto_downloader',
|
||||
'label': '主辅分离',
|
||||
'items': [{"title": config.name, "value": config.name}
|
||||
@@ -835,9 +837,14 @@ class IYUUAutoSeed(_PluginBase):
|
||||
logger.info(f"种子 {seed.get('info_hash')} 辅种失败且已缓存,跳过 ...")
|
||||
continue
|
||||
# 添加任务 如果配置了主辅分离使用辅种下载器
|
||||
success = self.__download_torrent(seed=seed,
|
||||
service=self.auto_service_info if self.auto_service_info else service,
|
||||
save_path=save_paths.get(current_hash))
|
||||
if self._auto_downloader:
|
||||
success = self.__download_torrent(seed=seed,
|
||||
service=self.auto_service_info,
|
||||
save_path=save_paths.get(current_hash))
|
||||
else:
|
||||
success = self.__download_torrent(seed=seed,
|
||||
service=service,
|
||||
save_path=save_paths.get(current_hash))
|
||||
if success:
|
||||
success_torrents.append(seed.get("info_hash"))
|
||||
|
||||
@@ -1334,4 +1341,4 @@ class IYUUAutoSeed(_PluginBase):
|
||||
|
||||
self._sites = sites
|
||||
# 保存配置
|
||||
self.__update_config()
|
||||
self.__update_config()
|
||||
Reference in New Issue
Block a user