perf: Platform automation add remove account method (#13411)

Co-authored-by: feng <1304903146@qq.com>
pull/13413/head
fit2bot 2024-06-12 19:23:40 +08:00 committed by GitHub
parent 9195c658a0
commit d8379195e6
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
3 changed files with 13 additions and 1 deletions

View File

@ -36,6 +36,7 @@ class DatabaseTypes(BaseType):
'verify_account_enabled': True,
'change_secret_enabled': True,
'push_account_enabled': True,
'remove_account_enabled': True,
},
cls.REDIS: {
'ansible_enabled': False,

View File

@ -53,7 +53,9 @@ class HostTypes(BaseType):
'gather_accounts_enabled': True,
'verify_account_enabled': True,
'change_secret_enabled': True,
'push_account_enabled': True
'push_account_enabled': True,
'remove_account_enabled': True,
},
cls.WINDOWS: {
'ansible_config': {

View File

@ -27,6 +27,7 @@ class PlatformAutomationSerializer(serializers.ModelSerializer):
"change_secret_enabled", "change_secret_method", "change_secret_params",
"verify_account_enabled", "verify_account_method", "verify_account_params",
"gather_accounts_enabled", "gather_accounts_method", "gather_accounts_params",
"remove_account_enabled", "remove_account_method", "remove_account_params",
]
extra_kwargs = {
# 启用资产探测
@ -67,6 +68,14 @@ class PlatformAutomationSerializer(serializers.ModelSerializer):
"gather_accounts_method": {
"label": _("Gather accounts method"),
},
"remove_account_method": {
"label": _("Remove account method"),
},
"remove_account_enabled": {
"label": _("Remove accounts enabled"),
"help_text": _("Enable account remove"),
},
}