feat: 为平台和提供商适配器添加默认 ID 配置 #248

This commit is contained in:
Soulter
2025-01-22 16:52:34 +08:00
parent 4b5d49cb41
commit b172b760ab
2 changed files with 4 additions and 0 deletions
+2
View File
@@ -27,6 +27,8 @@ def register_platform_adapter(
default_config_tmpl['type'] = adapter_name
if 'enable' not in default_config_tmpl:
default_config_tmpl['enable'] = False
if 'id' not in default_config_tmpl:
default_config_tmpl['id'] = adapter_name
pm = PlatformMetadata(
name=adapter_name,
+2
View File
@@ -28,6 +28,8 @@ def register_provider_adapter(
default_config_tmpl['type'] = provider_type_name
if 'enable' not in default_config_tmpl:
default_config_tmpl['enable'] = False
if 'id' not in default_config_tmpl:
default_config_tmpl['id'] = provider_type_name
pm = ProviderMetaData(
type=provider_type_name,