I am trying to supply data to serializer related field but it keeps throwing a validation error which says the field is required even when I supply a value for it through postman. I honestly don't know what I am doing wrong.
Here's are my serializer;
class ProjectFileSerializer(serializers.ModelSerializers):
class Meta:
model = ProjectFile
fields = ['project', 'file']
class ProjectSerializer(serializers.ModelSerializer):
project_file = ProjectFileSerializer(write_only=True, many=True)
class Meta:
model = Project
fields = ['title', 'category', 'budget', 'project_file']