Task #7120 (closed)
Opened 12 years ago
Closed 12 years ago
Port to 1.2 template loaders
Reported by: | cxallan | Owned by: | cxallan |
---|---|---|---|
Priority: | critical | Milestone: | OMERO-4.4 |
Component: | Web | Version: | n.a. |
Keywords: | n.a. | Cc: | |
Resources: | n.a. | Referenced By: | n.a. |
References: | n.a. | Remaining Time: | n.a. |
Sprint: | n.a. |
Description (last modified by cxallan)
As of Django 1.2 the template loaders have gone from a callables based API to a class based one. Our usage will need to be ported throughout the application. Some details are available here:
Some of the deprecation warnings that not porting to this API create can be seen in #7118.
Change History (5)
comment:1 Changed 12 years ago by cxallan
- Description modified (diff)
comment:2 Changed 12 years ago by wmoore
comment:3 Changed 12 years ago by wmoore
It seems that it is not necessary to have an app turned "on" in order that you can use the templates within it:
http://docs.djangoproject.com/en/1.3/ref/templates/api/#template-loaders
Although you will need to add the location to TEMPLATE_DIRS.
Your templates can go anywhere you want, as long as the directories and templates are readable by the Web server. They can have any extension you want, such as .html or .txt, or they can have no extension at all.
comment:4 Changed 12 years ago by jburel
- Sprint 2011-11-10 (2) deleted
Referencing ticket #7116 has changed sprint.
comment:5 Changed 12 years ago by cxallan
- Resolution set to fixed
- Status changed from new to closed
All done and working.
Seems that the update to Class loaders requires us to edit 'omeroweb/settings.py'
Need to replace this:
With this (default)
http://docs.djangoproject.com/en/1.3/ref/settings/#std:setting-TEMPLATE_LOADERS