Browse Source

perf: 修改 connect token api

pull/9134/head
ibuler 2 years ago
parent
commit
0ffea3855b
  1. 4
      apps/authentication/serializers/connection_token.py

4
apps/authentication/serializers/connection_token.py

@ -148,9 +148,9 @@ class ConnectionTokenSecretSerializer(OrgResourceModelSerializerMixin):
expire_now = serializers.BooleanField(label=_('Expired now'), default=True)
user = ConnectionTokenUserSerializer(read_only=True)
asset = ConnectionTokenAssetSerializer(read_only=True)
platform = ConnectionTokenPlatform(read_only=True)
account = ConnectionTokenAccountSerializer(read_only=True)
gateway = ConnectionTokenGatewaySerializer(read_only=True)
platform = ConnectionTokenPlatform(read_only=True)
# cmd_filter_rules = ConnectionTokenCmdFilterRuleSerializer(many=True)
actions = ActionChoicesField()
expire_at = serializers.IntegerField()
@ -158,7 +158,7 @@ class ConnectionTokenSecretSerializer(OrgResourceModelSerializerMixin):
class Meta:
model = ConnectionToken
fields = [
'id', 'value', 'user', 'asset', 'platform', 'account',
'id', 'value', 'user', 'asset', 'account', 'platform',
'protocol', 'gateway', 'actions', 'expire_at', 'expire_now',
]
extra_kwargs = {

Loading…
Cancel
Save