paov 4 years ago
parent b0f1b4690f
commit 77b7f43ba1
  1. 3
      choose/views.py

@ -28,7 +28,10 @@ def login_requiered(func):
def list_of_teas(request): def list_of_teas(request):
my_choice = Choice.objects.filter(users__in=[request.user]).first() my_choice = Choice.objects.filter(users__in=[request.user]).first()
if my_choice is None:
choice = json.loads(my_choice.choice) choice = json.loads(my_choice.choice)
else:
choice = {}
print(choice) print(choice)
dic = OrderedDict() dic = OrderedDict()
for cat in TeaCategory.objects.all(): for cat in TeaCategory.objects.all():

Loading…
Cancel
Save