gadventures / django-fsm-admin

Mixin and template tags to integrate django-fsm transitions into the django admin.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Django 1.10: AttributeError: 'Options' object has no attribute 'get_field_by_name'

bruno-gelb opened this issue · comments

mixins.py: fsmfield = obj._meta.get_field_by_name(field)[0]

It's about bringing django 1.10 support to the table, right?..

I've got the same problem - a very quick and dirty hack:

mixins l78:

  • return self.model._meta.get_field_by_name(fsm_field_name)[0]
  • return self.model._meta.get_field(fsm_field_name)

same in mixins.py l225: fsmfield = obj._meta.get_field(field)