Answers for "i have override save method but it doesnot work while saving object using update method django"

5

how to override save method in django

def save(self, *args, **kwargs):
	if not self.id:
	# Object is a new instance

	return super(Model, self).save(*args, **kwargs)
Posted by: Guest on August-04-2020

Code answers related to "i have override save method but it doesnot work while saving object using update method django"

Python Answers by Framework

Browse Popular Code Answers by Language