Open ad-m opened 7 years ago
Ran into the same issues. These were the changes that got it to run:
In fields.py, remove the metaclass = models.SubFielddBase. Deprecated since 1.9, removed in django 1.10. Add a function below to_python like this:
def from_db_value(self,value,expression,connection,context):
if value is None:
return value
try:
if isinstance(value, str):
return json.loads(value)
except ValueError:
pass
return ""
Mind you, I am not sure that this will work in all calls to the db yet, but at least it gets you up and running.
In views.py on the line from django.conf.urls remove patterns, this was deprecated in 1.9. Keep urls. Then, convert your urlpattern definition into a list or tuple, as per the django docs. Finally, everywhere in this file where the view is called by a string name, replace it by calling the object from the imported pulpo_form views. E.g.
url(r'^main/(?P<order>(id|owner|title|creation_date))/(?P<ad>(asc|dsc))/$', 'ordered_forms', name="main_sort")
should become:
url(r'^main/(?P<order>(id|owner|title|creation_date))/(?P<ad>(asc|dsc))/$', views.ordered_forms, name="main_sort")
This helps for me. Cheers.
Fresh installation. No changes. Settings as in documentation. No errors on 'django<1.10'.