<%! from baruwa.lib.filters import totals from baruwa.lib.cluster import host_status %>

${_("Todays stats")}

${_("Processed")} ${c.baruwa_totals.total|totals}
${_("Clean")} ${c.baruwa_totals.clean|totals}
${_("High scoring spam")} ${c.baruwa_totals.highspam|totals}
${_("Low scoring spam")} ${c.baruwa_totals.lowspam|totals}
${_("Virus infected")} ${c.baruwa_totals.virii|totals}
${_("Policy blocked")} ${c.baruwa_totals.infected|totals}
${_("Inbound queues")} ${h.link_to(c.baruwa_inbound, url('mailq-status-directed', queue='inbound'))}
${_("Outbound queues")} ${h.link_to(c.baruwa_outbound, url('mailq-status-directed', queue='outbound'))}

${_('Graph')}

% if c.baruwa_totals.total: % else: ${_('Not enough data available to generate graph.')} % endif
% if c.user.is_superadmin:

${_('Scanner node status')}

% if not c.servers:
${_('No active scanning nodes found')}
% endif: % for server in c.servers:
${h.literal('') if host_status(server.hostname) else h.literal('')} ${h.link_to(server.hostname, url('server-status', serverid=server.id))}
% endfor
% endif
<%def name="title()">\ ${_('Status :: Global status')} <%def name="heading()">\ ${_('Status :: Global status')} <%def name="headers()">\ <%def name="submenu()"> <%def name="localscripts()">\ ${h.javascript_link(h.media_url() + 'js/vendor/jquery.flot.min.js', h.media_url() + 'js/vendor/jquery.flot.pie.min.js', h.media_url() + 'js/vendor/jquery.flot.resize.min.js', h.media_url() + 'js/baruwa/status.min.js')} <%inherit file="../base.html"/>