mirror of
https://github.com/pretix/pretix.git
synced 2026-05-07 15:34:02 +00:00
Added ordering in admin interface order list
This commit is contained in:
committed by
Raphael Michel
parent
39e940da5e
commit
ad2a712934
@@ -69,6 +69,12 @@ class OrderList(EventPermissionRequiredMixin, ListView):
|
||||
if self.request.GET.get("provider", "") != "":
|
||||
p = self.request.GET.get("provider", "")
|
||||
qs = qs.filter(payment_provider=p)
|
||||
if self.request.GET.get("ordering", "") != "":
|
||||
p = self.request.GET.get("ordering", "")
|
||||
p_admissable = ('-code', 'code', '-email', 'email', '-total', 'total', '-datetime', 'datetime', '-status', 'status')
|
||||
if p in p_admissable:
|
||||
qs = qs.order_by(p)
|
||||
|
||||
return qs.distinct()
|
||||
|
||||
def get_payment_providers(self):
|
||||
|
||||
Reference in New Issue
Block a user