From 2b49c995a0f8ac2eb76540f6d14acf69940cb751 Mon Sep 17 00:00:00 2001 From: ix <0x00fi@protonmail.com> Date: Wed, 8 Sep 2021 21:50:28 +0200 Subject: [PATCH] category challenges listed by point decrease --- src/ctfs/views.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/ctfs/views.py b/src/ctfs/views.py index 78c62df..0b0c1b3 100644 --- a/src/ctfs/views.py +++ b/src/ctfs/views.py @@ -21,7 +21,7 @@ def get_description_by_lang(ctf): def category(request, cat_slug): cat = get_object_or_404(Category, slug=cat_slug) - ctfs = CTF.objects.filter(category=cat).order_by('-points') + ctfs = CTF.objects.filter(category=cat).order_by('points') for ex in ctfs: ex.solved_num = CTF_flags.objects.filter(ctf=ex).count() ex.solved = ex.solved_by(request.user)