You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Is it possible to define one of the inputs based on another input when we have multiple inputs in input_group? This requires some way of passing the output of an input in the input_group to the next input. An application of this is when we have two drop down menus for example and the options of the second drop down menu change based on what the user chooses from the first drop down menu. Something like this example:
DBs= ['DB1', 'DB2', 'DB3']
Tables= ['Table1', 'Table2', 'Table3', 'Table4']
text_info=input_group('Database and table name', [
select(label='Select the database of the table:', options=DBs, name='DB_name'),
select(label='Select the name of the table:', options=Tables, name='Table_name')
])
So is there a way to bind the options of the second drop down menu above to the user selection from the first drop down? Like if the user chooses 'DB1' then the options in the second menu will be 'Table1' and 'Table2' but if the user chooses 'DB2' the options will be 'Table3' and 'Table4'.
The text was updated successfully, but these errors were encountered:
PyWebIO does not support this feature currently. I will add it in todo list.
Here is a workaround for now:
DBs= ['DB1', 'DB2']
Tables= {'DB1': ['Table1', 'Table2', ], 'DB2': ['Table3', 'Table4']}
db_name=select(label='Select the database of the table:', options=DBs)
table_name=select(label='Select the name of the table:', options=Tables[db_name])
put_text(table_name)
Is it possible to define one of the inputs based on another input when we have multiple inputs in input_group? This requires some way of passing the output of an input in the input_group to the next input. An application of this is when we have two drop down menus for example and the options of the second drop down menu change based on what the user chooses from the first drop down menu. Something like this example:
So is there a way to bind the options of the second drop down menu above to the user selection from the first drop down? Like if the user chooses 'DB1' then the options in the second menu will be 'Table1' and 'Table2' but if the user chooses 'DB2' the options will be 'Table3' and 'Table4'.
The text was updated successfully, but these errors were encountered: