Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
|
@@ -37,7 +37,7 @@ st.markdown("""
|
|
| 37 |
""", unsafe_allow_html=True)
|
| 38 |
|
| 39 |
# Display the header
|
| 40 |
-
st.markdown('<div class="header">๐
|
| 41 |
|
| 42 |
st.markdown("""
|
| 43 |
<div class="description-box">
|
|
@@ -93,7 +93,9 @@ if submit_button_left:
|
|
| 93 |
advice = st.text_area(" ", height=100)
|
| 94 |
submit_button_right = st.button("์กฐ์ธ ์ ์ถํ๊ธฐ")
|
| 95 |
|
| 96 |
-
if
|
| 97 |
-
# Google Sheets
|
| 98 |
-
|
| 99 |
st.success("์กฐ์ธ์ด ์ฑ๊ณต์ ์ผ๋ก ์ ์ถ๋์์ต๋๋ค!")
|
|
|
|
|
|
|
|
|
| 37 |
""", unsafe_allow_html=True)
|
| 38 |
|
| 39 |
# Display the header
|
| 40 |
+
st.markdown('<div class="header">๐ ๊ณ ๋ฏผํด๊ฒฐ ๋์์ฃผ๊ธฐ ๐ </div>', unsafe_allow_html=True)
|
| 41 |
|
| 42 |
st.markdown("""
|
| 43 |
<div class="description-box">
|
|
|
|
| 93 |
advice = st.text_area(" ", height=100)
|
| 94 |
submit_button_right = st.button("์กฐ์ธ ์ ์ถํ๊ธฐ")
|
| 95 |
|
| 96 |
+
if not st.session_state.get('submitted', False): # 'submitted' ์ํ๊ฐ False์ธ ๊ฒฝ์ฐ์๋ง ์คํ
|
| 97 |
+
record_advice("์ ํ๋ ๊ณ ๋ฏผ ๋ด์ฉ", advice) # Google Sheets์ ๊ธฐ๋ก
|
| 98 |
+
st.session_state['submitted'] = True # 'submitted' ์ํ๋ฅผ True๋ก ์ค์ ํ์ฌ ์ค๋ณต ์ ์ถ ๋ฐฉ์ง
|
| 99 |
st.success("์กฐ์ธ์ด ์ฑ๊ณต์ ์ผ๋ก ์ ์ถ๋์์ต๋๋ค!")
|
| 100 |
+
else:
|
| 101 |
+
st.warning("์ด๋ฏธ ์ ์ถ๋์์ต๋๋ค.") # ์ด๋ฏธ ์ ์ถ๋ ๊ฒฝ์ฐ ๊ฒฝ๊ณ ๋ฉ์์ง ์ถ๋ ฅ
|