2022-10-21 21:39:04 +03:00
|
|
|
from rest_framework import serializers
|
|
|
|
|
|
|
|
|
|
|
|
class SearchSerializer(serializers.Serializer):
|
|
|
|
body = serializers.CharField(max_length=200)
|
|
|
|
|
|
|
|
def create(self, validated_data):
|
2022-10-21 23:34:41 +03:00
|
|
|
raise NotImplementedError
|
2022-10-21 21:39:04 +03:00
|
|
|
|
|
|
|
def update(self, instance, validated_data):
|
2022-10-21 23:34:41 +03:00
|
|
|
raise NotImplementedError
|
2022-10-21 21:39:04 +03:00
|
|
|
|
|
|
|
|
|
|
|
class ResponseSerializer(serializers.Serializer):
|
|
|
|
results = serializers.JSONField()
|
|
|
|
|
|
|
|
def create(self, validated_data):
|
2022-10-21 23:34:41 +03:00
|
|
|
raise NotImplementedError
|
2022-10-21 21:39:04 +03:00
|
|
|
|
|
|
|
def update(self, instance, validated_data):
|
2022-10-21 23:34:41 +03:00
|
|
|
raise NotImplementedError
|