Show
Ignore:
Timestamp:
10/05/08 11:21:53 (15 years ago)
Author:
jerome
Message:

Changed the way informations are output, especially to replace 'print'
statements which won't exist anymore in Python 3.

Files:
1 modified

Legend:

Unmodified
Added
Removed
  • pykota/trunk/bin/pkrefund

    r3413 r3429  
    257257                        percent.oneMore() 
    258258                else : 
    259                     print _("Date : %s") % str(job.JobDate)[:19] 
    260                     print _("Printer : %s") % job.PrinterName 
    261                     print _("User : %s") % job.UserName 
    262                     print _("JobId : %s") % job.JobId 
    263                     print _("Title : %s") % job.JobTitle 
     259                    self.display("%s\n" % (_("Date : %s") % str(job.JobDate)[:19])) 
     260                    self.display("%s\n" % (_("Printer : %s") % job.PrinterName)) 
     261                    self.display("%s\n" % (_("User : %s") % job.UserName)) 
     262                    self.display("%s\n" % (_("JobId : %s") % job.JobId)) 
     263                    self.display("%s\n" % (_("Title : %s") % job.JobTitle)) 
    264264                    if job.JobBillingCode : 
    265                         print _("Billing code : %s") % job.JobBillingCode 
    266                     print _("Pages : %i") % job.JobSize 
    267                     print _("Credits : %.3f") % job.JobPrice 
     265                        self.display("%s\n" % (_("Billing code : %s") % job.JobBillingCode)) 
     266                    self.display("%s\n" % (_("Pages : %i") % job.JobSize)) 
     267                    self.display("%s\n" % (_("Credits : %.3f") % job.JobPrice)) 
    268268 
    269269                    while True : 
     
    292292        if outfname != "-" : 
    293293            nbusers = len(peruser) 
    294             print _("Refunded %(nbusers)i users for %(nbjobs)i jobs, %(nbpages)i pages and %(nbcredits).3f credits") \ 
    295                      % locals() 
     294            self.display("%s\n" % (_("Refunded %(nbusers)i users for %(nbjobs)i jobs, %(nbpages)i pages and %(nbcredits).3f credits") \ 
     295                     % locals())) 
    296296 
    297297if __name__ == "__main__" :