Spaces:
Sleeping
Sleeping
Update app.py
Browse files139 unmodified lines1401411421431431441451471461471481491 unmodified line151152153155156154155156157158139 unmodified lines st.session_state.user_type = None st.session_state.username = "" st.rerun()# زر تحميل قاعدة البيانات يظهر فقط للمشرف adminif st.session_state.get("username") == "admin": st.subheader("🗃️ إدارة قاعدة البيانات") try: if os.path.exists("complaints_system.db"): with open("complaints_system.db", "rb") as f: st.download_button( label="📥 تحميل قاعدة البيانات",1 unmodified line file_name="complaints_system.db", mime="application/octet-stream" ) except FileNotFoundError: st.error("⚠️ قاعدة البيانات غير موجودة!") else: st.error("⚠️ ملف قاعدة البيانات غير موجود!")
app.py+4-4