perf: account view secret mfa (#9600)

Co-authored-by: feng <1304903146@qq.com>
pull/9601/head^2
fit2bot 2 years ago committed by GitHub
parent d85b024c47
commit 7040f46565
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

@ -66,7 +66,7 @@ class AccountSecretsViewSet(RecordViewLogMixin, AccountViewSet):
'default': serializers.AccountSecretSerializer,
}
http_method_names = ['get', 'options']
# permission_classes = [RBACPermission, UserConfirmation.require(ConfirmType.MFA)]
permission_classes = [RBACPermission, UserConfirmation.require(ConfirmType.MFA)]
rbac_perms = {
'list': 'accounts.view_accountsecret',
'retrieve': 'accounts.view_accountsecret',

@ -1,10 +1,10 @@
from rest_framework import serializers
from django.utils.translation import ugettext_lazy as _
from rest_framework import serializers
from assets.models import Asset, Node
from common.serializers.fields import ObjectRelatedField
from perms.models import AssetPermission
from perms.serializers.permission import ActionChoicesField
from common.serializers.fields import ObjectRelatedField
from tickets.models import ApplyAssetTicket
from .common import BaseApplyAssetSerializer
from .ticket import TicketApplySerializer

Loading…
Cancel
Save