Changeset 2735 for pykota/trunk/pykota/storages/ldapstorage.py
- Timestamp:
- 02/21/06 16:43:18 (18 years ago)
- Files:
-
- 1 modified
Legend:
- Unmodified
- Added
- Removed
-
pykota/trunk/pykota/storages/ldapstorage.py
r2726 r2735 1114 1114 return self.doModify(userpquota.ident, fields) 1115 1115 1116 def writeUserPQuotaPagesCounters(self, userpquota, newpagecounter, newlifepagecounter) :1117 """Sets the new page counters permanently for a user print quota."""1118 fields = {1119 "pykotaPageCounter" : str(newpagecounter),1120 "pykotaLifePageCounter" : str(newlifepagecounter),1121 "pykotaDateLimit" : None,1122 "pykotaWarnCount" : "0",1123 }1124 return self.doModify(userpquota.ident, fields)1125 1126 1116 def decreaseUserAccountBalance(self, user, amount) : 1127 1117 """Decreases user's account balance from an amount.""" … … 1208 1198 self.doAdd(lastjdn, fields) 1209 1199 1210 def writeUserPQuotaLimits(self, userpquota, softlimit, hardlimit) :1211 """S ets soft and hard limits for a user quota."""1200 def saveUserPQuota(self, userpquota) : 1201 """Saves an user print quota entry.""" 1212 1202 fields = { 1213 "pykotaSoftLimit" : str(softlimit), 1214 "pykotaHardLimit" : str(hardlimit), 1215 "pykotaDateLimit" : "None", 1216 "pykotaWarnCount" : "0", 1203 "pykotaSoftLimit" : str(userpquota.SoftLimit), 1204 "pykotaHardLimit" : str(userpquota.HardLimit), 1205 "pykotaDateLimit" : str(userpquota.DateLimit), 1206 "pykotaWarnCount" : str(userpquota.WarnCount), 1207 "pykotaPageCounter" : str(userpquota.PageCounter), 1208 "pykotaLifePageCounter" : str(userpquota.LifePageCounter), 1217 1209 } 1218 1210 self.doModify(userpquota.ident, fields) … … 1232 1224 return self.doModify(userpquota.ident, fields) 1233 1225 1234 def writeGroupPQuotaLimits(self, grouppquota, softlimit, hardlimit) :1235 """S ets soft and hard limits for a group quota on a specific printer."""1226 def saveGroupPQuota(self, grouppquota) : 1227 """Saves a group print quota entry.""" 1236 1228 fields = { 1237 "pykotaSoftLimit" : str( softlimit),1238 "pykotaHardLimit" : str( hardlimit),1239 "pykotaDateLimit" : "None",1229 "pykotaSoftLimit" : str(grouppquota.SoftLimit), 1230 "pykotaHardLimit" : str(grouppquota.HardLimit), 1231 "pykotaDateLimit" : str(grouppquota.DateLimit), 1240 1232 } 1241 1233 self.doModify(grouppquota.ident, fields)