modocache / django-generate-scaffold

Generate a Django model, views, URLconf, and templates using a single command.
139 stars 39 forks source link

Django 1.5 support #27

Closed drillbits closed 11 years ago

drillbits commented 11 years ago

Put quotes around the first parameter of url template tags

The first parameter do not allow unquoted string since Django 1.5.

Add context_keys to TemplatesGenerator

MODEL_NAME_archive_year.html uses 'year' the context of YearArchiveView.

But, on Django 1.5, it is returned as a date object.

So the template must use 'year.year'.

In order to maintain backward compatibility, add context_keys and set proper key depending on the version of Django.

modocache commented 11 years ago

Thanks very much for your contribution! I will release this to PyPI as soon as possible, until then please use this SHA.

Currently the CI only tests Python 2.7 & Django 1.4, but I plan on adding tests which use Django 1.5. Any help would be very much appreciated! See: https://github.com/modocache/django-generate-scaffold/issues/23