Changeset 1755
- Timestamp:
- 09/28/04 19:45:31 (20 years ago)
- Location:
- pykota/trunk
- Files:
-
- 6 modified
Legend:
- Unmodified
- Added
- Removed
-
pykota/trunk/bin/edpykota
r1584 r1755 24 24 # 25 25 # $Log$ 26 # Revision 1.77 2004/09/28 17:45:31 jalet 27 # Added the --hardreset command line option to edpykota 28 # 26 29 # Revision 1.76 2004/07/01 19:56:40 jalet 27 30 # Better dispatching of error messages … … 334 337 -n | --noquota Doesn't set a quota but only does accounting. 335 338 336 -r | --reset Resets the printed page counter for the user 337 or group to zero. The life time page counter 338 is kept unchanged. 339 -r | --reset Resets the actual page counter for the user 340 or group to zero on the specified printers. 341 The life time page counter is kept unchanged. 342 343 -R | --hardreset Resets the actual and life time page counters 344 for the user or group to zero on the specified 345 printers. 339 346 340 347 -l | --limitby l Choose if the user/group is limited in printing … … 394 401 well as every user whose name begins with 'jo'. 395 402 Their life time page counter on each printer will be kept unchanged. 403 You can also reset the life time page counters by using the 404 --hardreset | -R command line option. 396 405 397 406 $ edpykota --printer hpcolor --noquota jerome … … 622 631 if options["reset"] : 623 632 entrypquota.reset() 633 elif options["hardreset"] : 634 entrypquota.hardreset() 624 635 625 636 if balance : … … 660 671 "printer" : "*", \ 661 672 } 662 short_options = "vhdc:l:b:i:naugrp:P:S:H:G: "663 long_options = ["help", "version", "charge=", "delete", "limitby=", "balance=", "ingroups=", "noquota", "add", "users", "groups", "reset", " prototype=", "printer=", "softlimit=", "hardlimit=", "pgroups="]673 short_options = "vhdc:l:b:i:naugrp:P:S:H:G:R" 674 long_options = ["help", "version", "charge=", "delete", "limitby=", "balance=", "ingroups=", "noquota", "add", "users", "groups", "reset", "hardreset", "prototype=", "printer=", "softlimit=", "hardlimit=", "pgroups="] 664 675 665 676 # Initializes the command line tool … … 687 698 options["charge"] = options["c"] or options["charge"] 688 699 options["pgroups"] = options["G"] or options["pgroups"] 700 options["hardreset"] = options["R"] or options["hardreset"] 689 701 690 702 if options["help"] : -
pykota/trunk/docs/edpykota.sgml
r1168 r1755 16 16 <listitem> 17 17 <para> 18 Add printers ;18 Add printers (it's preferable to use the <application>pkprinters</application> command for this though) ; 19 19 </para> 20 20 </listitem> … … 52 52 <listitem> 53 53 <para> 54 Choose the way you will limit printing : either by page quota or by account balance value. 54 Choose the way you will limit printing : either by page quota or by account balance value ; 55 </para> 56 </listitem> 57 <listitem> 58 <para> 59 Reset page counters. 55 60 </para> 56 61 </listitem> … … 63 68 64 69 $Log$ 70 Revision 1.5 2004/09/28 17:45:31 jalet 71 Added the --hardreset command line option to edpykota 72 65 73 Revision 1.4 2003/10/14 20:26:53 jalet 66 74 Better documentation. -
pykota/trunk/man/edpykota.1
r1724 r1755 2 2 .TH EDPYKOTA "1" "September 2004" "C@LL - Conseil Internet & Logiciels Libres" "User Commands" 3 3 .SH NAME 4 edpykota \- manual page for edpykota 1.20alpha1 2_unofficial4 edpykota \- manual page for edpykota 1.20alpha17_unofficial 5 5 .SH DESCRIPTION 6 edpykota v1.20alpha1 2_unofficial (c) 2003-2004 C@LL - Conseil Internet & Logiciels Libres6 edpykota v1.20alpha17_unofficial (c) 2003-2004 C@LL - Conseil Internet & Logiciels Libres 7 7 A Print Quota editor for PyKota. 8 8 .PP … … 73 73 .TP 74 74 \fB\-r\fR | \fB\-\-reset\fR 75 Resets the printed page counter for the user 76 or group to zero. The life time page counter 77 is kept unchanged. 75 Resets the actual page counter for the user 76 or group to zero on the specified printers. 77 The life time page counter is kept unchanged. 78 .TP 79 \fB\-R\fR | \fB\-\-hardreset\fR 80 Resets the actual and life time page counters 81 for the user or group to zero on the specified 82 printers. 78 83 .TP 79 84 \fB\-l\fR | \fB\-\-limitby\fR l … … 137 142 well as every user whose name begins with 'jo'. 138 143 Their life time page counter on each printer will be kept unchanged. 144 You can also reset the life time page counters by using the 145 \fB\-\-hardreset\fR | \fB\-R\fR command line option. 139 146 .IP 140 147 \f(CW$ edpykota --printer hpcolor --noquota jerome\fR -
pykota/trunk/NEWS
r1751 r1755 24 24 - 1.20alpha17 : 25 25 26 - Added --hardreset command line option to edpykota. 27 26 28 - Fixed problem with accented chars in title, filename 27 29 or options and LDAP backend. -
pykota/trunk/pykota/storage.py
r1743 r1755 22 22 # 23 23 # $Log$ 24 # Revision 1.62 2004/09/28 17:45:31 jalet 25 # Added the --hardreset command line option to edpykota 26 # 24 27 # Revision 1.61 2004/09/24 21:19:48 jalet 25 28 # Did a pass of PyChecker … … 430 433 self.parent.writeUserPQuotaPagesCounters(self, 0, int(self.LifePageCounter or 0)) 431 434 self.PageCounter = 0 435 436 def hardreset(self) : 437 """Resets actual and life time page counters to 0.""" 438 self.parent.writeUserPQuotaPagesCounters(self, 0, 0) 439 self.PageCounter = self.LifePageCounter = 0 432 440 433 441 def computeJobPrice(self, jobsize) : -
pykota/trunk/TODO
r1753 r1755 25 25 history, to be able to discover duplicate print 26 26 jobs. 27 28 - Add --hardreset command line option to29 edpykota to also reset lifetime page counters to 0.30 27 31 28 - Maybe put "gracedelay" in the database.