summaryrefslogtreecommitdiffstats
path: root/templates/admin/monitor.tmpl
blob: 1ab6b75a1e1efcc8517df4ca076a7083cbb57afa (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
{{template "admin/layout_head" (dict "ctxData" . "pageClass" "admin monitor")}}
	<div class="admin-setting-content">
		{{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 class="ui g-modal-confirm delete modal">
	<div class="header">
		{{.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/modal_actions_confirm" .}}
</div>

{{template "admin/layout_footer" .}}