projects
/
freeside.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
9e9708b
)
support display of negative time
author
jeff
<jeff>
Thu, 6 Dec 2007 16:51:47 +0000
(16:51 +0000)
committer
jeff
<jeff>
Thu, 6 Dec 2007 16:51:47 +0000
(16:51 +0000)
httemplate/view/svc_acct.cgi
patch
|
blob
|
history
diff --git
a/httemplate/view/svc_acct.cgi
b/httemplate/view/svc_acct.cgi
index
971c6a4
..
8326818
100755
(executable)
--- a/
httemplate/view/svc_acct.cgi
+++ b/
httemplate/view/svc_acct.cgi
@@
-253,8
+253,9
@@
Service #<B><% $svcnum %></B>
% foreach my $uf ( keys %ulabel ) {
% my $tf = $uf . "_threshold";
% if ( $svc_acct->$uf ne '' ) {
% foreach my $uf ( keys %ulabel ) {
% my $tf = $uf . "_threshold";
% if ( $svc_acct->$uf ne '' ) {
-% my $v = $uf eq 'seconds' ? duration_exact($svc_acct->$uf)
-% : FS::UI::bytecount::display_bytecount($svc_acct->$uf);
+% my $v = $uf eq 'seconds'
+% ? (($svc_acct->$uf < 0 ? '-' : ''). duration_exact($svc_acct->$uf) )
+% : FS::UI::bytecount::display_bytecount($svc_acct->$uf);
<TR>
<TD ALIGN="right"><% $ulabel{$uf} %> remaining</TD>
<TD BGCOLOR="#ffffff"><% $v %></TD>
<TR>
<TD ALIGN="right"><% $ulabel{$uf} %> remaining</TD>
<TD BGCOLOR="#ffffff"><% $v %></TD>