diff --git a/htdocs/comm/index.php b/htdocs/comm/index.php index c9fc1359a0a..65626157d9f 100644 --- a/htdocs/comm/index.php +++ b/htdocs/comm/index.php @@ -223,7 +223,7 @@ if ( $db->query($sql) ) $var=!$var; print ""; - print "id\">".img_file()." "; + print "id\">".img_file()." "; print "id\">$obj->libelle $obj->label"; print "".strftime("%d %b %Y",$obj->da).""; print ''.$obj->sname.''; @@ -252,33 +252,41 @@ if ($socidp) { $sql .= " AND s.idp = $socidp"; } -$sql .= " ORDER BY a.datea DESC"; +$sql .= " ORDER BY a.datea ASC"; if ( $db->query($sql) ) { $num = $db->num_rows(); - - print ''; - print ''; - $var = true; - $i = 0; - - while ($i < $num ) + if ($num > 0) + { + print '
Actions à faire
'; + print ''; + $var = true; + $i = 0; + + while ($i < $num ) { $obj = $db->fetch_object($i); $var=!$var; print ""; - print ""; - print ""; + + print '"; + print ''; $i++; } - // TODO Ajouter rappel pour "il y a des contrats à mettre en service" - // TODO Ajouter rappel pour "il y a des contrats qui arrivent à expiration" - print "
Actions à faire
id\">".img_file()." "; + print "id\">".img_file()." "; print "id\">$obj->libelle $obj->label".strftime("%d %b %Y",$obj->da)."'. strftime("%d %b %Y",$obj->da); + if (date("U",$obj->da) < time()) + { + print img_warning(); + } + print "'.$obj->sname.'

"; - + // TODO Ajouter rappel pour "il y a des contrats à mettre en service" + // TODO Ajouter rappel pour "il y a des contrats qui arrivent à expiration" + print "
"; + } $db->free(); } else