From 135b1ec1cda12f7cd2885fb5d4510af2fa14136e Mon Sep 17 00:00:00 2001 From: lLefevre Date: Fri, 6 Jan 2012 08:27:26 +0000 Subject: [PATCH] [-] BO : fix #PSFV-347 --- modules/followup/followup.php | 19 +++++++++++-------- 1 file changed, 11 insertions(+), 8 deletions(-) diff --git a/modules/followup/followup.php b/modules/followup/followup.php index 37b663ee5..1ae730705 100644 --- a/modules/followup/followup.php +++ b/modules/followup/followup.php @@ -88,7 +88,8 @@ class Followup extends Module } public function getContent() - { + { + $html = ''; /* Save settings */ if (Tools::isSubmit('submitFollowUp')) foreach ($this->confKeys AS $c) @@ -106,7 +107,7 @@ class Followup extends Module $n3 = $this->bestCustomer(true); $n4 = $this->badCustomer(true); - echo ' + $html .= '

'.$this->l('Customer follow-up').'

@@ -211,7 +212,7 @@ class Followup extends Module $statsArray[$stat['date_stat']][$stat['id_email_type']]['nb_used'] = (int)($stat['nb_used']); } - echo ' + $html .= ' '.$this->l('S').' '.$this->l('U').' @@ -228,7 +229,7 @@ class Followup extends Module '; if (!sizeof($statsArray)) - echo ''.$this->l('No statistics at this time.').''; + $html .= ''.$this->l('No statistics at this time.').''; foreach ($statsArray AS $date_stat => $array) { $rates = array(); @@ -236,27 +237,29 @@ class Followup extends Module if (isset($statsArray[$date_stat][$i]['nb']) AND isset($statsArray[$date_stat][$i]['nb_used']) AND $statsArray[$date_stat][$i]['nb_used'] > 0) $rates[$i] = number_format(($statsArray[$date_stat][$i]['nb_used'] / $statsArray[$date_stat][$i]['nb'])*100, 2, '.', ''); - echo ' + $html .= ' '.$date_stat.''; for ($i = 1; $i != 5; $i++) { - echo ' + $html .= ' '.(isset($statsArray[$date_stat][$i]['nb']) ? (int)($statsArray[$date_stat][$i]['nb']) : 0).' '.(isset($statsArray[$date_stat][$i]['nb_used']) ? (int)($statsArray[$date_stat][$i]['nb_used']) : 0).' '.(isset($rates[$i]) ? ''.$rates[$i].'' : '0.00').''; } - echo ' + $html .= ' '; } - echo ' + $html .= '
'; + + return $html; } /* Log each sent e-mail */