Django Makemigrations Keeps Making The Same Alteration
I have a django project built with Django 1.10.7 and mysql 14.14 Distrib 5.5.54 If I do: $ python manage.py makemigrations my_app I get: Migrations for 'my_app': my_app/migra
Solution 1:
Provide the id_generator
function as the default value instead of the returned value of it. The function will be called every time when the new object is created.
reference = models.CharField(max_length=20, default=id_generator)
Post a Comment for "Django Makemigrations Keeps Making The Same Alteration"