Spaces:
Build error
Build error
Commit ·
44a3325
1
Parent(s): d9d8ffb
Update ui_utils.py
Browse files23 unmodified lines2425262728293023 unmodified lineselif st.session_state.query_flow:existing_classes = [cls["class"] for cls in client.schema.get()["classes"]]class_options = existing_classes + ["Query all data"]return st.selectbox("Select a class or query all data:", class_options, key="class_selector_query")def handle_new_class_selection(client, selected_class):if selected_class == "New Class":23 unmodified lines242526272829303132333435363723 unmodified lineselif st.session_state.query_flow:existing_classes = [cls["class"] for cls in client.schema.get()["classes"]]class_options = existing_classes + ["Query all data"]selected_option = st.selectbox("Select a class or query all data:", class_options, key="class_selector_query")if selected_option == "Query all data":# If "Query all data" is selected, return the first class as a default for now# You can modify this behavior as neededreturn existing_classes[0]else:return selected_optiondef handle_new_class_selection(client, selected_class):if selected_class == "New Class":
ui_utils.py+8-1