Spaces:
Running
Running
Update app.py
Browse files
app.py
CHANGED
@@ -328,13 +328,13 @@ def show_field(f: Field, index: int, data_collected):
|
|
328 |
value=value, help=f.help)
|
329 |
case 'multiselect':
|
330 |
choices = default_choices if not f.other_params.get('choices') else f.other_params.get('choices')
|
331 |
-
|
332 |
-
|
333 |
-
options = choices,
|
334 |
format_func=lambda x: x,
|
335 |
key=key, max_selections=3,
|
336 |
help=f.help)
|
337 |
-
st.session_state[key] =
|
338 |
case 'likert_radio':
|
339 |
labels = default_labels if not f.other_params.get('labels') else f.other_params.get('labels')
|
340 |
st.radio(f.title,
|
|
|
328 |
value=value, help=f.help)
|
329 |
case 'multiselect':
|
330 |
choices = default_choices if not f.other_params.get('choices') else f.other_params.get('choices')
|
331 |
+
key = f.name + str(index)
|
332 |
+
value = st.multiselect(f.title,
|
333 |
+
options = choices,
|
334 |
format_func=lambda x: x,
|
335 |
key=key, max_selections=3,
|
336 |
help=f.help)
|
337 |
+
st.session_state[key] = value
|
338 |
case 'likert_radio':
|
339 |
labels = default_labels if not f.other_params.get('labels') else f.other_params.get('labels')
|
340 |
st.radio(f.title,
|