Django Stories 1.0beta1 documentation
Version 1.0 includes of bunch of changes, some of which are not backwards compatible. This migration guide will try to help you upgrade your stories to 1.0.
Before we install the new version of stories, we need to determine which parts will need your attention. While there are no schema changes to stories and relations in 1.0, there are, however, some steps that need to be taken to ensure everything stays the same.
The setting USE_CATEGORIES has been removed, instead you will need to use the categories to register the fields you once had. These fields were hard coded into stories as primary_category and categories. Here is an example of what you can do
CATEGORIES_SETTINGS = {
'FK_REGISTRY': {
'stories.story': {
'name': 'primary_category', 'related_name': 'primary_category'
}
},
'M2M_REGISTRY': {
'stories.story': {
'name': 'categories', 'related_name': 'categories'
}
}
}
relations are now a seperate app within stories, you must add stories.relations to your INSTALLED_APPS
INSTALLED_APPS = (
...
'stories',
'stories.relations',
...
)
stories is now south enabled, however, there are some things you will need to know about how the initial migration runs. While you will be faking the initial migration, since your upgrading, these points are good to know.
The only requirement now is BeautifullSoup, all the others were removed. If you expect reversion, tinymce or categories to be installed via stories requirements, please update any site specific requirements file to include these packages.
django-tinymce was removed as a dependance of stories and therefore removed as the default widget for the body field. In order to get TinyMCE to render the body field you will need to supply WIDGET setting.
STORY_SETTINGS = {
...
'WIDGET': 'path.to.TinyMCEWIdget',
...
}
The relation template tags have moved into the relations app within stories. Any instance of {% load stories %} needs to be replaced with {% load story_relation_tags %}. The tag names are still the same and function the same
The setting STORY_ORDERING was renamed to simply ORDERING
While the property stil exists and functions the same, it was rather dumb in the way it worked. There is a new property called author_display which renders out a template you can use. This will be if you want to use a custom author model