galerie/views.py: oprava sorteni obrazku
This commit is contained in:
parent
7b3f423a74
commit
66715166d4
1 changed files with 2 additions and 2 deletions
|
@ -38,7 +38,7 @@ def nahled(request, pk, soustredeni):
|
|||
if not request.user.is_staff:
|
||||
podgalerie = podgalerie.filter(zobrazit__lt=1)
|
||||
|
||||
obrazky = Obrazek.objects.filter(galerie = galerie)
|
||||
obrazky = Obrazek.objects.filter(galerie = galerie).order_by('poradi')
|
||||
preview = zobrazit(galerie, request)
|
||||
|
||||
sourozenci = []
|
||||
|
@ -82,7 +82,7 @@ def detail(request, pk, fotka, soustredeni):
|
|||
galerie = get_object_or_404(Galerie, pk=pk)
|
||||
preview = zobrazit(galerie, request)
|
||||
obrazek = get_object_or_404(Obrazek, pk=fotka)
|
||||
obrazky = galerie.obrazek_set.all()
|
||||
obrazky = galerie.obrazek_set.all().order_by('poradi')
|
||||
|
||||
# vytvoreni a obslouzeni formulare
|
||||
if request.method == 'POST':
|
||||
|
|
Loading…
Reference in a new issue