jazzband / django-fsm-log

Automatic logging for Django FSM
https://django-fsm-log.readthedocs.io/en/latest/
MIT License
241 stars 78 forks source link

Allow manager to be used in migrations #94

Closed imomaliev closed 2 years ago

imomaliev commented 5 years ago

Hi, I would like to have ability to use StateLog's manager in migrations for data migrations

https://docs.djangoproject.com/en/2.1/topics/migrations/#model-managers

I could provide PR if this feature request accepted

blueyed commented 5 years ago

Sounds good to me in general. What is your use case?

imomaliev commented 5 years ago

I have 2 models, parent and child, child model has fsm. I need to add fsm functionality to parent one. So for the sake of data consistency I need to do data migration and create StateLog records for existing objects of parent model based on state logs of the child.