Closed wynandvdl closed 6 years ago
I have tested it and I get the same error.
Could you solve it?
I have the same problem: /smart_selects/widgets.py in render, line 242 'NoneType' object does not support item assignment
{% admin_related_field_urls bound_field as bound_field_urls %}
I have the same problem anyone could solve it it?
I don't want to complicate the code in django-smart-selects any more than it already is (it's brittle enough already), so I will not be fixing this.
The proper fix is to get django-material to properly render widgets as I noted in my comment on #170.
Sorry!
Here is the solution https://stackoverflow.com/a/52361037/3472881
Hi
I had a look at issue #170 and have the same problem. I tried the workaround that was suggested, but unfortunately it does not work on the admin side. Everything works perfectly when django-material is disabled. I know the bug is not on your side, but it would be great if smart-selects would be able to work with django-material. Any help would be appreciated
Here is my model, the referenced foreignkey is in a different app and like I said smart-selects works without django-material enabled.
admin.py
widget.py as suggested workaround
The error I receive from shell
TypeError: init() missing 9 required positional arguments: 'to_app_name', 'to_model_name', 'chained_field', 'chained_model_field', 'foreign_key_app_name', 'foreign_key_model_name', 'foreign_key_field_name', 'show_all', and 'auto_choose'