Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
@@ -60,15 +60,17 @@ if st.button("Generate Study Plan"):
|
|
60 |
|
61 |
# Export options
|
62 |
col1, col2 = st.columns(2)
|
|
|
63 |
with col1:
|
64 |
if st.button("Export to PDF"):
|
65 |
pdf_file = export_to_pdf(study_plan)
|
66 |
st.success(f"Study plan exported as {pdf_file}")
|
67 |
with open(pdf_file, "rb") as file:
|
68 |
-
st.download_button("Download PDF", file, file_name="study_plan.pdf")
|
|
|
69 |
with col2:
|
70 |
if st.button("Export to Excel"):
|
71 |
excel_file = export_to_excel(study_plan)
|
72 |
st.success(f"Study plan exported as {excel_file}")
|
73 |
with open(excel_file, "rb") as file:
|
74 |
-
st.download_button("Download Excel", file, file_name="study_plan.xlsx")
|
|
|
60 |
|
61 |
# Export options
|
62 |
col1, col2 = st.columns(2)
|
63 |
+
|
64 |
with col1:
|
65 |
if st.button("Export to PDF"):
|
66 |
pdf_file = export_to_pdf(study_plan)
|
67 |
st.success(f"Study plan exported as {pdf_file}")
|
68 |
with open(pdf_file, "rb") as file:
|
69 |
+
st.download_button("Download PDF", file, file_name="study_plan.pdf", key="pdf_download")
|
70 |
+
|
71 |
with col2:
|
72 |
if st.button("Export to Excel"):
|
73 |
excel_file = export_to_excel(study_plan)
|
74 |
st.success(f"Study plan exported as {excel_file}")
|
75 |
with open(excel_file, "rb") as file:
|
76 |
+
st.download_button("Download Excel", file, file_name="study_plan.xlsx", key="excel_download")
|