working download

This commit is contained in:
William Zhang 2018-05-08 16:58:52 -04:00
parent 00e853bc93
commit 5b33ef03cc
2 changed files with 3 additions and 2 deletions

1
.gitignore vendored
View File

@ -17,3 +17,4 @@ config.py
settings.py settings.py
env/ env/
db.sqlite3 db.sqlite3
*.json

View File

@ -21,9 +21,9 @@ import requests
about = requests.get("https://sgawebsite-e30e2.firebaseio.com/about.json") about = requests.get("https://sgawebsite-e30e2.firebaseio.com/about.json")
forms = requests.get("https://sgawebsite-e30e2.firebaseio.com/forms.json") forms = requests.get("https://sgawebsite-e30e2.firebaseio.com/forms.json")
with open("about.json", 'w') as f: with open("about.json", 'w') as f:
f.write(about.json()) f.write(str(about.json()[0]))
with open("forms.json", 'w') as f: with open("forms.json", 'w') as f:
f.write(forms.json()) f.write(str(forms.json()[0]))
urlpatterns = [ urlpatterns = [