#12875: Cannot redefine admin ordering dynamically ----------------------------------+----------------------------------------- Reporter: msaelices | Owner: nobody Status: new | Milestone: Component: django.contrib.admin | Version: 1.1 Keywords: | Stage: Unreviewed Has_patch: 0 | ----------------------------------+----------------------------------------- Sometimes you need redefine ordering dinamically, based in some logic at runtime
A example of that needed was this code: {{{ #!python class MyBaseAdmin(admin.ModelAdmin): def get_ordering(self, request): # I'd like i.e. a different order based on user or whatever if request.user.is_superuser(): ... return super(MyBaseAdmin, self).get_ordering(request) }}} -- Ticket URL: <http://code.djangoproject.com/ticket/12875> Django <http://code.djangoproject.com/> The Web framework for perfectionists with deadlines. -- You received this message because you are subscribed to the Google Groups "Django updates" group. To post to this group, send email to django-upda...@googlegroups.com. To unsubscribe from this group, send email to django-updates+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/django-updates?hl=en.