Answer the question
In order to leave comments, you need to log in
Django.Theory: Implementing multiple checkboxes?
Hello.
I write a service about the sale / rent of real estate.
I am interested in the following question:
There is an object, let's call it for example "House",
the house has the following parameters:
1. "Name"
2. "Type of heating" with the following options
Answer the question
In order to leave comments, you need to log in
If the set of checkboxes is fixed, you need to create a field in the "house" model for each of the checkboxes.
Put a checkbox on each field in the form. Only the standard template will not work, you will have to create your own so that the checkboxes are shown in several lists. But it's not scary.
The search is trivial - everything is in one table.
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question