Fixed merge conflicts.
commit
557d2d457d
|
|
@ -2,7 +2,7 @@
|
||||||
|
|
||||||
[](https://travis-ci.org/iambrandontaylor/django-admin-sortable)
|
[](https://travis-ci.org/iambrandontaylor/django-admin-sortable)
|
||||||
|
|
||||||
Current version: 2.0.13
|
Current version: 2.0.14
|
||||||
|
|
||||||
This project makes it easy to add drag-and-drop ordering to any model in
|
This project makes it easy to add drag-and-drop ordering to any model in
|
||||||
Django admin. Inlines for a sortable model may also be made sortable,
|
Django admin. Inlines for a sortable model may also be made sortable,
|
||||||
|
|
@ -496,14 +496,11 @@ ordering on top of that just seemed a little much in my opinion.
|
||||||
### Status
|
### Status
|
||||||
django-admin-sortable is currently used in production.
|
django-admin-sortable is currently used in production.
|
||||||
|
|
||||||
|
### What's new in 2.0.14?
|
||||||
### What's new in 2.0.13?
|
- Refactored exception handling when determining `order_field_name`
|
||||||
- Fixed an issue where the index_value for sortable stacked inlines might not have been found.
|
|
||||||
|
|
||||||
|
|
||||||
### Future
|
### Future
|
||||||
- Better template support for foreign keys that are self referential. If someone would like to take on rendering recursive sortables, that would be super.
|
- Better template support for foreign keys that are self referential. If someone would like to take on rendering recursive sortables, that would be super.
|
||||||
|
|
||||||
|
|
||||||
### License
|
### License
|
||||||
django-admin-sortable is released under the Apache Public License v2.
|
django-admin-sortable is released under the Apache Public License v2.
|
||||||
|
|
|
||||||
|
|
@ -3,7 +3,7 @@ Django Admin Sortable
|
||||||
|
|
||||||
|Build Status|
|
|Build Status|
|
||||||
|
|
||||||
Current version: 2.0.13
|
Current version: 2.0.14
|
||||||
|
|
||||||
This project makes it easy to add drag-and-drop ordering to any model in
|
This project makes it easy to add drag-and-drop ordering to any model in
|
||||||
Django admin. Inlines for a sortable model may also be made sortable,
|
Django admin. Inlines for a sortable model may also be made sortable,
|
||||||
|
|
@ -611,11 +611,11 @@ Status
|
||||||
|
|
||||||
django-admin-sortable is currently used in production.
|
django-admin-sortable is currently used in production.
|
||||||
|
|
||||||
What's new in 2.0.13?
|
|
||||||
|
What's new in 2.0.14?
|
||||||
~~~~~~~~~~~~~~~~~~~~~
|
~~~~~~~~~~~~~~~~~~~~~
|
||||||
|
|
||||||
- Fixed an issue where the index\_value for sortable stacked inlines
|
- Refactored exception handling when determining ``order_field_name``
|
||||||
might not have been found.
|
|
||||||
|
|
||||||
Future
|
Future
|
||||||
~~~~~~
|
~~~~~~
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,4 @@
|
||||||
VERSION = (2, 0, 13)
|
VERSION = (2, 0, 14)
|
||||||
DEV_N = None
|
DEV_N = None
|
||||||
|
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -194,7 +194,7 @@ class SortableAdmin(SortableAdminBase, ModelAdmin):
|
||||||
except (AttributeError, IndexError):
|
except (AttributeError, IndexError):
|
||||||
# for Django 1.5.x
|
# for Django 1.5.x
|
||||||
order_field_name = opts.ordering[0]
|
order_field_name = opts.ordering[0]
|
||||||
finally:
|
except (AttributeError, IndexError):
|
||||||
order_field_name = 'order'
|
order_field_name = 'order'
|
||||||
|
|
||||||
objects = objects.order_by(sortable_by_expression, order_field_name)
|
objects = objects.order_by(sortable_by_expression, order_field_name)
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue