Updated documentation to include gotchas for existing models
parent
c34d067e10
commit
0ae9b5819d
22
README
22
README
|
|
@ -111,6 +111,25 @@ suggest NOT using SortableStackedInline. I'm currently working on
|
||||||
a way to make this more usable.
|
a way to make this more usable.
|
||||||
|
|
||||||
|
|
||||||
|
Potential Gotcha
|
||||||
|
=============
|
||||||
|
|
||||||
|
If you have an existing model that you're now making Sortable, existing
|
||||||
|
rows won't have an "order" attribute. Django-admin-sortable depends on
|
||||||
|
being able to leverage an aggregate Max to determine if a model is sortable.
|
||||||
|
|
||||||
|
A good rule of thumb if you're adding django-admin-sortable to an existing
|
||||||
|
project is to create a Data Migration using South to set the "order" column
|
||||||
|
according to your needs.
|
||||||
|
|
||||||
|
For example, if you have a SortableForeignKey field, you would need to set
|
||||||
|
the "order" column relative to that field, instead of setting the "order"
|
||||||
|
column in linear succession.
|
||||||
|
|
||||||
|
See: http://south.readthedocs.org/en/latest/tutorial/part3.html for more
|
||||||
|
information on Data Migrations.
|
||||||
|
|
||||||
|
|
||||||
Rationale
|
Rationale
|
||||||
=============
|
=============
|
||||||
Other projects have added drag-and-drop ordering to the ChangeList
|
Other projects have added drag-and-drop ordering to the ChangeList
|
||||||
|
|
@ -130,9 +149,10 @@ Status
|
||||||
admin-sortable is currently used in production.
|
admin-sortable is currently used in production.
|
||||||
|
|
||||||
|
|
||||||
What's new in 1.3.7?
|
What's new in 1.3.8?
|
||||||
=============
|
=============
|
||||||
- CSS fixes for tabular inlines courtesty of @ionelmc: https://github.com/ionelmc
|
- CSS fixes for tabular inlines courtesty of @ionelmc: https://github.com/ionelmc
|
||||||
|
- Updated documentation
|
||||||
|
|
||||||
Features
|
Features
|
||||||
=============
|
=============
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,4 @@
|
||||||
VERSION = (1, 3, 7) # following PEP 386
|
VERSION = (1, 3, 8) # following PEP 386
|
||||||
DEV_N = None
|
DEV_N = None
|
||||||
|
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue