drf-writable-nested icon indicating copy to clipboard operation
drf-writable-nested copied to clipboard

Writable nested model serializer for Django REST Framework

Results 80 drf-writable-nested issues
Sort by recently updated
recently updated
newest added

Can not update nested polymorphic object. I tried all methods (patch, put) but the drf exception occurs. I checked all issues/solutions and nothing helps. I've stucked on it for 2...

my code:  class UserSerializer(NestedUpdateMixin, serializers.ModelSerializer):   skill = SkillSerializer(many=True, required=False)   experience = ExperienceSerializer(many=True, required=False)   education = EducationSerializer(many=True, required=False)   profile = ProfileSerializer(required=True, instance=Profile)  class ProfileSerializer(WritableNestedModelSerializer):   child = ChildSerializer(many=True, required=False)   foreigner = UserForeignerSerializer(required=False,...

As mentioned here - https://github.com/beda-software/drf-writable-nested/issues/83, this package have a security issues, however original issue does not list them all I created a simple repo with examples of issues - https://github.com/regqueryvalueex/nested-serializer-issues-example-,...

WritableNestedModelSerializer won't work when there is a foreign key relation with a unique constraint con the child model. I already tried the mixin UniqueFieldsMixin, but it does not work either.

This adds support for initializing serializer with many=True. Works for create, not update. The current exception when attempting `many=True` in the master branch is that `initial_data` is not set. So...

``` class AlarmListSerializer(serializers.ListSerializer): @classmethod def many_init(cls, *args, **kwargs): # Instantiate the child serializer. kwargs['child'] = cls() # Instantiate the parent list serializer. return AlarmListSerializer(*args, **kwargs) def create(self, validated_data): ret =...

I have one model with a field which is self related, ```python class zi(models.Model): """汉字数据模型""" chszi = models.CharField(max_length=1, null=False, blank=False, verbose_name="汉字", unique=True) relatedzi = models.ManyToManyField("self", null=True, blank=True, related_name="rzi", symmetrical=True, verbose_name='关联字')...

Firstly, huge thanks for the code. I have a small question. Given two serializers: a parent and a child, inserting a ```validate``` method in the child serializer and printing something...

How to update only the selected fields with PATCH for the nested serializers ??