random shuffle
This commit is contained in:
parent
424ce56ac6
commit
af72b86197
@ -5,6 +5,7 @@ from datetime import date, datetime
|
||||
import json
|
||||
import glob
|
||||
import PIL.Image
|
||||
import random
|
||||
|
||||
from .models import User, ALKATOR_CHOICES_DICT
|
||||
|
||||
@ -66,6 +67,7 @@ def results(request):
|
||||
def photos(request):
|
||||
files = glob.glob("photos/*.jpg")
|
||||
rtn = []
|
||||
random.shuffle(files)
|
||||
for file in files:
|
||||
img = PIL.Image.open(file)
|
||||
rtn.append({
|
||||
|
Loading…
x
Reference in New Issue
Block a user