0
Doubt in Django
How does the filter query set work? Like, Room.objects.filter(R_category=room_category,available=True) Room - model name, R_category = charfield in Room model, available = booleanfield in Room model
1 Resposta
+ 1
The query will filter all objects in the 'Room' model, whose 'R_category' field is equal to 'room_category' and 'available' field is set to True.
See this:
https://docs.djangoproject.com/en/3.2/topics/db/queries/#retrieving-specific-objects-with-filters