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.
 
 
 
 
 

13 lines
334 B

from rest_framework import serializers
from bike.models import Bike
class BikeSerializer(serializers.HyperlinkedModelSerializer):
class Meta:
model = Bike
fields = '__all__'
created_at = serializers.ReadOnlyField()
state = serializers.ReadOnlyField()
available_states = serializers.ReadOnlyField()