${_("Summary Status ")}
<%
removeLink = ''
redoLink = ''
verifyLink = ''
updateLink = ''
for (action, link) in tsum.action_links:
if action == 'remove':
removeLink = link + "?disable_auto_summary=1"
redoLink = link
verifyLink = link + "/verify?force_restart=1"
elif action == 'reschedule':
updateLink = link
try:
summary_size = "%.2f" % (float(tsum.size)/(1024*1024))
timeDeltaDays = int(int(tsum.time_range)/86400)
if timeDeltaDays in [365, 366]:
timeDeltaString = _('1 year')
elif timeDeltaDays in [28, 29, 30, 31]:
timeDeltaString = _('1 month')
elif timeDeltaDays in [89, 90, 91, 92]:
timeDeltaString = _('3 months')
elif timeDeltaDays == 7:
timeDeltaString = _('1 week')
elif timeDeltaDays == 1:
timeDeltaString = _('1 day')
elif timeDeltaDays == 0:
timeDeltaString = _('All Time')
else:
timeDeltaString = _('%s days') % i18n.format_number(timeDeltaDays)
total_buckets = tsum.buckets
verification_time = util.timeToAgoStr(int(tsum.verification_time)) if tsum.verification_time else None
mod_time = util.timeToAgoStr(int(tsum.mod_time))
access_time = util.timeToAgoStr(int(tsum.access_time))
access_count = prettyInt(int(tsum.access_count))
total_buckets = tsum.buckets
except TypeError:
summary_size = None
timeDeltaString = None
access_time = None
verification_time = None
mod_time = None
access_count = None
total_buckets = None
complete = int(float(tsum.complete)*100)
completeString = _('Complete')
if mod_time:
completeString += "
" + _('Updated: ') + mod_time + ""
complete = int(float(tsum.complete)*100)
completeString = 'N/A'
if isNotEnoughData:
completeString = 'Not enough data to summarize.'
elif tsum.is_suspended:
completeString = 'Suspended.'
elif complete < 100:
completeString = "
Building summary - " + str(complete) + "%
"
elif complete == 100:
completeString = "Complete"
if mod_time:
completeString += "
Updated: " + mod_time + ""
%>
${get_summarization_status(tsum) | n}
% if tsum.verification_state and tsum.verification_state == 'VERIFYING':
${_("Verifying")}
${tsum.verification_progress if tsum.verification_progress else '0%'} ${_("complete")}
% else:
% if tsum.verification_state == "DONE":
<%
isVerificationSuccess = 1 if tsum.verification_buckets_failed == '0' else 0
verificationResult = tsum.verification_buckets_failed + _(" buckets failed (") + tsum.verification_buckets_passed + _(" passed, ") + tsum.verification_buckets_skipped + _(" skipped)") if tsum.verification_buckets_failed and tsum.verification_buckets_passed else _('There was an error retrieving the verification details for this summary.')
%>
% if not isVerificationSuccess:
${_("Failed to verify ")}${verification_time}
% else:
% endif
% elif tsum.verification_state == "PROCESS_ERROR":
<%
isVerificationSuccess = 0
%>
${_("Failed to verify")} ${verification_time}
% endif
% endif
% if verifyLink != '' and updateLink != '' and redoLink != '' and removeLink != '':