Your Name 3 سال پیش
والد
کامیت
eb6dd60df1
1فایلهای تغییر یافته به همراه4 افزوده شده و 3 حذف شده
  1. 4 3
      step_question/apis/main.py

+ 4 - 3
step_question/apis/main.py

@@ -42,10 +42,11 @@ async def submit(request: Request):
     }
     }
     print(result)
     print(result)
     get_db().insert(result)
     get_db().insert(result)
-    fr=codecs.open('static/index_complete.html','r','utf-8')
-    lines=fr.read()
-    fr.close()
+#    fr=codecs.open('static/index_complete.html','r','utf-8')
+#    lines=fr.read()
+#    fr.close()
 #    response = RedirectResponse(url='/a1/index_complete.html')
 #    response = RedirectResponse(url='/a1/index_complete.html')
+    lines='<html><body><script>    window.location.href = "/a1/index_complete.html"; </script>'
     return HTMLResponse(content=lines, status_code=200)
     return HTMLResponse(content=lines, status_code=200)
 
 
 #    return result
 #    return result