Files
webgit/src/main/resources/templates/remote.html
Sebastiaan de Schaetzen 4458eb204b Show remotes in table with editable URLs on remote page
List all configured remotes in a table with name, editable URL
field with Save button, and per-remote Push/Pull buttons.
Add GitService.listRemotes() and updateRemoteUrl() methods.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
2026-02-27 09:28:43 +01:00

42 lines
923 B
HTML

<!DOCTYPE html>
<html xmlns:th="http://www.thymeleaf.org">
<head>
<title th:text="'Remote - ' + ${name}">Remote</title>
</head>
<body>
<h2>Remotes</h2>
<table border="1" cellpadding="4" cellspacing="0">
<tr>
<th>Name</th>
<th>URL</th>
<th></th>
<th></th>
</tr>
<tr th:each="entry : ${remotes}">
<td th:text="${entry.key}"></td>
<td>
<form method="post" th:action="@{/repo/{name}/update-remote(name=${name})}">
<input type="hidden" name="remote" th:value="${entry.key}">
<input type="text" name="url" th:value="${entry.value}" size="40">
<input type="submit" value="Save">
</form>
</td>
<td>
<form method="post" th:action="@{/repo/{name}/push(name=${name})}">
<input type="submit" value="Push">
</form>
</td>
<td>
<form method="post" th:action="@{/repo/{name}/pull(name=${name})}">
<input type="submit" value="Pull">
</form>
</td>
</tr>
</table>
<p th:if="${remotes.isEmpty()}">No remotes configured.</p>
</body>
</html>