Skip to content

Commit

Permalink
Merge 5a4a71a into 00b364d
Browse files Browse the repository at this point in the history
  • Loading branch information
kjagiello committed Sep 5, 2019
2 parents 00b364d + 5a4a71a commit b54b69a
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions django_enumfield/contrib/drf.py
Original file line number Diff line number Diff line change
Expand Up @@ -39,3 +39,6 @@ def to_representation(self, value):
class NamedEnumField(EnumField):
def get_choice_value(self, enum_value):
return enum_value.name

class Meta:
swagger_schema_fields = {"type": "string"}

0 comments on commit b54b69a

Please sign in to comment.