On Sat, Dec 16, 2023 at 1:10 PM Reddy Tintaya wrote:
> Can't you just use
> workitem = serializers.PrimaryKeyRelatedField(
> queryset=WorkItem.objects.all())
> instead of workitem_id?
>
No because workitem_id is what is sent in the request.
>
> On Sat, Dec 16, 2023 at 10:00 AM Larry
Can't you just use
workitem = serializers.PrimaryKeyRelatedField(
queryset=WorkItem.objects.all())
instead of workitem_id?
On Sat, Dec 16, 2023 at 10:00 AM Larry Martell
wrote:
> I have a DRF API. It is throwing an error that I have not been able to fix.
>
> Here is my view and serializer:
I have a DRF API. It is throwing an error that I have not been able to fix.
Here is my view and serializer:
class CreateNotations(CreateAPIView):
permission_classes = [IsAuthenticated]
serializer_class = NotationListSerializer
def post(self, request, *args, **kwargs):
return
3 matches
Mail list logo