feat: sidebar Repository identique au Workspace-local, pages forge unifiees, GC miroirs vides
FlowDeck CI / lint (push) Successful in 1m37s
FlowDeck CI / test (push) Successful in 25m11s
FlowDeck CI / docker (push) Successful in 1m32s

This commit is contained in:
2026-10-09 22:33:34 -04:00
parent 9ea0cddf3c
commit d95178156f
13 changed files with 1110 additions and 175 deletions
+11
View File
@@ -34,8 +34,19 @@ router = APIRouter(tags=["board"], prefix="/board")
@router.get("/{owner}/{repo}", response_class=HTMLResponse)
def board(request: Request, owner: str, repo: str, view: str = Query(default="")):
from app.auth.session import SessionManager
from app.routers.dashboard._common import _cleanup_empty_mirrors, _ensure_forge_mirror
from app.templating import ENV
env = ENV
# Selecting a repository also opens a workspace-local of the same name:
# ensure the mirror exists, prune other empty mirrors.
user = SessionManager.decode_session(request.cookies.get("flowdeck_session", ""))
if user and owner and repo:
try:
mid = _ensure_forge_mirror(user["id"], owner, repo, forge="gitea")
_cleanup_empty_mirrors(user["id"], keep_name=f"{owner}/{repo}", keep_id=mid or 0)
except Exception:
logger.exception("board mirror ensure")
sidebar = _sidebar_data(request, owner, repo)
template = env.get_template("board.html")
return template.render(request=request, owner=owner, repo=repo, groups=[],