mirror of https://github.com/jumpserver/jumpserver
[Update] UserSerializer 添加 login_confirm_settings (#4086)
parent
31daaed4cd
commit
7ef09a4ca1
|
@ -40,6 +40,7 @@ class UserSerializer(CommonBulkSerializerMixin, serializers.ModelSerializer):
|
|||
login_blocked = serializers.SerializerMethodField()
|
||||
can_update = serializers.SerializerMethodField()
|
||||
can_delete = serializers.SerializerMethodField()
|
||||
login_confirm_settings = serializers.PrimaryKeyRelatedField(read_only=True, source='login_confirm_setting.reviewers', many=True)
|
||||
|
||||
key_prefix_block = "_LOGIN_BLOCK_{}"
|
||||
|
||||
|
@ -59,7 +60,7 @@ class UserSerializer(CommonBulkSerializerMixin, serializers.ModelSerializer):
|
|||
]
|
||||
fields = fields_small + [
|
||||
'groups', 'role', 'groups_display', 'role_display',
|
||||
'can_update', 'can_delete', 'login_blocked',
|
||||
'can_update', 'can_delete', 'login_blocked', 'login_confirm_settings'
|
||||
]
|
||||
|
||||
extra_kwargs = {
|
||||
|
|
Loading…
Reference in New Issue