[V0.2] WORKING Working calendar and AI with full frontend.

This commit is contained in:
c-d-p
2025-04-20 12:12:35 +02:00
parent ee86374da6
commit 6cee996fb3
27 changed files with 996 additions and 488 deletions

View File

@@ -7,6 +7,12 @@ from core.database import get_engine, Base
from modules import router
import logging
# import all models to ensure they are registered before create_all
from modules.calendar.models import CalendarEvent
from modules.auth.models import User
logging.getLogger('passlib').setLevel(logging.ERROR) # fix bc package logging is broken
# Create DB tables (remove in production; use migrations instead)
@@ -29,7 +35,11 @@ app.include_router(router)
# CORS
app.add_middleware(
CORSMiddleware,
allow_origins=["http://localhost:8081"],
allow_origins=[
"http://localhost:8081", # Keep for web testing if needed
"http://192.168.1.9:8081", # Add your mobile device/emulator origin (adjust port if needed)
# Add other origins if necessary, e.g., production frontend URL
],
allow_credentials=True,
allow_methods=["*"],
allow_headers=["*"]