nano-run/templates/units-list.html

103 lines
4.4 KiB
HTML
Raw Normal View History

2020-09-28 13:46:37 +00:00
<html>
2020-09-28 15:12:57 +00:00
<head>
2020-10-01 13:09:40 +00:00
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no">
2020-09-28 15:12:57 +00:00
</head>
2020-09-28 13:46:37 +00:00
<body>
2020-10-01 13:09:40 +00:00
<div class="container">
<nav class="navbar navbar-expand-sm navbar-light bg-light">
<a class="navbar-brand" href="{{.Rel "/"}}">Nano-Run</a>
<div class="collapse navbar-collapse">
<ul class="navbar-nav mr-auto">
<li class="nav-item active">
<a class="nav-link" href="{{.Rel "/unit/"}}">All units</a>
</li>
{{if .Authorized}}
<li class="nav-item">
<a class="nav-link" href="{{.Rel "/auth/logout"}}">Logout</a>
</li>
{{end}}
</ul>
</div>
<span class="navbar-text">{{.Login}}</span>
2020-09-28 15:12:57 +00:00
</nav>
2020-10-01 13:09:40 +00:00
<br/>
<div class="row">
<div class="col">
<div class="card">
<div class="card-body">
<h5 class="card-title">All units</h5>
<div class="table-responsive">
<table class="table table-borderless table-striped">
<thead>
<tr>
2020-10-02 04:43:26 +00:00
<th></th>
2020-10-01 13:09:40 +00:00
<th>Name</th>
<th>Mode</th>
<th>Concurrency</th>
<th>Attempts</th>
<th>Interval</th>
<th>Timeout</th>
<th>Max request size</th>
<th>Working directory</th>
</tr>
</thead>
<tbody>
{{range .Units}}
<tr>
2020-10-02 04:43:26 +00:00
<td title="secured">
{{if .Secured}}🛡️{{end}}
</td>
2020-10-01 13:09:40 +00:00
<td>
2020-10-02 04:43:26 +00:00
<a href="{{.Name}}/">{{.Name}}</a>
2020-10-01 13:09:40 +00:00
</td>
<td>
<span class="unit-mode unit-mode-{{.Mode}}">{{.Mode}}</span>
</td>
<td>
<span class="unit-mode unit-mode-workers">{{.Workers}}</span>
</td>
<td>
{{.Attempts}}
</td>
<td>
<span class="unit-mode unit-mode-interval">{{.Interval}}</span>
</td>
<td>
{{with .Timeout}}
{{.}}
{{else}}
{{end}}
</td>
<td>
{{with .MaxRequest}}
{{.}}
{{else}}
{{end}}
</td>
<td>
{{with .WorkDir}}
<details>
<summary>static</summary>
<p>{{.}}</p>
</details>
{{else}}
<i>dynamic</i>
{{end}}
</td>
</tr>
{{end}}
</tbody>
</table>
</div>
</div>
</div>
</div>
</div>
</div>
<link rel="stylesheet" href="{{.Rel "/static" "css" "bootstrap-material-design.min.css"}}">
2020-09-28 13:46:37 +00:00
</body>
</html>