Changeset 2388 for pykota/trunk/pykota/storages/ldapstorage.py
- Timestamp:
- 07/27/05 15:17:28 (19 years ago)
- Files:
-
- 1 modified
Legend:
- Unmodified
- Added
- Removed
-
pykota/trunk/pykota/storages/ldapstorage.py
r2386 r2388 1420 1420 """Returns the list of all billing codes which match a certain pattern.""" 1421 1421 codes = [] 1422 result = self.doSearch("(&(objectClass=pykotaBilling) %s)" % "".join(["(pykotaBillingCode=%s)" % self.userCharsetToDatabase(bcode) for bcode in billingcodepattern.split(",")]), \1422 result = self.doSearch("(&(objectClass=pykotaBilling)(|%s))" % "".join(["(pykotaBillingCode=%s)" % self.userCharsetToDatabase(bcode) for bcode in billingcodepattern.split(",")]), \ 1423 1423 ["pykotaBillingCode", "description", "pykotaPageCounter", "pykotaBalance"], \ 1424 1424 base=self.info["billingcodebase"]) … … 1437 1437 return codes 1438 1438 1439 def setBillingCodeValues(self, code, new balance, newpagecounter) :1439 def setBillingCodeValues(self, code, newpagecounter, newbalance) : 1440 1440 """Sets the new page counter and balance for a billing code.""" 1441 1441 fields = { … … 1445 1445 return self.doModify(code.ident, fields) 1446 1446 1447 def consumeBillingCode(self, code, balance, pagecounter) :1447 def consumeBillingCode(self, code, pagecounter, balance) : 1448 1448 """Consumes from a billing code.""" 1449 1449 fields = {