Avatar ·

Django Solr (Filter) - a falling list for objects, how to implement? or adapt

📁 список, python, пример

There is such a list of objects displayed by the value of the attributes of goods.

the values ​​of the attributes of goods that are interconnected - should be in the form of a drop -down SELECT (OPTION) list/dropdownMenu, i.e. - For example, instead of Size: Medium, Size: Small it should just be

  mediumsmall    

that these values ​​of the attributes are applied SIZE can be specified inside TemPlates (Label), i.e. This is not so important, the main thing is how they can be placed in this Select list (dropdown menu).


I want to add that I tried to change the values ​​that are indicated by the default, in TemPlates, instead of checkboxes - I tried to indicate Select Option, but the result was obtained Inappropriate

.


tamplates

browse.html:

  {%  for  field, Data  in  fact_data.items %}  { % ""> if> data.results %} r { % include  'search/partials/fact.html'   with  name = data.name items = data.ressults %}  { % endfor %}     

facet.html:

  { %  for  item  in  items %}  & lt; dd & gt;  & lt;  input   class  =  "" Facet_checkbox ""   type  =  name = " "{ithem.name }} "" /& gt;  & lt;  input   class  =   type  =