I need to add 2 variables in serializer for for calculations in logic serializer
serializer = MoviesTopFrameSerializator(topMovie)
How can i do this ? and how to handle inside of serializer
I need to add 2 variables in serializer for for calculations in logic serializer
serializer = MoviesTopFrameSerializator(topMovie)
How can i do this ? and how to handle inside of serializer
You can use context to pass arbitrary data to the serializer
serializer = MoviesTopFrameSerializator(topMovie, context = {"foo":"bar"})
later, this context data can be accessed via the instance attribute as self.context["foo"]