fix
This commit is contained in:
parent
ab4895ff85
commit
9155c44041
@ -9,6 +9,7 @@ ENV LANG="C.UTF-8" \
|
|||||||
API_TOKEN="moviepilot" \
|
API_TOKEN="moviepilot" \
|
||||||
SUPERUSER="admin" \
|
SUPERUSER="admin" \
|
||||||
SUPERUSER_PASSWORD="password" \
|
SUPERUSER_PASSWORD="password" \
|
||||||
|
AUTH_SITE="iyuu" \
|
||||||
LIBRARY_PATH="" \
|
LIBRARY_PATH="" \
|
||||||
DOWNLOAD_PATH="/downloads" \
|
DOWNLOAD_PATH="/downloads" \
|
||||||
TORRENT_TAG="MOVIEPILOT" \
|
TORRENT_TAG="MOVIEPILOT" \
|
||||||
|
@ -59,6 +59,8 @@ class Settings(BaseSettings):
|
|||||||
INDEXER: str = "builtin"
|
INDEXER: str = "builtin"
|
||||||
# 索引站点,站点域名关键字使用,分隔
|
# 索引站点,站点域名关键字使用,分隔
|
||||||
INDEXER_SITES: str = ""
|
INDEXER_SITES: str = ""
|
||||||
|
# 用户认证站点 hhclub/audiences/hddolby/zmpt/freefarm/hdfans/wintersakura/leaves/1ptba/icc2022/iyuu
|
||||||
|
AUTH_SITE: str = ""
|
||||||
# 消息通知渠道 telegram/wechat/slack
|
# 消息通知渠道 telegram/wechat/slack
|
||||||
MESSAGER: str = "telegram"
|
MESSAGER: str = "telegram"
|
||||||
# WeChat企业ID
|
# WeChat企业ID
|
||||||
|
@ -11,7 +11,7 @@ class PluginManager(metaclass=Singleton):
|
|||||||
"""
|
"""
|
||||||
插件管理器
|
插件管理器
|
||||||
"""
|
"""
|
||||||
systemconfigs: SystemConfigOper = None
|
systemconfig: SystemConfigOper = None
|
||||||
|
|
||||||
# 插件列表
|
# 插件列表
|
||||||
_plugins: dict = {}
|
_plugins: dict = {}
|
||||||
@ -24,7 +24,7 @@ class PluginManager(metaclass=Singleton):
|
|||||||
self.init_config()
|
self.init_config()
|
||||||
|
|
||||||
def init_config(self):
|
def init_config(self):
|
||||||
self.systemconfigs = SystemConfigOper()
|
self.systemconfig = SystemConfigOper()
|
||||||
# 停止已有插件
|
# 停止已有插件
|
||||||
self.stop()
|
self.stop()
|
||||||
# 启动插件
|
# 启动插件
|
||||||
@ -95,7 +95,7 @@ class PluginManager(metaclass=Singleton):
|
|||||||
"""
|
"""
|
||||||
if not self._plugins.get(pid):
|
if not self._plugins.get(pid):
|
||||||
return {}
|
return {}
|
||||||
return self.systemconfigs.get(self._config_key % pid) or {}
|
return self.systemconfig.get(self._config_key % pid) or {}
|
||||||
|
|
||||||
def save_plugin_config(self, pid: str, conf: dict) -> bool:
|
def save_plugin_config(self, pid: str, conf: dict) -> bool:
|
||||||
"""
|
"""
|
||||||
@ -103,7 +103,7 @@ class PluginManager(metaclass=Singleton):
|
|||||||
"""
|
"""
|
||||||
if not self._plugins.get(pid):
|
if not self._plugins.get(pid):
|
||||||
return False
|
return False
|
||||||
return self.systemconfigs.set(self._config_key % pid, conf)
|
return self.systemconfig.set(self._config_key % pid, conf)
|
||||||
|
|
||||||
def get_plugin_commands(self) -> List[dict]:
|
def get_plugin_commands(self) -> List[dict]:
|
||||||
"""
|
"""
|
||||||
|
Binary file not shown.
Binary file not shown.
Binary file not shown.
@ -27,8 +27,6 @@ class EventType(Enum):
|
|||||||
class SystemConfigKey(Enum):
|
class SystemConfigKey(Enum):
|
||||||
# 用户已安装的插件
|
# 用户已安装的插件
|
||||||
UserInstalledPlugins = "UserInstalledPlugins"
|
UserInstalledPlugins = "UserInstalledPlugins"
|
||||||
# 用户认证参数
|
|
||||||
UserSiteAuthParams = "UserSiteAuthParams"
|
|
||||||
|
|
||||||
|
|
||||||
# 站点框架
|
# 站点框架
|
||||||
|
Loading…
x
Reference in New Issue
Block a user