serializer short

This commit is contained in:
d0c 2023-02-20 15:59:44 +01:00
parent f6a4745dfd
commit 5502be73bb

View file

@ -27,3 +27,8 @@ class DeviceSerializer(serializers.ModelSerializer):
class Meta:
model = Device
exclude = ["id"]
class DeviceSerializerShort(DeviceSerializer):
class Meta:
model = Device
include = ["codename", "vendor", "name", "release", "maintainers", "cameras", "battery", "screen"]