Changing ordering of model in the admin views

38 views
Skip to first unread message

אורי

unread,
Oct 10, 2020, 4:34:19 AM10/10/20
to django...@googlegroups.com
Django users,

I have a User model, in which I defined class Meta with ordering. It's defined like this:

class Meta:
verbose_name = _('user')
verbose_name_plural = _('users')
ordering = ('-speedy_net_site_profile__last_visit',)
swappable = 'AUTH_USER_MODEL'

But, I have two apps - Speedy Net and Speedy Match, and in Speedy Match I want a different order (
      ordering = ('-speedy_match_site_profile__last_visit',)
). How can I do this?

Thanks,

Dvs Khamele

unread,
Oct 11, 2020, 1:01:14 PM10/11/20
to django...@googlegroups.com
Hi do you hire contract based python/django freelancer?
 We can help you in this and related tasks at fair prices. Reply or send email to div...@pythonmate.com
Best Regards, 
Divyesh Khamele,
Pythonmate

--
You received this message because you are subscribed to the Google Groups "Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to django-users...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/django-users/CABD5YeEgKXis7GiwL%2BHtmAt8gSwwqaDOVpzOS-M8-NiL%3D5cPWg%40mail.gmail.com.
Reply all
Reply to author
Forward
0 new messages