503 | | banner = self.startingBanner(printer.Name) |
504 | | if banner : |
505 | | self.logdebug("Printing starting banner before accounting begins.") |
506 | | self.handleData(banner) |
| 510 | if (action == 'DENY') and (userpquota.WarnCount < self.config.getMaxDenyBanners()) : |
| 511 | self.printInfo(_("Banner won't be printed : maximum number of deny banners reached."), "warn") |
| 512 | else : |
| 513 | if action == 'DENY' : |
| 514 | userpquota.warn() # increments the warning counter |
| 515 | self.exportUserInfo(userpquota) |
| 516 | banner = self.startingBanner(printer.Name) |
| 517 | if banner : |
| 518 | self.logdebug("Printing starting banner before accounting begins.") |
| 519 | self.handleData(banner) |
513 | | banner = self.startingBanner(printer.Name) |
514 | | if banner : |
515 | | self.logdebug("Printing starting banner during accounting.") |
516 | | self.handleData(banner) |
517 | | if self.accounter.isSoftware : |
518 | | bannersize += 1 # TODO : fix this by passing the banner's content through PDLAnalyzer |
| 526 | if (action == 'DENY') and (userpquota.WarnCount < self.config.getMaxDenyBanners()) : |
| 527 | self.printInfo(_("Banner won't be printed : maximum number of deny banners reached."), "warn") |
| 528 | else : |
| 529 | if action == 'DENY' : |
| 530 | userpquota.warn() # increments the warning counter |
| 531 | self.exportUserInfo(userpquota) |
| 532 | banner = self.startingBanner(printer.Name) |
| 533 | if banner : |
| 534 | self.logdebug("Printing starting banner during accounting.") |
| 535 | self.handleData(banner) |
| 536 | if self.accounter.isSoftware : |
| 537 | bannersize += 1 # TODO : fix this by passing the banner's content through PDLAnalyzer |
538 | | banner = self.endingBanner(printer.Name) |
539 | | if banner : |
540 | | self.logdebug("Printing ending banner during accounting.") |
541 | | self.handleData(banner) |
542 | | if self.accounter.isSoftware : |
543 | | bannersize += 1 # TODO : fix this by passing the banner's content through PDLAnalyzer |
| 557 | if (action == 'DENY') and (userpquota.WarnCount < self.config.getMaxDenyBanners()) : |
| 558 | self.printInfo(_("Banner won't be printed : maximum number of deny banners reached."), "warn") |
| 559 | else : |
| 560 | if action == 'DENY' : |
| 561 | userpquota.warn() # increments the warning counter |
| 562 | self.exportUserInfo(userpquota) |
| 563 | banner = self.endingBanner(printer.Name) |
| 564 | if banner : |
| 565 | self.logdebug("Printing ending banner during accounting.") |
| 566 | self.handleData(banner) |
| 567 | if self.accounter.isSoftware : |
| 568 | bannersize += 1 # TODO : fix this by passing the banner's content through PDLAnalyzer |
577 | | banner = self.endingBanner(printer.Name) |
578 | | if banner : |
579 | | self.logdebug("Printing ending banner after accounting ends.") |
580 | | self.handleData(banner) |
581 | | |
| 602 | if (action == 'DENY') and (userpquota.WarnCount < self.config.getMaxDenyBanners()) : |
| 603 | self.printInfo(_("Banner won't be printed : maximum number of deny banners reached."), "warn") |
| 604 | else : |
| 605 | if action == 'DENY' : |
| 606 | userpquota.warn() # increments the warning counter |
| 607 | self.exportUserInfo(userpquota) |
| 608 | banner = self.endingBanner(printer.Name) |
| 609 | if banner : |
| 610 | self.logdebug("Printing ending banner after accounting ends.") |
| 611 | self.handleData(banner) |
| 612 | |