2024-04-11 15:09:27 +02:00
|
|
|
def diet_restriction(meals,client):
|
2024-04-11 15:44:45 +02:00
|
|
|
flag = True
|
|
|
|
print(client.restrykcje_dietowe)
|
|
|
|
|
2024-04-11 15:09:27 +02:00
|
|
|
for meal in meals:
|
|
|
|
vegan,vegetarian,meat = meal.vegan_vegetarian_meat
|
|
|
|
print(meal)
|
2024-04-11 15:44:45 +02:00
|
|
|
if not vegan and client.restrykcje_dietowe == 'Vegan':
|
|
|
|
print("tu")
|
|
|
|
|
|
|
|
flag = False
|
|
|
|
elif client.restrykcje_dietowe == 'Vegetarian' and meat:
|
|
|
|
print("tu2")
|
|
|
|
flag = False
|
|
|
|
|
|
|
|
print("----------------------------------")
|
|
|
|
return flag
|
2024-04-11 15:09:27 +02:00
|
|
|
|