From 9243a284d60fb2fdcc1284313723515086246f8a Mon Sep 17 00:00:00 2001 From: x2003bruneau Date: Thu, 12 Apr 2007 08:29:39 +0000 Subject: [PATCH] Sort requests by type cron_validations.php | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) git-svn-id: svn+ssh://murphy/home/svn/platal/trunk@1688 839d8a87-29fc-0310-9880-83ba4fa771e5 --- bin/cron/cron_validations.php | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/bin/cron/cron_validations.php b/bin/cron/cron_validations.php index 3768240..68c3c0f 100755 --- a/bin/cron/cron_validations.php +++ b/bin/cron/cron_validations.php @@ -46,7 +46,15 @@ $message = .(empty($nbold)?"":"dont $nbold depuis le dernier mail !!!\n") .(empty($nbveryold)?"":"et dont *$nbveryold* sont en retard de plus de 6h !!!") ."\n" - ."https://www.polytechnique.org/admin/validate\n"; + ."https://www.polytechnique.org/admin/validate\n\n" + ."Par catégorie :\n"; +$res = XDB::iterRow("SELECT type, count(*) + FROM x4dat.requests + GROUP BY type + ORDER BY type"); +while (list($type, $nb) = $res->next()) { + $message .= "- $type: $nb\n"; +} $message = wordwrap($message,78); $mymail->setTxtBody($message); -- 2.1.4