summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorivan <ivan>2008-11-03 01:10:25 +0000
committerivan <ivan>2008-11-03 01:10:25 +0000
commit378fc3c26eff1e53422284cb49fb21b3cd9c3e33 (patch)
tree782b74aa51f536937576c6690906291994160195
parentaf0bf34fadc9bb398e54560657dce51987c975a9 (diff)
time remaining is more useful to display as hours + minutes than days, hours, minutes from Time::Duration
-rwxr-xr-xhttemplate/view/svc_acct.cgi5
1 files changed, 4 insertions, 1 deletions
diff --git a/httemplate/view/svc_acct.cgi b/httemplate/view/svc_acct.cgi
index e6d2b690f..ec22bd0bc 100755
--- a/httemplate/view/svc_acct.cgi
+++ b/httemplate/view/svc_acct.cgi
@@ -260,7 +260,10 @@ Service #<B><% $svcnum %></B>
% my $tf = $uf . "_threshold";
% if ( $svc_acct->$uf ne '' ) {
% my $v = $uf eq 'seconds'
-% ? (($svc_acct->$uf < 0 ? '-' : ''). duration_exact($svc_acct->$uf) )
+% #? (($svc_acct->$uf < 0 ? '-' : ''). duration_exact($svc_acct->$uf) )
+% ? ($svc_acct->$uf < 0 ? '-' : '').
+% int(abs($svc_acct->$uf)/3600). "hr ".
+% sprintf("%02d",(abs($svc_acct->$uf)%3600)/60). "min"
% : FS::UI::bytecount::display_bytecount($svc_acct->$uf);
<TR>
<TD ALIGN="right"><% $ulabel{$uf} %> remaining</TD>