summaryrefslogtreecommitdiffstats
path: root/templates/admin/monitor.tmpl
blob: f11d071ea433cabf280f9c87a786bf4ec8dc2383 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
{{template "base/head" .}}
<div class="page-content admin monitor">
	{{template "admin/navbar" .}}
	<div class="ui container">
		{{template "base/alert" .}}
		{{template "admin/cron" .}}
		<h4 class="ui top attached header">
			{{.locale.Tr "admin.monitor.queues"}}
		</h4>
		<div class="ui attached table segment">
			<table class="ui very basic striped table unstackable">
				<thead>
					<tr>
						<th>{{.locale.Tr "admin.monitor.queue.name"}}</th>
						<th>{{.locale.Tr "admin.monitor.queue.type"}}</th>
						<th>{{.locale.Tr "admin.monitor.queue.exemplar"}}</th>
						<th>{{.locale.Tr "admin.monitor.queue.numberworkers"}}</th>
						<th>{{.locale.Tr "admin.monitor.queue.numberinqueue"}}</th>
						<th></th>
					</tr>
				</thead>
				<tbody>
					{{range .Queues}}
						<tr>
							<td>{{.Name}}</td>
							<td>{{.Type}}</td>
							<td>{{.ExemplarType}}</td>
							<td>{{$sum := .NumberOfWorkers}}{{if lt $sum 0}}-{{else}}{{$sum}}{{end}}</td>
							<td>{{$sum := .NumberInQueue}}{{if lt $sum 0}}-{{else}}{{$sum}}{{end}}</td>
							<td><a href="{{$.Link}}/queue/{{.QID}}" class="button">{{if lt $sum 0}}{{$.locale.Tr "admin.monitor.queue.review"}}{{else}}{{$.locale.Tr "admin.monitor.queue.review_add"}}{{end}}</a>
						</tr>
					{{end}}
				</tbody>
			</table>
		</div>

		{{template "admin/process" .}}
	</div>
</div>
<div class="ui small basic delete modal">
	<div class="ui icon header">
		{{svg "octicon-x" 16 "close inside"}}
		{{.locale.Tr "admin.monitor.process.cancel"}}
	</div>
	<div class="content">
		<p>{{$.locale.Tr "admin.monitor.process.cancel_notices" `<span class="name"></span>` | Safe}}</p>
		<p>{{$.locale.Tr "admin.monitor.process.cancel_desc"}}</p>
	</div>
	{{template "base/delete_modal_actions" .}}
</div>
{{template "base/footer" .}}