Some checks failed
Build & Push Docker / build (push) Has been cancelled
- Remove all Excel code (import, export, template, pandas, openpyxl) - New canvas-based schedule editor with drag & drop (interact.js) - Modern 3-panel UI: sidebar, canvas, documentation tab - New data model: Block with id/date/start/end, ProgramType with id/name/color - Clean API: GET /api/health, POST /api/validate, GET /api/sample, POST /api/generate-pdf - Rewritten PDF generator using ScenarioDocument directly (no DataFrame) - Professional PDF output: dark header, colored blocks, merged cells, legend, footer - Sample JSON: "Zimní výjezd oddílu" with 11 blocks, 3 program types - 30 tests passing (API, core models, PDF generation) Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
27 lines
695 B
Python
27 lines
695 B
Python
"""FastAPI application entry point."""
|
|
|
|
from fastapi import FastAPI
|
|
from fastapi.staticfiles import StaticFiles
|
|
from fastapi.responses import FileResponse
|
|
import os
|
|
|
|
from app.api.router import api_router
|
|
from app.config import VERSION
|
|
|
|
app = FastAPI(
|
|
title="Scenar Creator",
|
|
description="Web tool for creating experience course scenarios with canvas editor",
|
|
version=VERSION,
|
|
)
|
|
|
|
app.include_router(api_router)
|
|
|
|
# Static files
|
|
static_dir = os.path.join(os.path.dirname(__file__), "static")
|
|
app.mount("/static", StaticFiles(directory=static_dir), name="static")
|
|
|
|
|
|
@app.get("/", include_in_schema=False)
|
|
async def root():
|
|
return FileResponse(os.path.join(static_dir, "index.html"))
|