Spaces:
Running
Running
- __pycache__/app.cpython-311.pyc +0 -0
- instance/coursels.db +0 -3
- instance/courses.db +0 -0
- reset_db.py +7 -0
__pycache__/app.cpython-311.pyc
ADDED
|
Binary file (33.1 kB). View file
|
|
|
instance/coursels.db
DELETED
|
@@ -1,3 +0,0 @@
|
|
| 1 |
-
version https://git-lfs.github.com/spec/v1
|
| 2 |
-
oid sha256:63df5905a95a503712def14d95e3161c838b7f28682649b42f36abc6f721b64c
|
| 3 |
-
size 512000
|
|
|
|
|
|
|
|
|
|
|
|
instance/courses.db
CHANGED
|
Binary files a/instance/courses.db and b/instance/courses.db differ
|
|
|
reset_db.py
ADDED
|
@@ -0,0 +1,7 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
from app import app, db, add_sample_data
|
| 2 |
+
|
| 3 |
+
with app.app_context():
|
| 4 |
+
db.drop_all()
|
| 5 |
+
db.create_all()
|
| 6 |
+
add_sample_data()
|
| 7 |
+
print("Database reset complete.")
|