From 7c2e807d36a3887b2cda1524ae0f0fff0d4972c3 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C4=99drzej=20Klepacki?= Date: Sat, 9 Jan 2021 19:36:38 +0100 Subject: [PATCH] usluga przedmiot --- .../homepage/__pycache__/views.cpython-37.pyc | Bin 13240 -> 13247 bytes SocialHelper/homepage/views.py | 10 +++++----- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/SocialHelper/homepage/__pycache__/views.cpython-37.pyc b/SocialHelper/homepage/__pycache__/views.cpython-37.pyc index 534ec636de3cdebb55c6980a169b2ca9e7d12197..9552f0617bbfb2455b1769ee39ab8e4fc920e2c4 100644 GIT binary patch delta 125 zcmdmyzCWGUiI}9NFtl>!E&1RawSj1Jsn8lRBm?AX!AGf@M@Ep!so)XR)rUhIzJT(jpnVK1c88k)w cLNpnRq=Dv7PGA+C9K=)2RHVQ81kVRG0G;t7J^%m! delta 122 zcmdm=z9XI2iIxE#sDBso_lFpL~K_Mhe8}Wvpea z;Yi`lW}3iQ#8tzX#gxLBA~^XUx4eST9L`#v63!Z?1za^eH4F=xni+!`G==>_G#QJe Uf#y$6U=^Jl#8bWb3eRgb02KluPXGV_ diff --git a/SocialHelper/homepage/views.py b/SocialHelper/homepage/views.py index e1048a4..167543a 100644 --- a/SocialHelper/homepage/views.py +++ b/SocialHelper/homepage/views.py @@ -134,19 +134,19 @@ def filter(request): if oddam_local == "on" and potrzebuje_local != "on": zmienna = 2 - all_product = all_product.filter(type=zmienna) + all_product = all_product.filter(type=2) if oddam_local != "on" and potrzebuje_local == "on": zmienna = 1 - all_product = all_product.filter(type=zmienna) + all_product = all_product.filter(type=1) if usluga_local == "on" and przedmiot_local != "on": zmienna = 1 - all_product = all_product.filter(type=zmienna) + all_product = all_product.filter(offer=1) if usluga_local != "on" and przedmiot_local == "on": zmienna = 2 - all_product = all_product.filter(type=zmienna) + all_product = all_product.filter(offer=2) if wol_local == "on": all_product = all_product.filter(Wolontatriat=True) @@ -519,7 +519,7 @@ def offer(request, offer_id): user_list = chat.objects.values_list('author_id', flat=True).distinct('author_id').filter(product_id = offer_id, sec_user_id = request.user.id).exclude(author_id = request.user.id) User = get_user_model() email_list = User.objects.filter(id__in = user_list) - else: + else: user_list = chat.objects.none() email_list = chat.objects.none()