feat: portable Windows data layout and launcher package

Separate persistent user data from application code (data/work_tracker.db,
data/uploads, data/storage) with idempotent legacy migration and SQLite
integrity checks. Add offline packaging scripts for a Windows x11 x64
portable ZIP (embeddable Python, Start/Stop/Backup.bat). Fix launcher:
no multiline python -c in BAT and no os.dup2 — uvicorn runs detached with
wvt.log; health wait and busy-port diagnostics included.
This commit is contained in:
Арсентьев Александр
2026-10-20 15:55:04 +03:00
parent a6449a7d70
commit b97d79e13a
28 changed files with 2432 additions and 11 deletions
+2 -1
View File
@@ -1,6 +1,7 @@
from fastapi import APIRouter, Depends, HTTPException, Request, Form, UploadFile, File
from fastapi.responses import RedirectResponse
from sqlalchemy.orm import Session
from app.config import uploads_dir
from app.database import database
from app.models import project, boq
from app.models.daily_report import DailyReport, DailyReportItem
@@ -11,7 +12,7 @@ from decimal import Decimal
from pathlib import Path
router = APIRouter()
UPLOAD_DIR = Path(__file__).resolve().parents[1] / "uploads"
UPLOAD_DIR = uploads_dir()
def _completed_quantities(db, project_id, items):