[freeside-commits] freeside/httemplate/view svc_acct.cgi, 1.49.2.7, 1.49.2.8

Ivan,,, ivan at wavetail.420.am
Sun Nov 2 17:10:29 PST 2008


Update of /home/cvs/cvsroot/freeside/httemplate/view
In directory wavetail.420.am:/tmp/cvs-serv20748

Modified Files:
      Tag: FREESIDE_1_7_BRANCH
	svc_acct.cgi 
Log Message:
time remaining is more useful to display as hours + minutes than days, hours, minutes from Time::Duration

Index: svc_acct.cgi
===================================================================
RCS file: /home/cvs/cvsroot/freeside/httemplate/view/svc_acct.cgi,v
retrieving revision 1.49.2.7
retrieving revision 1.49.2.8
diff -u -d -r1.49.2.7 -r1.49.2.8
--- svc_acct.cgi	13 Jan 2008 20:46:51 -0000	1.49.2.7
+++ svc_acct.cgi	3 Nov 2008 01:10:26 -0000	1.49.2.8
@@ -260,7 +260,10 @@
 %   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>



More information about the freeside-commits mailing list