I have some checkboxes that update from a database and then the user should modify those entries and click a buttton to save to the database again. The thing is that when I switch a selectbox from one item of the database to another and did manually modify the checkboxes values of the previous database item, the new one doesn’t load the database value and instead keeps the modified checkboxes from the last edition.
tarea = st.checkbox(
label = "Tarea",
value = alumnos_db.find_one({"_id":selected_student}).get(date_format,{}).get(course_selected,{}).get("tarea",False)
)
The above code is the one that whit any change in any other streamlit wodget (before those checkboxes) it runs and loads the value = alumnos...
part.
It works as I expect before touching any checkbox but after being changed manually, it keeps the last recorded value.