diff --git a/gestion/tools/stats_cableur.py b/gestion/tools/stats_cableur.py index df687499..27d0cf2c 100644 --- a/gestion/tools/stats_cableur.py +++ b/gestion/tools/stats_cableur.py @@ -6,7 +6,7 @@ import sys sys.path.append("/usr/scripts/gestion") -from types import * +import types from ldap_crans import crans_ldap from pysqlite2 import dbapi2 as sqlite import re @@ -14,7 +14,7 @@ from time import mktime, strptime def plat(chose): """Applatit une liste de liste. Hautement récursif.""" - if type(chose) != ListType: + if type(chose) != types.ListType: return [chose] return sum(map(lambda x: plat(x), chose), []) @@ -57,7 +57,7 @@ hist() # Exemple de requete : -# select nom, count(nom) as combien from historique +# select nom, count(nom) as combien from historique # where date>1093950403 group by nom order by combien ; # select action,count(action) from historique where nom='bernat' and