diff --git a/htdocs/adherents/stats/index.php b/htdocs/adherents/stats/index.php index 8e19ce15ffe..40d7bd8d77c 100644 --- a/htdocs/adherents/stats/index.php +++ b/htdocs/adherents/stats/index.php @@ -28,8 +28,8 @@ require_once DOL_DOCUMENT_ROOT.'/adherents/class/adherentstats.class.php'; require_once DOL_DOCUMENT_ROOT.'/core/class/dolgraph.class.php'; require_once DOL_DOCUMENT_ROOT.'/core/lib/member.lib.php'; -$WIDTH=500; -$HEIGHT=200; +$WIDTH=DolGraph::getDefaultGraphSizeForStats('width'); +$HEIGHT=DolGraph::getDefaultGraphSizeForStats('height'); $userid=GETPOST('userid','int'); if ($userid < 0) $userid=0; $socid=GETPOST('socid','int'); if ($socid < 0) $socid=0; @@ -143,8 +143,7 @@ $head = member_stats_prepare_head($adh); dol_fiche_head($head, 'statssubscription', $langs->trans("Statistics"), 0, 'user'); -print ''; -print '
'; +print '
'; // Show filter box /*print '
'; @@ -210,8 +209,8 @@ foreach ($data as $val) print '
'; -print ''; -print ''; +print '
'; + // Show graphs print '
'; @@ -223,7 +222,10 @@ else { } print '
'; -print ''; + +print '
'; +print '
'; + dol_fiche_end(); diff --git a/htdocs/comm/propal/stats/index.php b/htdocs/comm/propal/stats/index.php index a76b21a0371..ef979275101 100644 --- a/htdocs/comm/propal/stats/index.php +++ b/htdocs/comm/propal/stats/index.php @@ -28,8 +28,8 @@ require '../../../main.inc.php'; require_once DOL_DOCUMENT_ROOT.'/comm/propal/class/propalestats.class.php'; require_once DOL_DOCUMENT_ROOT.'/core/class/dolgraph.class.php'; -$WIDTH=500; -$HEIGHT=200; +$WIDTH=DolGraph::getDefaultGraphSizeForStats('width'); +$HEIGHT=DolGraph::getDefaultGraphSizeForStats('height'); $userid=GETPOST('userid','int'); if ($userid < 0) $userid=0; $socid=GETPOST('socid','int'); if ($socid < 0) $socid=0; @@ -216,8 +216,9 @@ complete_head_from_modules($conf,$langs,null,$head,$h,'propal_stats'); dol_fiche_head($head,'byyear',$langs->trans("Statistics")); -print ''; -print '
'; + +print '
'; + //if (empty($socid)) //{ @@ -282,8 +283,8 @@ foreach ($data as $val) print '
'; -print ''; -print ''; +print '
'; + // Show graphs print '
'; @@ -297,7 +298,10 @@ else { } print '
'; -print ''; + +print '
'; +print '
'; + dol_fiche_end(); diff --git a/htdocs/commande/stats/index.php b/htdocs/commande/stats/index.php index 1c8a52e201a..cb7e2034275 100644 --- a/htdocs/commande/stats/index.php +++ b/htdocs/commande/stats/index.php @@ -1,6 +1,6 @@ - * Copyright (c) 2004-2012 Laurent Destailleur + * Copyright (c) 2004-2013 Laurent Destailleur * Copyright (C) 2005-2012 Regis Houssin * Copyright (C) 2012 Marcos GarcĂ­a * @@ -29,8 +29,8 @@ require_once DOL_DOCUMENT_ROOT.'/commande/class/commande.class.php'; require_once DOL_DOCUMENT_ROOT.'/commande/class/commandestats.class.php'; require_once DOL_DOCUMENT_ROOT.'/core/class/dolgraph.class.php'; -$WIDTH=500; -$HEIGHT=200; +$WIDTH=DolGraph::getDefaultGraphSizeForStats('width'); +$HEIGHT=DolGraph::getDefaultGraphSizeForStats('height'); $mode=GETPOST("mode")?GETPOST("mode"):'customer'; if ($mode == 'customer' && ! $user->rights->commande->lire) accessforbidden(); @@ -237,8 +237,9 @@ complete_head_from_modules($conf,$langs,null,$head,$h,$type); dol_fiche_head($head,'byyear',$langs->trans("Statistics")); -print ''; -print '
'; + +print '
'; + //if (empty($socid)) //{ @@ -305,8 +306,8 @@ foreach ($data as $val) print '
'; -print ''; -print ''; +print '
'; + // Show graphs print '
'; @@ -320,7 +321,9 @@ else { } print '
'; -print ''; + +print '
'; +print '
'; dol_fiche_end(); diff --git a/htdocs/compta/deplacement/stats/index.php b/htdocs/compta/deplacement/stats/index.php index 2c8bf25fd5c..eade2e3c13d 100755 --- a/htdocs/compta/deplacement/stats/index.php +++ b/htdocs/compta/deplacement/stats/index.php @@ -29,8 +29,8 @@ require_once DOL_DOCUMENT_ROOT.'/compta/deplacement/class/deplacementstats.class $langs->load("trips"); -$WIDTH=500; -$HEIGHT=200; +$WIDTH=DolGraph::getDefaultGraphSizeForStats('width'); +$HEIGHT=DolGraph::getDefaultGraphSizeForStats('height'); $userid=GETPOST('userid','int'); if ($userid < 0) $userid=0; $socid=GETPOST('socid','int'); if ($socid < 0) $socid=0; @@ -204,8 +204,9 @@ complete_head_from_modules($conf,$langs,null,$head,$h,'trip_stats'); dol_fiche_head($head,'byyear',$langs->trans("Statistics")); -print ''; -print '
'; + +print '
'; + // Show filter box print ''; @@ -266,8 +267,8 @@ foreach ($data as $val) print '
'; -print ''; -print ''; +print '
'; + // Show graphs print '
'; @@ -281,7 +282,10 @@ else { } print '
'; -print ''; + +print '
'; +print '
'; + dol_fiche_end(); diff --git a/htdocs/compta/facture/stats/index.php b/htdocs/compta/facture/stats/index.php index 7fc43f1edfe..bfc50b11ae8 100644 --- a/htdocs/compta/facture/stats/index.php +++ b/htdocs/compta/facture/stats/index.php @@ -27,8 +27,8 @@ require '../../../main.inc.php'; require_once DOL_DOCUMENT_ROOT.'/core/class/dolgraph.class.php'; require_once DOL_DOCUMENT_ROOT.'/compta/facture/class/facturestats.class.php'; -$WIDTH=500; -$HEIGHT=200; +$WIDTH=DolGraph::getDefaultGraphSizeForStats('width'); +$HEIGHT=DolGraph::getDefaultGraphSizeForStats('height'); $mode=GETPOST("mode")?GETPOST("mode"):'customer'; if ($mode == 'customer' && ! $user->rights->facture->lire) accessforbidden(); @@ -214,8 +214,9 @@ complete_head_from_modules($conf,$langs,null,$head,$h,$type); dol_fiche_head($head,'byyear',$langs->trans("Statistics")); -print ''; -print '
'; + +print '
'; + //if (empty($socid)) //{ @@ -280,8 +281,8 @@ foreach ($data as $val) print '
'; -print ''; -print ''; +print '
'; + // Show graphs print '
'; @@ -295,7 +296,10 @@ else { } print '
'; -print ''; + +print '
'; +print '
'; + dol_fiche_end(); diff --git a/htdocs/core/class/dolgraph.class.php b/htdocs/core/class/dolgraph.class.php index 087fd03b237..dd512b25f02 100644 --- a/htdocs/core/class/dolgraph.class.php +++ b/htdocs/core/class/dolgraph.class.php @@ -785,7 +785,7 @@ class DolGraph $this->_stringtoshow =''."\n"; $this->_stringtoshow.='
'.$this->title.'

'; - $this->_stringtoshow.='
'."\n"; + $this->_stringtoshow.='
'."\n"; $this->_stringtoshow.='