MCPcopy
hub / github.com/django/django / save

Method save

tests/serializers/models/data.py:284–291  ·  view source on GitHub ↗

A save method that modifies the data in the object. A user-defined save() method isn't called when objects are deserialized (#4459).

(self, *args, **kwargs)

Source from the content-addressed store, hash-verified

282 data = models.IntegerField(null=True)
283
284 def save(self, *args, **kwargs):
285 """
286 A save method that modifies the data in the object.
287 A user-defined save() method isn't called when objects are deserialized
288 (#4459).
289 """
290 self.data = 666
291 super().save(*args, **kwargs)
292
293
294# Tests for serialization of models using inheritance.

Calls

no outgoing calls