Skip to content

Commit e78597b

Browse files
committed
fix: update session filter message to indicate recent 6 months only
1 parent 55e9403 commit e78597b

File tree

1 file changed

+6
-3
lines changed

1 file changed

+6
-3
lines changed

code/Home.py

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -454,9 +454,6 @@ def app():
454454
# -- 1. unit dataframe --
455455

456456
cols = st.columns([4, 4, 4, 1])
457-
cols[0].markdown(f'### Filter the sessions on the sidebar\n'
458-
f'##### {len(st.session_state.df_session_filtered)} sessions, '
459-
f'{len(st.session_state.df_session_filtered.subject_id.unique())} mice filtered')
460457

461458
with cols[0].expander(':bulb: Get the master session table by code', expanded=False):
462459
st.code(f'''
@@ -493,6 +490,12 @@ def app():
493490
sync_session_state_to_URL()
494491
init()
495492
st.rerun() # Reload the page to apply the changes
493+
494+
cols[0].markdown(f'### Filter the sessions on the sidebar\n' +
495+
f'##### {len(st.session_state.df_session_filtered)} sessions, ' +
496+
f'{len(st.session_state.df_session_filtered.subject_id.unique())} mice filtered' +
497+
(f' (recent 6 months only)' if not st.session_state.if_load_sessions_older_than_6_month else '')
498+
)
496499

497500
table_height = slider_wrapper_for_url_query(st_prefix=cols[-1],
498501
label='Table height',

0 commit comments

Comments
 (0)