diff --git a/src/pages/trading/trading_system_page.py b/src/pages/trading/trading_system_page.py index e28727e..31d06af 100644 --- a/src/pages/trading/trading_system_page.py +++ b/src/pages/trading/trading_system_page.py @@ -247,42 +247,31 @@ def trading_system_page(): col1, col2 = st.columns(2) with col1: - ticker = st.text_input("Ticker", value=str(prefill.get('ticker', ''))) + ticker = st.text_input("Ticker", value=str(prefill.get('ticker', '')), key="watchlist_ticker") entry_price = st.number_input("Entry Price", value=float(prefill.get('entry_price') or 0.0), min_value=0.0, step=0.01, - format="%.2f") + format="%.2f", + key="watchlist_entry_price") shares = st.number_input("Shares", value=int(prefill.get('shares') or 0), min_value=0, - step=1) + step=1, + key="watchlist_shares") with col2: target_price = st.number_input("Target Price", value=float(prefill.get('target_price') or 0.0), min_value=0.0, step=0.01, - format="%.2f") + format="%.2f", + key="watchlist_target_price") stop_loss = st.number_input("Stop Loss", value=float(prefill.get('stop_loss') or 0.0), min_value=0.0, step=0.01, - format="%.2f") - shares = st.number_input("Shares", - value=prefill.get('shares', 0), - min_value=0, - step=1) - with col2: - target_price = st.number_input("Target Price", - value=prefill.get('target_price', 0.0), - min_value=0.0, - step=0.01, - format="%.2f") - stop_loss = st.number_input("Stop Loss", - value=prefill.get('stop_loss', 0.0), - min_value=0.0, - step=0.01, - format="%.2f") + format="%.2f", + key="watchlist_stop_loss") notes = st.text_area("Notes")