summaryrefslogtreecommitdiff
path: root/deps/rabbitmq_management/priv/www/js/tmpl/msg-detail-publishes.ejs
blob: 4ea959ac52a71708b338ee250e6f6effaebb4b1e (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
<h3><%= label %></h3>
<% if (object && object.length > 0) { %>
<%
     var col_confirm = mode != 'exchange-outgoing';
%>
<table class="list">
  <tr>
<% if (mode == 'channel') { %>
    <th>Exchange</th>
<% } else if (mode == 'exchange-incoming') { %>
    <th>Channel</th>
<% } else if (mode == 'exchange-outgoing') { %>
    <th>Queue</th>
<% } else { %>
    <th>Exchange</th>
<% } %>
    <th>publish</th>
<% if (col_confirm) { %>
    <th>confirm</th>
<% } %>
  </tr>
<%
     for (var i = 0; i < object.length; i++) {
       var pub = object[i];
%>
    <tr<%= alt_rows(i)%>>

<% if (mode == 'channel') { %>
      <td><%= link_exchange(pub.exchange.vhost, pub.exchange.name) %></td>
<% } else if (mode == 'exchange-incoming') { %>
      <td><%= link_channel(pub.channel_details.name) %></td>
<% } else if (mode == 'exchange-outgoing') { %>
      <td><%= link_queue(pub.queue.vhost, pub.queue.name) %></td>
<% } else { %>
      <td><%= link_exchange(pub.exchange.vhost, pub.exchange.name) %></td>
<% } %>
      <td class="r"><%= fmt_detail_rate(pub.stats, 'publish') %></td>
<% if (col_confirm) { %>
      <td class="r"><%= fmt_detail_rate(pub.stats, 'confirm') %></td>
<% } %>
    </tr>
<% } %>
</table>
<% } else { %>
<p> ... no publishes ...</p>
<% } %>