mirror of https://github.com/jumpserver/jumpserver
You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
16 lines
525 B
16 lines
525 B
1 year ago
|
from django.utils.translation import gettext_lazy as _
|
||
|
from rest_framework import serializers
|
||
|
|
||
|
from users.const import FileNameConflictResolution
|
||
|
|
||
|
|
||
|
class BasicSerializer(serializers.Serializer):
|
||
|
file_name_conflict_resolution = serializers.ChoiceField(
|
||
|
FileNameConflictResolution.choices, default=FileNameConflictResolution.REPLACE,
|
||
|
required=False, label=_('File name conflict resolution')
|
||
|
)
|
||
|
|
||
|
|
||
|
class KokoSerializer(serializers.Serializer):
|
||
|
basic = BasicSerializer(required=False, label=_('Basic'))
|