Show
Ignore:
Timestamp:
09/19/05 09:08:55 (19 years ago)
Author:
jerome
Message:

Now honors the passthrough mode for printers (although it can't be set with pkprinters for now).
The output format for pkprinters --list has changed.
Severity : can be high if thrid party tools rely on the old pkprinters' output format.

Files:
1 modified

Legend:

Unmodified
Added
Removed
  • pykota/trunk/bin/cupspykota

    r2455 r2463  
    822822        self.exportPhaseInfo("BEFORE") 
    823823         
     824        if self.Action != "DENY" :  
     825            if self.Printer.MaxJobSize and (self.softwareJobSize > self.Printer.MaxJobSize) : 
     826                # This printer was set to refuse jobs this large. 
     827                self.printInfo(_("Precomputed job size (%s pages) too large for printer %s.") % (self.softwareJobSize, self.PrinterName), "warn") 
     828                self.Action = "DENY" 
     829             
    824830        if self.Action != "DENY" : 
    825831            if self.User.LimitBy == "noprint" : 
     
    848854            if self.User.LimitBy in ('noquota', 'nochange') : 
    849855                self.logdebug("User %s is allowed to print with no limit, no need to check quota." % self.UserName) 
     856            elif self.Printer.PassThrough :     
     857                self.logdebug("Printer %s is in PassThrough mode, no need to check quota." % self.PrinterName) 
    850858            else : 
    851859                self.logdebug("Checking user %s print quota entry on printer %s" \ 
     
    920928            self.printInfo(_("Job size : %i") % self.JobSize) 
    921929             
    922             if self.User.LimitBy == "nochange" : 
     930            if (self.User.LimitBy == "nochange") or self.Printer.PassThrough : 
    923931                # no need to update the quota for the current user on this printer 
    924932                self.printInfo(_("User %s's quota on printer %s won't be modified") % (self.UserName, self.PrinterName))