refactor: Simplify strategy guide page navigation buttons
This commit is contained in:
parent
f9b6cb82f8
commit
99f890c4c6
@ -713,32 +713,9 @@ def strategy_guide_page():
|
|||||||
* Set price alerts
|
* Set price alerts
|
||||||
""")
|
""")
|
||||||
|
|
||||||
if st.button("Run Daily SunnyBands Scan"):
|
if st.button("Go to SunnyBands Scanner"):
|
||||||
with st.spinner("Running scanner..."):
|
st.session_state.page = "Technical Scanner"
|
||||||
try:
|
st.rerun()
|
||||||
signals = run_technical_scanner(
|
|
||||||
scanner_choice="sunnybands",
|
|
||||||
start_date=datetime.now().strftime("%Y-%m-%d"),
|
|
||||||
end_date=datetime.now().strftime("%Y-%m-%d"),
|
|
||||||
min_price=5.0,
|
|
||||||
max_price=100.0,
|
|
||||||
min_volume=500000,
|
|
||||||
portfolio_size=100000.0,
|
|
||||||
interval="1d"
|
|
||||||
)
|
|
||||||
if signals:
|
|
||||||
st.success(f"Found {len(signals)} potential setups")
|
|
||||||
for signal in signals:
|
|
||||||
with st.expander(f"{signal['ticker']} Setup"):
|
|
||||||
col1, col2 = st.columns(2)
|
|
||||||
with col1:
|
|
||||||
st.metric("Price", f"${signal['entry_price']:.2f}")
|
|
||||||
st.metric("Volume", f"{signal['volume']:,}")
|
|
||||||
with col2:
|
|
||||||
st.metric("Stop Loss", f"${signal['stop_loss']:.2f}")
|
|
||||||
st.metric("Target", f"${signal['target_price']:.2f}")
|
|
||||||
except Exception as e:
|
|
||||||
st.error(f"Error running scanner: {str(e)}")
|
|
||||||
|
|
||||||
# Morning Trading Section
|
# Morning Trading Section
|
||||||
with st.expander("2. Trading Strategy (6:30-7:30 AM PST)"):
|
with st.expander("2. Trading Strategy (6:30-7:30 AM PST)"):
|
||||||
@ -810,7 +787,7 @@ def strategy_guide_page():
|
|||||||
* Refine strategies
|
* Refine strategies
|
||||||
""")
|
""")
|
||||||
|
|
||||||
if st.button("Add Trade Review"):
|
if st.button("Go to Trading Journal"):
|
||||||
st.session_state.page = "Trading Journal"
|
st.session_state.page = "Trading Journal"
|
||||||
st.rerun()
|
st.rerun()
|
||||||
|
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user