- Timestamp:
- 05/21/05 00:40:21 (20 years ago)
- Location:
- pykota/trunk
- Files:
-
- 37 modified
Legend:
- Unmodified
- Added
- Removed
-
pykota/trunk/bin/dumpykota
r2218 r2266 90 90 hostname Client's hostname 91 91 billingcode Job's billing code 92 start Job's date of printing 93 end Job's date of printing 92 94 93 95 Contrary to other PyKota management tools, wildcard characters are not … … 111 113 112 114 Dumps the job history for user jerome on printer HP2100 only. 115 116 $ dumpykota --data history start=200503 end=20050730234615 117 118 Dumps all jobs printed between March 1st 2005 at midnight and 119 July 30th 2005 at 23 hours 46 minutes and 15 secondes included. 113 120 114 121 This program is free software; you can redistribute it and/or modify -
pykota/trunk/cgi-bin/printquota.cgi
r2265 r2266 29 29 import cgi 30 30 import urllib 31 32 from mx import DateTime 31 33 32 34 from pykota import version … … 203 205 billingcode = None 204 206 self.report = ["<h2>%s</h2>" % _("History")] 205 history = self.storage.retrieveHistory(user, printer, datelimit, hostname, billingcode)207 history = self.storage.retrieveHistory(user, printer, hostname, billingcode, end=datelimit) 206 208 if not history : 207 209 self.report.append("<h3>%s</h3>" % _("Empty")) … … 257 259 job.JobPages)]))) 258 260 self.report.append('</table>') 261 d = DateTime.ISO.ParseDateTime(job.JobDate) 259 262 dico = { "history" : 1, 260 "datelimit" : job.JobDate,263 "datelimit" : "%04i%02i%02i %02i:%02i:%02i" % (d.year, d.month, d.day, d.hour, d.minute, d.second), 261 264 } 262 265 if user and user.Exists : -
pykota/trunk/docs/dumpykota.sgml
r2236 r2266 60 60 be ANDed together to select only certain records in the database. 61 61 For example the filter expression <literal>username=jerome</literal> 62 would only dump datas pertaining to user <literal>jerome</literal>. 62 would only dump datas pertaining to user <literal>jerome</literal> 63 while the filter expression <literal>start=2005</literal> used 64 when dumping the history would only dump jobs printed during 65 the year <literal>2005</literal>. 63 66 </para> 64 67 … … 66 69 Several keys like <literal>username</literal> are possible, but some 67 70 only apply to certain data types. Using a key which is not supported 68 for a particular data type will return an emptyresult.71 for a particular data type may return an incorrect result. 69 72 <tip><title>Tip</title> 70 73 <para> -
pykota/trunk/man/de/dumpykota.1
r2237 r2266 2 2 .TH DUMPYKOTA "1" "mai 2005" "C@LL - Conseil Internet & Logiciels Libres" "User Commands" 3 3 .SH NOM 4 dumpykota \- page de manuel de dumpykota 1.2 2_unofficial4 dumpykota \- page de manuel de dumpykota 1.23alpha4_unofficial 5 5 .SH DESCRIPTION 6 dumpykota v1.2 2_unofficial (c) 2003, 2004, 2005 C@LL \- Conseil Internet & Logiciels Libres6 dumpykota v1.23alpha4_unofficial (c) 2003, 2004, 2005 C@LL \- Conseil Internet & Logiciels Libres 7 7 .PP 8 8 Dumps PyKota database's content. … … 80 80 billingcode 81 81 Job's billing code 82 .TP 83 start 84 Job's date of printing 85 .TP 86 end 87 Job's date of printing 82 88 .IP 83 89 Contrary to other PyKota management tools, wildcard characters are not … … 101 107 .IP 102 108 Dumps the job history for user jerome on printer HP2100 only. 109 .IP 110 \f(CW$ dumpykota --data history start=200503 end=20050730234615\fR 111 .IP 112 Dumps all jobs printed between March 1st 2005 at midnight and 113 July 30th 2005 at 23 hours 46 minutes and 15 secondes included. 103 114 .PP 104 115 This program is free software; you can redistribute it and/or modify -
pykota/trunk/man/dumpykota.1
r2237 r2266 2 2 .TH DUMPYKOTA "1" "May 2005" "C@LL - Conseil Internet & Logiciels Libres" "User Commands" 3 3 .SH NAME 4 dumpykota \- manual page for dumpykota 1.2 2_unofficial4 dumpykota \- manual page for dumpykota 1.23alpha4_unofficial 5 5 .SH DESCRIPTION 6 dumpykota v1.2 2_unofficial (c) 2003, 2004, 2005 C@LL \- Conseil Internet & Logiciels Libres6 dumpykota v1.23alpha4_unofficial (c) 2003, 2004, 2005 C@LL \- Conseil Internet & Logiciels Libres 7 7 .PP 8 8 Dumps PyKota database's content. … … 80 80 billingcode 81 81 Job's billing code 82 .TP 83 start 84 Job's date of printing 85 .TP 86 end 87 Job's date of printing 82 88 .IP 83 89 Contrary to other PyKota management tools, wildcard characters are not … … 101 107 .IP 102 108 Dumps the job history for user jerome on printer HP2100 only. 109 .IP 110 \f(CW$ dumpykota --data history start=200503 end=20050730234615\fR 111 .IP 112 Dumps all jobs printed between March 1st 2005 at midnight and 113 July 30th 2005 at 23 hours 46 minutes and 15 secondes included. 103 114 .PP 104 115 This program is free software; you can redistribute it and/or modify -
pykota/trunk/man/el_GR/dumpykota.1
r2237 r2266 2 2 .TH DUMPYKOTA "1" "mai 2005" "C@LL - Conseil Internet & Logiciels Libres" "User Commands" 3 3 .SH NOM 4 dumpykota \- page de manuel de dumpykota 1.2 2_unofficial4 dumpykota \- page de manuel de dumpykota 1.23alpha4_unofficial 5 5 .SH DESCRIPTION 6 dumpykota v1.2 2_unofficial (c) 2003, 2004, 2005 C@LL \- Conseil Internet & Logiciels Libres6 dumpykota v1.23alpha4_unofficial (c) 2003, 2004, 2005 C@LL \- Conseil Internet & Logiciels Libres 7 7 .PP 8 8 Dumps PyKota database's content. … … 80 80 billingcode 81 81 Job's billing code 82 .TP 83 start 84 Job's date of printing 85 .TP 86 end 87 Job's date of printing 82 88 .IP 83 89 Contrary to other PyKota management tools, wildcard characters are not … … 101 107 .IP 102 108 Dumps the job history for user jerome on printer HP2100 only. 109 .IP 110 \f(CW$ dumpykota --data history start=200503 end=20050730234615\fR 111 .IP 112 Dumps all jobs printed between March 1st 2005 at midnight and 113 July 30th 2005 at 23 hours 46 minutes and 15 secondes included. 103 114 .PP 104 115 This program is free software; you can redistribute it and/or modify -
pykota/trunk/man/es/dumpykota.1
r2237 r2266 2 2 .TH DUMPYKOTA "1" "mai 2005" "C@LL - Conseil Internet & Logiciels Libres" "User Commands" 3 3 .SH NOM 4 dumpykota \- page de manuel de dumpykota 1.2 2_unofficial4 dumpykota \- page de manuel de dumpykota 1.23alpha4_unofficial 5 5 .SH DESCRIPTION 6 dumpykota v1.2 2_unofficial (c) 2003, 2004, 2005 C@LL \- Conseil Internet & Logiciels Libres6 dumpykota v1.23alpha4_unofficial (c) 2003, 2004, 2005 C@LL \- Conseil Internet & Logiciels Libres 7 7 .PP 8 8 Dumps PyKota database's content. … … 80 80 billingcode 81 81 Job's billing code 82 .TP 83 start 84 Job's date of printing 85 .TP 86 end 87 Job's date of printing 82 88 .IP 83 89 Contrary to other PyKota management tools, wildcard characters are not … … 101 107 .IP 102 108 Dumps the job history for user jerome on printer HP2100 only. 109 .IP 110 \f(CW$ dumpykota --data history start=200503 end=20050730234615\fR 111 .IP 112 Dumps all jobs printed between March 1st 2005 at midnight and 113 July 30th 2005 at 23 hours 46 minutes and 15 secondes included. 103 114 .PP 104 115 This program is free software; you can redistribute it and/or modify -
pykota/trunk/man/fr/dumpykota.1
r2237 r2266 2 2 .TH DUMPYKOTA "1" "mai 2005" "C@LL - Conseil Internet & Logiciels Libres" "User Commands" 3 3 .SH NOM 4 dumpykota \- page de manuel de dumpykota 1.2 2_unofficial4 dumpykota \- page de manuel de dumpykota 1.23alpha4_unofficial 5 5 .SH DESCRIPTION 6 dumpykota v1.2 2_unofficial (c) 2003, 2004, 2005 C@LL \- Conseil Internet & Logiciels Libres6 dumpykota v1.23alpha4_unofficial (c) 2003, 2004, 2005 C@LL \- Conseil Internet & Logiciels Libres 7 7 .PP 8 8 Exporte le contenu de la base de donn� de PyKota. … … 87 87 billingcode 88 88 Code de facturation du travail d'impression 89 .TP 90 start 91 Date du travail d'impression 92 .TP 93 end 94 Date du travail d'impression 89 95 .IP 90 96 Contrairement aux autres outils d'administration de PyKota, les caract�s … … 110 116 Exporte l'historique des travaux de l'utilisateur jerome sur l'imprimante 111 117 HP2100 seulement. 118 .IP 119 \f(CW$ dumpykota --data history start=200503 end=20050730234615\fR 120 .IP 121 Exporte tous les travaux imprim�entre le 1er Mars 2005 �inuit et 122 le 30 Juillet 2005 �3 heures 46 minutes et 15 secondes inclus. 112 123 .PP 113 124 This program is free software; you can redistribute it and/or modify -
pykota/trunk/man/it/dumpykota.1
r2237 r2266 2 2 .TH DUMPYKOTA "1" "mai 2005" "C@LL - Conseil Internet & Logiciels Libres" "User Commands" 3 3 .SH NOM 4 dumpykota \- page de manuel de dumpykota 1.2 2_unofficial4 dumpykota \- page de manuel de dumpykota 1.23alpha4_unofficial 5 5 .SH DESCRIPTION 6 dumpykota v1.2 2_unofficial (c) 2003, 2004, 2005 C@LL \- Conseil Internet & Logiciels Libres6 dumpykota v1.23alpha4_unofficial (c) 2003, 2004, 2005 C@LL \- Conseil Internet & Logiciels Libres 7 7 .PP 8 8 Dumps PyKota database's content. … … 80 80 billingcode 81 81 Job's billing code 82 .TP 83 start 84 Job's date of printing 85 .TP 86 end 87 Job's date of printing 82 88 .IP 83 89 Contrary to other PyKota management tools, wildcard characters are not … … 101 107 .IP 102 108 Dumps the job history for user jerome on printer HP2100 only. 109 .IP 110 \f(CW$ dumpykota --data history start=200503 end=20050730234615\fR 111 .IP 112 Dumps all jobs printed between March 1st 2005 at midnight and 113 July 30th 2005 at 23 hours 46 minutes and 15 secondes included. 103 114 .PP 104 115 This program is free software; you can redistribute it and/or modify -
pykota/trunk/man/nb_NO/dumpykota.1
r2237 r2266 2 2 .TH DUMPYKOTA "1" "mai 2005" "C@LL - Conseil Internet & Logiciels Libres" "User Commands" 3 3 .SH NOM 4 dumpykota \- page de manuel de dumpykota 1.2 2_unofficial4 dumpykota \- page de manuel de dumpykota 1.23alpha4_unofficial 5 5 .SH DESCRIPTION 6 dumpykota v1.2 2_unofficial (c) 2003, 2004, 2005 C@LL \- Conseil Internet & Logiciels Libres6 dumpykota v1.23alpha4_unofficial (c) 2003, 2004, 2005 C@LL \- Conseil Internet & Logiciels Libres 7 7 .PP 8 8 Dumps PyKota database's content. … … 80 80 billingcode 81 81 Job's billing code 82 .TP 83 start 84 Job's date of printing 85 .TP 86 end 87 Job's date of printing 82 88 .IP 83 89 Contrary to other PyKota management tools, wildcard characters are not … … 101 107 .IP 102 108 Dumps the job history for user jerome on printer HP2100 only. 109 .IP 110 \f(CW$ dumpykota --data history start=200503 end=20050730234615\fR 111 .IP 112 Dumps all jobs printed between March 1st 2005 at midnight and 113 July 30th 2005 at 23 hours 46 minutes and 15 secondes included. 103 114 .PP 104 115 This program is free software; you can redistribute it and/or modify -
pykota/trunk/man/pt_BR/dumpykota.1
r2237 r2266 2 2 .TH DUMPYKOTA "1" "mai 2005" "C@LL - Conseil Internet & Logiciels Libres" "User Commands" 3 3 .SH NOM 4 dumpykota \- page de manuel de dumpykota 1.2 2_unofficial4 dumpykota \- page de manuel de dumpykota 1.23alpha4_unofficial 5 5 .SH DESCRIPTION 6 dumpykota v1.2 2_unofficial (c) 2003, 2004, 2005 C@LL \- Conseil Internet & Logiciels Libres6 dumpykota v1.23alpha4_unofficial (c) 2003, 2004, 2005 C@LL \- Conseil Internet & Logiciels Libres 7 7 .PP 8 8 Dumps PyKota database's content. … … 80 80 billingcode 81 81 Job's billing code 82 .TP 83 start 84 Job's date of printing 85 .TP 86 end 87 Job's date of printing 82 88 .IP 83 89 Contrary to other PyKota management tools, wildcard characters are not … … 101 107 .IP 102 108 Dumps the job history for user jerome on printer HP2100 only. 109 .IP 110 \f(CW$ dumpykota --data history start=200503 end=20050730234615\fR 111 .IP 112 Dumps all jobs printed between March 1st 2005 at midnight and 113 July 30th 2005 at 23 hours 46 minutes and 15 secondes included. 103 114 .PP 104 115 This program is free software; you can redistribute it and/or modify -
pykota/trunk/man/pt/dumpykota.1
r2237 r2266 2 2 .TH DUMPYKOTA "1" "mai 2005" "C@LL - Conseil Internet & Logiciels Libres" "User Commands" 3 3 .SH NOM 4 dumpykota \- page de manuel de dumpykota 1.2 2_unofficial4 dumpykota \- page de manuel de dumpykota 1.23alpha4_unofficial 5 5 .SH DESCRIPTION 6 dumpykota v1.2 2_unofficial (c) 2003, 2004, 2005 C@LL \- Conseil Internet & Logiciels Libres6 dumpykota v1.23alpha4_unofficial (c) 2003, 2004, 2005 C@LL \- Conseil Internet & Logiciels Libres 7 7 .PP 8 8 Dumps PyKota database's content. … … 80 80 billingcode 81 81 Job's billing code 82 .TP 83 start 84 Job's date of printing 85 .TP 86 end 87 Job's date of printing 82 88 .IP 83 89 Contrary to other PyKota management tools, wildcard characters are not … … 101 107 .IP 102 108 Dumps the job history for user jerome on printer HP2100 only. 109 .IP 110 \f(CW$ dumpykota --data history start=200503 end=20050730234615\fR 111 .IP 112 Dumps all jobs printed between March 1st 2005 at midnight and 113 July 30th 2005 at 23 hours 46 minutes and 15 secondes included. 103 114 .PP 104 115 This program is free software; you can redistribute it and/or modify -
pykota/trunk/man/sv_SE/dumpykota.1
r2237 r2266 2 2 .TH DUMPYKOTA "1" "mai 2005" "C@LL - Conseil Internet & Logiciels Libres" "User Commands" 3 3 .SH NOM 4 dumpykota \- page de manuel de dumpykota 1.2 2_unofficial4 dumpykota \- page de manuel de dumpykota 1.23alpha4_unofficial 5 5 .SH DESCRIPTION 6 dumpykota v1.2 2_unofficial (c) 2003, 2004, 2005 C@LL \- Conseil Internet & Logiciels Libres6 dumpykota v1.23alpha4_unofficial (c) 2003, 2004, 2005 C@LL \- Conseil Internet & Logiciels Libres 7 7 .PP 8 8 Dumps PyKota database's content. … … 80 80 billingcode 81 81 Job's billing code 82 .TP 83 start 84 Job's date of printing 85 .TP 86 end 87 Job's date of printing 82 88 .IP 83 89 Contrary to other PyKota management tools, wildcard characters are not … … 101 107 .IP 102 108 Dumps the job history for user jerome on printer HP2100 only. 109 .IP 110 \f(CW$ dumpykota --data history start=200503 end=20050730234615\fR 111 .IP 112 Dumps all jobs printed between March 1st 2005 at midnight and 113 July 30th 2005 at 23 hours 46 minutes and 15 secondes included. 103 114 .PP 104 115 This program is free software; you can redistribute it and/or modify -
pykota/trunk/man/th/dumpykota.1
r2237 r2266 2 2 .TH DUMPYKOTA "1" "mai 2005" "C@LL - Conseil Internet & Logiciels Libres" "User Commands" 3 3 .SH NOM 4 dumpykota \- page de manuel de dumpykota 1.2 2_unofficial4 dumpykota \- page de manuel de dumpykota 1.23alpha4_unofficial 5 5 .SH DESCRIPTION 6 dumpykota v1.2 2_unofficial (c) 2003, 2004, 2005 C@LL \- Conseil Internet & Logiciels Libres6 dumpykota v1.23alpha4_unofficial (c) 2003, 2004, 2005 C@LL \- Conseil Internet & Logiciels Libres 7 7 .PP 8 8 Dumps PyKota database's content. … … 80 80 billingcode 81 81 Job's billing code 82 .TP 83 start 84 Job's date of printing 85 .TP 86 end 87 Job's date of printing 82 88 .IP 83 89 Contrary to other PyKota management tools, wildcard characters are not … … 101 107 .IP 102 108 Dumps the job history for user jerome on printer HP2100 only. 109 .IP 110 \f(CW$ dumpykota --data history start=200503 end=20050730234615\fR 111 .IP 112 Dumps all jobs printed between March 1st 2005 at midnight and 113 July 30th 2005 at 23 hours 46 minutes and 15 secondes included. 103 114 .PP 104 115 This program is free software; you can redistribute it and/or modify -
pykota/trunk/man/tr/dumpykota.1
r2237 r2266 2 2 .TH DUMPYKOTA "1" "mai 2005" "C@LL - Conseil Internet & Logiciels Libres" "User Commands" 3 3 .SH NOM 4 dumpykota \- page de manuel de dumpykota 1.2 2_unofficial4 dumpykota \- page de manuel de dumpykota 1.23alpha4_unofficial 5 5 .SH DESCRIPTION 6 dumpykota v1.2 2_unofficial (c) 2003, 2004, 2005 C@LL \- Conseil Internet & Logiciels Libres6 dumpykota v1.23alpha4_unofficial (c) 2003, 2004, 2005 C@LL \- Conseil Internet & Logiciels Libres 7 7 .PP 8 8 Dumps PyKota database's content. … … 80 80 billingcode 81 81 Job's billing code 82 .TP 83 start 84 Job's date of printing 85 .TP 86 end 87 Job's date of printing 82 88 .IP 83 89 Contrary to other PyKota management tools, wildcard characters are not … … 101 107 .IP 102 108 Dumps the job history for user jerome on printer HP2100 only. 109 .IP 110 \f(CW$ dumpykota --data history start=200503 end=20050730234615\fR 111 .IP 112 Dumps all jobs printed between March 1st 2005 at midnight and 113 July 30th 2005 at 23 hours 46 minutes and 15 secondes included. 103 114 .PP 104 115 This program is free software; you can redistribute it and/or modify -
pykota/trunk/man/zh_TW/dumpykota.1
r2237 r2266 2 2 .TH DUMPYKOTA "1" "mai 2005" "C@LL - Conseil Internet & Logiciels Libres" "User Commands" 3 3 .SH NOM 4 dumpykota \- page de manuel de dumpykota 1.2 2_unofficial4 dumpykota \- page de manuel de dumpykota 1.23alpha4_unofficial 5 5 .SH DESCRIPTION 6 dumpykota v1.2 2_unofficial (c) 2003, 2004, 2005 C@LL \- Conseil Internet & Logiciels Libres6 dumpykota v1.23alpha4_unofficial (c) 2003, 2004, 2005 C@LL \- Conseil Internet & Logiciels Libres 7 7 .PP 8 8 Dumps PyKota database's content. … … 80 80 billingcode 81 81 Job's billing code 82 .TP 83 start 84 Job's date of printing 85 .TP 86 end 87 Job's date of printing 82 88 .IP 83 89 Contrary to other PyKota management tools, wildcard characters are not … … 101 107 .IP 102 108 Dumps the job history for user jerome on printer HP2100 only. 109 .IP 110 \f(CW$ dumpykota --data history start=200503 end=20050730234615\fR 111 .IP 112 Dumps all jobs printed between March 1st 2005 at midnight and 113 July 30th 2005 at 23 hours 46 minutes and 15 secondes included. 103 114 .PP 104 115 This program is free software; you can redistribute it and/or modify -
pykota/trunk/NEWS
r2265 r2266 22 22 PyKota NEWS : 23 23 24 - 1.23alpha4 : 25 26 - The data dumper now accept start= and end= to specify the starting 27 and ending dates to dump the history. 28 24 29 - 1.23alpha3 : 25 30 -
pykota/trunk/po/de/pykota.po
r2228 r2266 244 244 " hostname Client's hostname\n" 245 245 " billingcode Job's billing code\n" 246 " start Job's date of printing\n" 247 " end Job's date of printing\n" 246 248 " \n" 247 249 " Contrary to other PyKota management tools, wildcard characters are not \n" … … 265 267 " \n" 266 268 " Dumps the job history for user jerome on printer HP2100 only.\n" 269 " \n" 270 " $ dumpykota --data history start=200503 end=20050730234615\n" 271 " \n" 272 " Dumps all jobs printed between March 1st 2005 at midnight and\n" 273 " July 30th 2005 at 23 hours 46 minutes and 15 secondes included.\n" 267 274 " \n" 268 275 "This program is free software; you can redistribute it and/or modify\n" -
pykota/trunk/po/el_GR/pykota.po
r2228 r2266 240 240 " hostname Client's hostname\n" 241 241 " billingcode Job's billing code\n" 242 " start Job's date of printing\n" 243 " end Job's date of printing\n" 242 244 " \n" 243 245 " Contrary to other PyKota management tools, wildcard characters are not \n" … … 261 263 " \n" 262 264 " Dumps the job history for user jerome on printer HP2100 only.\n" 265 " \n" 266 " $ dumpykota --data history start=200503 end=20050730234615\n" 267 " \n" 268 " Dumps all jobs printed between March 1st 2005 at midnight and\n" 269 " July 30th 2005 at 23 hours 46 minutes and 15 secondes included.\n" 263 270 " \n" 264 271 "This program is free software; you can redistribute it and/or modify\n" -
pykota/trunk/po/es/pykota.po
r2228 r2266 258 258 " hostname Client's hostname\n" 259 259 " billingcode Job's billing code\n" 260 " start Job's date of printing\n" 261 " end Job's date of printing\n" 260 262 " \n" 261 263 " Contrary to other PyKota management tools, wildcard characters are not \n" … … 279 281 " \n" 280 282 " Dumps the job history for user jerome on printer HP2100 only.\n" 283 " \n" 284 " $ dumpykota --data history start=200503 end=20050730234615\n" 285 " \n" 286 " Dumps all jobs printed between March 1st 2005 at midnight and\n" 287 " July 30th 2005 at 23 hours 46 minutes and 15 secondes included.\n" 281 288 " \n" 282 289 "This program is free software; you can redistribute it and/or modify\n" -
pykota/trunk/po/fr/pykota.po
r2228 r2266 254 254 " hostname Client's hostname\n" 255 255 " billingcode Job's billing code\n" 256 " start Job's date of printing\n" 257 " end Job's date of printing\n" 256 258 " \n" 257 259 " Contrary to other PyKota management tools, wildcard characters are not \n" … … 275 277 " \n" 276 278 " Dumps the job history for user jerome on printer HP2100 only.\n" 279 " \n" 280 " $ dumpykota --data history start=200503 end=20050730234615\n" 281 " \n" 282 " Dumps all jobs printed between March 1st 2005 at midnight and\n" 283 " July 30th 2005 at 23 hours 46 minutes and 15 secondes included.\n" 277 284 " \n" 278 285 "This program is free software; you can redistribute it and/or modify\n" … … 359 366 " hostname Nom d'h�de la machine cliente\n" 360 367 " billingcode Code de facturation du travail d'impression\n" 368 " start Date du travail d'impression\n" 369 " end Date du travail d'impression\n" 361 370 " \n" 362 371 " Contrairement aux autres outils d'administration de PyKota, les " … … 383 392 " Exporte l'historique des travaux de l'utilisateur jerome sur l'imprimante\n" 384 393 " HP2100 seulement.\n" 394 " \n" 395 " $ dumpykota --data history start=200503 end=20050730234615\n" 396 " \n" 397 " Exporte tous les travaux imprim�entre le 1er Mars 2005 �inuit et\n" 398 " le 30 Juillet 2005 �3 heures 46 minutes et 15 secondes inclus.\n" 385 399 " \n" 386 400 "This program is free software; you can redistribute it and/or modify\n" -
pykota/trunk/po/it/pykota.po
r2228 r2266 202 202 " hostname Client's hostname\n" 203 203 " billingcode Job's billing code\n" 204 " start Job's date of printing\n" 205 " end Job's date of printing\n" 204 206 " \n" 205 207 " Contrary to other PyKota management tools, wildcard characters are not \n" … … 223 225 " \n" 224 226 " Dumps the job history for user jerome on printer HP2100 only.\n" 227 " \n" 228 " $ dumpykota --data history start=200503 end=20050730234615\n" 229 " \n" 230 " Dumps all jobs printed between March 1st 2005 at midnight and\n" 231 " July 30th 2005 at 23 hours 46 minutes and 15 secondes included.\n" 225 232 " \n" 226 233 "This program is free software; you can redistribute it and/or modify\n" -
pykota/trunk/po/nb_NO/pykota.po
r2228 r2266 254 254 " hostname Client's hostname\n" 255 255 " billingcode Job's billing code\n" 256 " start Job's date of printing\n" 257 " end Job's date of printing\n" 256 258 " \n" 257 259 " Contrary to other PyKota management tools, wildcard characters are not \n" … … 275 277 " \n" 276 278 " Dumps the job history for user jerome on printer HP2100 only.\n" 279 " \n" 280 " $ dumpykota --data history start=200503 end=20050730234615\n" 281 " \n" 282 " Dumps all jobs printed between March 1st 2005 at midnight and\n" 283 " July 30th 2005 at 23 hours 46 minutes and 15 secondes included.\n" 277 284 " \n" 278 285 "This program is free software; you can redistribute it and/or modify\n" -
pykota/trunk/po/pt_BR/pykota.po
r2228 r2266 200 200 " hostname Client's hostname\n" 201 201 " billingcode Job's billing code\n" 202 " start Job's date of printing\n" 203 " end Job's date of printing\n" 202 204 " \n" 203 205 " Contrary to other PyKota management tools, wildcard characters are not \n" … … 221 223 " \n" 222 224 " Dumps the job history for user jerome on printer HP2100 only.\n" 225 " \n" 226 " $ dumpykota --data history start=200503 end=20050730234615\n" 227 " \n" 228 " Dumps all jobs printed between March 1st 2005 at midnight and\n" 229 " July 30th 2005 at 23 hours 46 minutes and 15 secondes included.\n" 223 230 " \n" 224 231 "This program is free software; you can redistribute it and/or modify\n" -
pykota/trunk/po/pt/pykota.po
r2228 r2266 200 200 " hostname Client's hostname\n" 201 201 " billingcode Job's billing code\n" 202 " start Job's date of printing\n" 203 " end Job's date of printing\n" 202 204 " \n" 203 205 " Contrary to other PyKota management tools, wildcard characters are not \n" … … 221 223 " \n" 222 224 " Dumps the job history for user jerome on printer HP2100 only.\n" 225 " \n" 226 " $ dumpykota --data history start=200503 end=20050730234615\n" 227 " \n" 228 " Dumps all jobs printed between March 1st 2005 at midnight and\n" 229 " July 30th 2005 at 23 hours 46 minutes and 15 secondes included.\n" 223 230 " \n" 224 231 "This program is free software; you can redistribute it and/or modify\n" -
pykota/trunk/po/pykota.pot
r2228 r2266 202 202 " hostname Client's hostname\n" 203 203 " billingcode Job's billing code\n" 204 " start Job's date of printing\n" 205 " end Job's date of printing\n" 204 206 " \n" 205 207 " Contrary to other PyKota management tools, wildcard characters are not \n" … … 223 225 " \n" 224 226 " Dumps the job history for user jerome on printer HP2100 only.\n" 227 " \n" 228 " $ dumpykota --data history start=200503 end=20050730234615\n" 229 " \n" 230 " Dumps all jobs printed between March 1st 2005 at midnight and\n" 231 " July 30th 2005 at 23 hours 46 minutes and 15 secondes included.\n" 225 232 " \n" 226 233 "This program is free software; you can redistribute it and/or modify\n" -
pykota/trunk/po/sv_SE/pykota.po
r2228 r2266 203 203 " hostname Client's hostname\n" 204 204 " billingcode Job's billing code\n" 205 " start Job's date of printing\n" 206 " end Job's date of printing\n" 205 207 " \n" 206 208 " Contrary to other PyKota management tools, wildcard characters are not \n" … … 224 226 " \n" 225 227 " Dumps the job history for user jerome on printer HP2100 only.\n" 228 " \n" 229 " $ dumpykota --data history start=200503 end=20050730234615\n" 230 " \n" 231 " Dumps all jobs printed between March 1st 2005 at midnight and\n" 232 " July 30th 2005 at 23 hours 46 minutes and 15 secondes included.\n" 226 233 " \n" 227 234 "This program is free software; you can redistribute it and/or modify\n" -
pykota/trunk/po/th/pykota.po
r2228 r2266 201 201 " hostname Client's hostname\n" 202 202 " billingcode Job's billing code\n" 203 " start Job's date of printing\n" 204 " end Job's date of printing\n" 203 205 " \n" 204 206 " Contrary to other PyKota management tools, wildcard characters are not \n" … … 222 224 " \n" 223 225 " Dumps the job history for user jerome on printer HP2100 only.\n" 226 " \n" 227 " $ dumpykota --data history start=200503 end=20050730234615\n" 228 " \n" 229 " Dumps all jobs printed between March 1st 2005 at midnight and\n" 230 " July 30th 2005 at 23 hours 46 minutes and 15 secondes included.\n" 224 231 " \n" 225 232 "This program is free software; you can redistribute it and/or modify\n" -
pykota/trunk/po/tr/pykota.po
r2228 r2266 247 247 " hostname Client's hostname\n" 248 248 " billingcode Job's billing code\n" 249 " start Job's date of printing\n" 250 " end Job's date of printing\n" 249 251 " \n" 250 252 " Contrary to other PyKota management tools, wildcard characters are not \n" … … 268 270 " \n" 269 271 " Dumps the job history for user jerome on printer HP2100 only.\n" 272 " \n" 273 " $ dumpykota --data history start=200503 end=20050730234615\n" 274 " \n" 275 " Dumps all jobs printed between March 1st 2005 at midnight and\n" 276 " July 30th 2005 at 23 hours 46 minutes and 15 secondes included.\n" 270 277 " \n" 271 278 "This program is free software; you can redistribute it and/or modify\n" -
pykota/trunk/po/zh_TW/pykota.po
r2226 r2266 203 203 " hostname Client's hostname\n" 204 204 " billingcode Job's billing code\n" 205 " start Job's date of printing\n" 206 " end Job's date of printing\n" 205 207 " \n" 206 208 " Contrary to other PyKota management tools, wildcard characters are not \n" … … 224 226 " \n" 225 227 " Dumps the job history for user jerome on printer HP2100 only.\n" 228 " \n" 229 " $ dumpykota --data history start=200503 end=20050730234615\n" 230 " \n" 231 " Dumps all jobs printed between March 1st 2005 at midnight and\n" 232 " July 30th 2005 at 23 hours 46 minutes and 15 secondes included.\n" 226 233 " \n" 227 234 "This program is free software; you can redistribute it and/or modify\n" -
pykota/trunk/pykota/dumper.py
r2264 r2266 65 65 "hostname", 66 66 "billingcode", 67 "start", 68 "end", 67 69 ] 68 70 def main(self, arguments, options, restricted=1) : -
pykota/trunk/pykota/storage.py
r2217 r2266 23 23 # 24 24 25 from mx import DateTime 26 25 27 class PyKotaStorageError(Exception): 26 28 """An exception for Quota Storage related stuff.""" … … 588 590 return text 589 591 592 def cleanDates(self, startdate, enddate) : 593 """Clean the dates to create a correct filter.""" 594 if startdate is None : 595 startdate = enddate 596 if enddate is None : 597 enddate = startdate 598 if (startdate is None) and (enddate is None) : 599 return (None, None) 600 if startdate.isdigit() and enddate.isdigit() : 601 datedict = { "start" : startdate, "end" : enddate } 602 for limit in datedict.keys() : 603 dateval = datedict[limit] 604 lgdateval = len(dateval) 605 if lgdateval == 4 : 606 if limit == "start" : 607 dateval = "%s0101 00:00:00" % dateval 608 else : 609 dateval = "%s1231 23:59:59" % dateval 610 elif lgdateval == 6 : 611 if limit == "start" : 612 dateval = "%s01 00:00:00" % dateval 613 else : 614 mxdate = DateTime.ISO.ParseDateTime("%s01 00:00:00" % dateval) 615 dateval = "%s%02i 23:59:59" % (dateval, mxdate.days_in_month) 616 elif lgdateval == 8 : 617 if limit == "start" : 618 dateval = "%s 00:00:00" % dateval 619 else : 620 dateval = "%s 23:59:59" % dateval 621 elif lgdateval == 10 : 622 if limit == "start" : 623 dateval = "%s %s:00:00" % (dateval[:8], dateval[8:]) 624 else : 625 dateval = "%s %s:59:59" % (dateval[:8], dateval[8:]) 626 elif lgdateval == 12 : 627 if limit == "start" : 628 dateval = "%s %s:%s:00" % (dateval[:8], dateval[8:10], dateval[10:]) 629 else : 630 dateval = "%s %s:%s:59" % (dateval[:8], dateval[8:10], dateval[10:]) 631 elif lgdateval == 14 : 632 dateval = "%s %s:%s:%s" % (dateval[:8], dateval[8:10], dateval[10:12], dateval[12:]) 633 else : 634 dateval = None 635 try : 636 DateTime.ISO.ParseDateTime(dateval) 637 except : 638 dateval = None 639 datedict[limit] = dateval 640 (start, end) = (datedict["start"], datedict["end"]) 641 if start > end : 642 (start, end) = (end, start) 643 return (start, end) 644 else : 645 return (None, None) 646 590 647 def openConnection(pykotatool) : 591 648 """Returns a connection handle to the appropriate Quota Storage Database.""" -
pykota/trunk/pykota/storages/ldapstorage.py
r2222 r2266 1044 1044 self.doModify(pgroup.ident, fields) 1045 1045 1046 def retrieveHistory(self, user=None, printer=None, datelimit=None, hostname=None, billingcode=None, limit=100) :1047 """Retrieves all print jobs for user on printer (or all) be foredate, limited to first 100 results."""1046 def retrieveHistory(self, user=None, printer=None, hostname=None, billingcode=None, limit=100, start=None, end=None) : 1047 """Retrieves all print jobs for user on printer (or all) between start and end date, limited to first 100 results.""" 1048 1048 precond = "(objectClass=pykotaJob)" 1049 1049 where = [] … … 1110 1110 minute = int(date[10:12]) 1111 1111 second = int(date[12:14]) 1112 job.JobDate = "%04i-%02i-%02i %02i:%02i:%02i" % (year, month, day, hour, minute, second) 1113 if (datelimit is None) or (job.JobDate <= datelimit) : 1112 job.JobDate = "%04i%02i%02i %02i:%02i:%02i" % (year, month, day, hour, minute, second) 1113 if ((start is None) and (end is None)) or \ 1114 ((start is None) and (job.JobDate <= end)) or \ 1115 ((end is None) and (job.JobDate >= start)) or \ 1116 ((job.JobDate >= start) and (job.JobDate <= end)) : 1114 1117 job.UserName = fields.get("pykotaUserName")[0] 1115 1118 job.PrinterName = fields.get("pykotaPrinterName")[0] … … 1335 1338 else : 1336 1339 printer = None 1337 entries = self.retrieveHistory(user, printer, hostname=extractonly.get("hostname"), billingcode=extractonly.get("billingcode"), limit=None) 1340 startdate = extractonly.get("start") 1341 enddate = extractonly.get("end") 1342 for limit in ("start", "end") : 1343 try : 1344 del extractonly[limit] 1345 except KeyError : 1346 pass 1347 (startdate, enddate) = self.cleanDates(startdate, enddate) 1348 entries = self.retrieveHistory(user, printer, hostname=extractonly.get("hostname"), billingcode=extractonly.get("billingcode"), limit=None, start=startdate, end=enddate) 1338 1349 if entries : 1339 1350 result = [ ("username", "printername", "dn", "jobid", "pagecounter", "jobsize", "action", "jobdate", "filename", "title", "copies", "options", "jobprice", "hostname", "jobsizebytes", "md5sum", "pages", "billingcode") ] -
pykota/trunk/pykota/storages/sql.py
r2222 r2266 124 124 def extractHistory(self, extractonly={}) : 125 125 """Extracts all jobhistory records.""" 126 startdate = extractonly.get("start") 127 enddate = extractonly.get("end") 128 for limit in ("start", "end") : 129 try : 130 del extractonly[limit] 131 except KeyError : 132 pass 126 133 thefilter = self.createFilter(extractonly) 127 134 if thefilter : 128 135 thefilter = "AND %s" % thefilter 136 (startdate, enddate) = self.cleanDates(startdate, enddate) 137 if startdate and enddate : 138 thefilter = "%s AND jobdate>=%s AND jobdate<=%s" % (thefilter, self.doQuote(startdate), self.doQuote(enddate)) 129 139 result = self.doRawSearch("SELECT users.username,printers.printername,jobhistory.* FROM users,printers,jobhistory WHERE users.id=jobhistory.userid AND printers.id=jobhistory.printerid %s ORDER BY jobhistory.id ASC" % thefilter) 130 140 return self.prepareRawResult(result) 131 141 132 142 def getAllUsersNames(self) : 133 143 """Extracts all user names.""" … … 498 508 self.doModify("DELETE FROM printergroupsmembers WHERE groupid=%s AND printerid=%s" % (self.doQuote(pgroup.ident), self.doQuote(printer.ident))) 499 509 500 def retrieveHistory(self, user=None, printer=None, datelimit=None, hostname=None, billingcode=None, limit=100) :501 """Retrieves all print jobs for user on printer (or all) be foredate, limited to first 100 results."""510 def retrieveHistory(self, user=None, printer=None, hostname=None, billingcode=None, limit=100, start=None, end=None) : 511 """Retrieves all print jobs for user on printer (or all) between start and end date, limited to first 100 results.""" 502 512 query = "SELECT jobhistory.*,username,printername FROM jobhistory,users,printers WHERE users.id=userid AND printers.id=printerid" 503 513 where = [] … … 510 520 if billingcode is not None : 511 521 where.append("billingcode=%s" % self.doQuote(self.userCharsetToDatabase(billingcode))) 512 if datelimit is not None : 513 where.append("jobdate<=%s" % self.doQuote(datelimit)) 522 if start is not None : 523 where.append("jobdate>=%s" % self.doQuote(start)) 524 if end is not None : 525 where.append("jobdate<=%s" % self.doQuote(end)) 514 526 if where : 515 527 query += " AND %s" % " AND ".join(where) -
pykota/trunk/pykota/version.py
r2262 r2266 22 22 # 23 23 24 __version__ = "1.23alpha 3_unofficial"24 __version__ = "1.23alpha4_unofficial" 25 25 26 26 __doc__ = """PyKota : a complete Printing Quota Solution for CUPS and LPRng.""" -
pykota/trunk/TODO
r2264 r2266 26 26 Winboxes it seems) 27 27 28 - Add date filtering options to dumpykota, something like29 date=+20050101 date=-2005020130 to dump all jobs printed between January 1st 2005 included31 and February 1st 2005 not included. This looks ugly but32 at least we avoid the problematic '<' and '>' on command33 lines, which would mandate the use of quotes...34 35 28 - Pass-through mode for printers : history correctly filled (including 36 29 job size) but no impact on user's page counter or account