Humorloos / bouldern-app

1 stars 1 forks source link

Add model history to relevant models #372

Closed Humorloos closed 2 years ago

Humorloos commented 2 years ago

see https://github.com/jazzband/django-simple-history

at deployment to server: Run Migrations With your model changes in place, create and apply the database migrations:

$ python manage.py makemigrations $ python manage.py migrate Existing Projects For existing projects, you can call the populate command to generate an initial change for preexisting model instances:

$ python manage.py populate_history --auto By default, history rows are inserted in batches of 200. This can be changed if needed for large tables by using the --batchsize option, for example --batchsize 500.