<!DOCTYPE html>
<html lang="zh-CN">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Sessions - Open Code Review Viewer</title>
    <link rel="stylesheet" href="/static/style.css">
</head>
<body>
<nav class="breadcrumb"><a href="/">Open Code Review Viewer</a> &rsaquo; <a href="/r/{{.EncodedRepo}}">{{.RepoName}}</a></nav>
<main>
<h2>Sessions: {{.RepoName}}</h2>
{{if .Sessions}}
<table class="table">
    <thead><tr><th>Session ID</th><th>Branch</th><th>Model</th><th>Files</th><th>Duration</th><th>Started At</th></tr></thead>
    <tbody>
    {{range .Sessions}}
        <tr>
            <td><a href="/r/{{$.EncodedRepo}}/{{.SessionID}}">{{.SessionID | printf "%.8s"}}…</a></td>
            <td>{{.GitBranch}}</td>
            <td><code>{{.Model}}</code></td>
            <td>{{.FileCount}}</td>
            <td>{{formatDuration .DurationSec}}</td>
            <td>{{formatTime .Timestamp}}</td>
        </tr>
    {{end}}
    </tbody>
</table>
{{else}}
<p>No sessions found for this repository.</p>
{{end}}
</main>
</body>
</html>
