Changeset 956 for pykota/trunk/pykota
- Timestamp:
- 04/24/03 13:53:48 (21 years ago)
- Location:
- pykota/trunk/pykota
- Files:
-
- 3 modified
Legend:
- Unmodified
- Added
- Removed
-
pykota/trunk/pykota/config.py
r952 r956 21 21 # 22 22 # $Log$ 23 # Revision 1.23 2003/04/24 11:53:48 jalet 24 # Default policy for unknown users/groups is to DENY printing instead 25 # of the previous default to ALLOW printing. This is to solve an accuracy 26 # problem. If you set the policy to ALLOW, jobs printed by in nexistant user 27 # (from PyKota's POV) will be charged to the next user who prints on the 28 # same printer. 29 # 23 30 # Revision 1.22 2003/04/23 22:13:57 jalet 24 31 # Preliminary support for LPRng added BUT STILL UNTESTED. … … 213 220 policy = self.getPrinterOption(printer, "policy").upper() 214 221 except PyKotaConfigError : 215 policy = " ALLOW"222 policy = "DENY" 216 223 if policy not in validpolicies : 217 224 raise PyKotaConfigError, _("Option policy in section %s only supports values in %s") % (printer, str(validpolicies)) -
pykota/trunk/pykota/tool.py
r955 r956 21 21 # 22 22 # $Log$ 23 # Revision 1.38 2003/04/24 11:53:48 jalet 24 # Default policy for unknown users/groups is to DENY printing instead 25 # of the previous default to ALLOW printing. This is to solve an accuracy 26 # problem. If you set the policy to ALLOW, jobs printed by in nexistant user 27 # (from PyKota's POV) will be charged to the next user who prints on the 28 # same printer. 29 # 23 30 # Revision 1.37 2003/04/24 08:08:27 jalet 24 31 # Debug message forgotten … … 352 359 balance = self.storage.getGroupBalance(groupid) 353 360 if balance is None : 354 if policy in [None, "ALLOW"]:361 if policy == "ALLOW" : 355 362 action = "POLICY_ALLOW" 356 363 else : … … 368 375 if quota is None : 369 376 # Unknown group or printer or combination 370 if policy in [None, "ALLOW"]:377 if policy == "ALLOW" : 371 378 action = "POLICY_ALLOW" 372 379 else : … … 427 434 balance = self.storage.getUserBalance(userid) 428 435 if balance is None : 429 if policy in [None, "ALLOW"]:436 if policy == "ALLOW" : 430 437 action = "POLICY_ALLOW" 431 438 else : … … 443 450 if quota is None : 444 451 # Unknown user or printer or combination 445 if policy in [None, "ALLOW"]:452 if policy == "ALLOW" : 446 453 action = "POLICY_ALLOW" 447 454 else : -
pykota/trunk/pykota/version.py
r954 r956 21 21 # 22 22 23 __version__ = "1.04pre 3-unofficial"23 __version__ = "1.04pre4-unofficial" 24 24 25 25 __doc__ = """PyKota : a complete Printing Quota Solution for CUPS and LPRng."""