diff --git a/htdocs/commande/stats/index.php b/htdocs/commande/stats/index.php
index dd79ee54ba1..8967e22a160 100644
--- a/htdocs/commande/stats/index.php
+++ b/htdocs/commande/stats/index.php
@@ -316,7 +316,6 @@ print '
% | ';
print '';
$oldyear=0;
-$var=true;
foreach ($data as $val)
{
$year = $val['year'];
@@ -324,7 +323,7 @@ foreach ($data as $val)
{ // If we have empty year
$oldyear--;
- print '';
+ print '
';
print '| 0?'&socid='.$socid:'').($userid>0?'&userid='.$userid:'').'">'.$oldyear.' | ';
print '0 | ';
print ' | ';
@@ -336,7 +335,7 @@ foreach ($data as $val)
}
- print '
';
+ print '
';
print '| 0?'&socid='.$socid:'').($userid>0?'&userid='.$userid:'').'">'.$year.' | ';
print ''.$val['nb'].' | ';
print ''.round($val['nb_diff']).' | ';
diff --git a/htdocs/compta/bank/bilan.php b/htdocs/compta/bank/bilan.php
index eb6aea4f2dc..2b3c897f3ce 100644
--- a/htdocs/compta/bank/bilan.php
+++ b/htdocs/compta/bank/bilan.php
@@ -69,22 +69,22 @@ print "
\n";
$sql = "SELECT sum(amount) as amount FROM ".MAIN_DB_PREFIX."paiement";
$paiem = valeur($sql);
-print "| Somme des paiements (associes a une facture) | ".price($paiem)." |
";
+print '| Somme des paiements (associes a une facture) | ".price($paiem)." |
';
$sql = "SELECT sum(amount) as amount FROM ".MAIN_DB_PREFIX."bank WHERE amount > 0";
$credits = valeur($sql);
-print "| Somme des credits | ".price($credits)." |
";
+print '| Somme des credits | ".price($credits)." |
';
$sql = "SELECT sum(amount) as amount FROM ".MAIN_DB_PREFIX."bank WHERE amount < 0";
$debits = valeur($sql);
-print "| Somme des debits | ".price($debits)." |
";
+print '| Somme des debits | ".price($debits)." |
';
$sql = "SELECT sum(amount) as amount FROM ".MAIN_DB_PREFIX."bank ";
$solde = valeur($sql);
-print "| ".$langs->trans("BankBalance")." | ".price($solde)." |
";
+print '| ".$langs->trans("BankBalance")." | ".price($solde)." |
';
print "";
diff --git a/htdocs/compta/facture/card.php b/htdocs/compta/facture/card.php
index 9483e79dba4..495085bc274 100644
--- a/htdocs/compta/facture/card.php
+++ b/htdocs/compta/facture/card.php
@@ -3599,12 +3599,11 @@ else if ($id > 0 || ! empty($ref))
print '';
$total_prev_ht = $total_prev_ttc = 0;
- $var = true;
foreach ($object->tab_previous_situation_invoice as $prev_invoice) {
$totalpaye = $prev_invoice->getSommePaiement();
$total_prev_ht += $prev_invoice->total_ht;
$total_prev_ttc += $prev_invoice->total_ttc;
- print '';
+ print '
';
print '| ' . $prev_invoice->getNomUrl(1) . ' | ';
print ' | ';
if (! empty($conf->banque->enabled))
@@ -3614,10 +3613,9 @@ else if ($id > 0 || ! empty($ref))
print '' . $prev_invoice->getLibStatut(3, $totalpaye) . ' | ';
print '
';
- $var = ! $var;
}
- print '';
+ print '
';
print ' | ';
print '' . price($total_prev_ht) . ' | ';
print '' . price($total_prev_ttc) . ' | ';
@@ -3638,12 +3636,11 @@ else if ($id > 0 || ! empty($ref))
$total_next_ht = $total_next_ttc = 0;
- $var = true;
foreach ($object->tab_next_situation_invoice as $next_invoice) {
$totalpaye = $next_invoice->getSommePaiement();
$total_next_ht += $next_invoice->total_ht;
$total_next_ttc += $next_invoice->total_ttc;
- print '
';
+ print '
';
print '| ' . $next_invoice->getNomUrl(1) . ' | ';
print ' | ';
if (! empty($conf->banque->enabled)) print ' | ';
@@ -3652,10 +3649,9 @@ else if ($id > 0 || ! empty($ref))
print '' . $next_invoice->getLibStatut(3, $totalpaye) . ' | ';
print '
';
- $var = ! $var;
}
- print '';
+ print '
';
print ' | ';
if (! empty($conf->banque->enabled)) print ' | ';
diff --git a/htdocs/compta/facture/stats/index.php b/htdocs/compta/facture/stats/index.php
index 77191136338..55ff4dad6e3 100644
--- a/htdocs/compta/facture/stats/index.php
+++ b/htdocs/compta/facture/stats/index.php
@@ -293,7 +293,6 @@ print '% | ';
print '
';
$oldyear=0;
-$var=true;
foreach ($data as $val)
{
$year = $val['year'];
@@ -301,7 +300,7 @@ foreach ($data as $val)
{ // If we have empty year
$oldyear--;
- print '';
+ print '
';
print '| 0?'&socid='.$socid:'').($userid>0?'&userid='.$userid:'').'">'.$oldyear.' | ';
print '0 | ';
print ' | ';
@@ -312,7 +311,7 @@ foreach ($data as $val)
print '
';
}
- print '';
+ print '
';
print '| 0?'&socid='.$socid:'').($userid>0?'&userid='.$userid:'').'">'.$year.' | ';
print ''.$val['nb'].' | ';
print ''.round($val['nb_diff']).' | ';
diff --git a/htdocs/compta/journal/purchasesjournal.php b/htdocs/compta/journal/purchasesjournal.php
index f0b520bb11e..fbd391ffe2a 100644
--- a/htdocs/compta/journal/purchasesjournal.php
+++ b/htdocs/compta/journal/purchasesjournal.php
@@ -184,7 +184,6 @@ print "".$langs->trans("Account")." | ";
print "".$langs->trans("Type")." | ".$langs->trans("Debit")." | ".$langs->trans("Credit")." | ";
print "
\n";
-$var=false;
$invoicestatic=new FactureFournisseur($db);
$companystatic=new Fournisseur($db);
@@ -229,7 +228,7 @@ foreach ($tabfac as $key => $val)
{
if (isset($line['nomtcheck']) || $mt)
{
- print "";
+ print '
';
print "| ".dol_print_date($db->jdate($val["date"]))." | ";
print "".$invoicestatic->getNomUrl(1)." | ";
print "".$k." | ".$line['label']." | ";
@@ -249,8 +248,6 @@ foreach ($tabfac as $key => $val)
}
}
}
-
- $var = !$var;
}
print "";
diff --git a/htdocs/compta/journal/sellsjournal.php b/htdocs/compta/journal/sellsjournal.php
index 670d89fd2cb..fd0c45be7cd 100644
--- a/htdocs/compta/journal/sellsjournal.php
+++ b/htdocs/compta/journal/sellsjournal.php
@@ -216,7 +216,6 @@ print ''.$langs->trans('Account').' | ';
print ''.$langs->trans('Type').' | '.$langs->trans('Debit').' | '.$langs->trans('Credit').' | ';
print "
\n";
-$var=false;
$invoicestatic=new Facture($db);
$companystatic=new Client($db);
@@ -262,7 +261,7 @@ foreach ($tabfac as $key => $val)
{
if (isset($line['nomtcheck']) || $mt)
{
- print "";
+ print '
';
print "| ".dol_print_date($db->jdate($val["date"]))." | ";
print "".$invoicestatic->getNomUrl(1)." | ";
print "".$k." | ".$line['label']." | ";
@@ -282,8 +281,6 @@ foreach ($tabfac as $key => $val)
}
}
}
-
- $var = !$var;
}
print "";
diff --git a/htdocs/compta/paiement/rapport.php b/htdocs/compta/paiement/rapport.php
index e9a90667e69..c73f79c60a4 100644
--- a/htdocs/compta/paiement/rapport.php
+++ b/htdocs/compta/paiement/rapport.php
@@ -145,7 +145,7 @@ if ($year)
print ''.$langs->trans("Size").' | ';
print ''.$langs->trans("Date").' | ';
print '
';
- $var=true;
+
if (is_resource($handle))
{
while (($file = readdir($handle))!==false)
@@ -155,7 +155,7 @@ if ($year)
$tfile = $dir . '/'.$year.'/'.$file;
$relativepath = $year.'/'.$file;
- print "".'| '.img_pdf().' '.$file.' | ';
+ print '
'.'| '.img_pdf().' '.$file.' | ';
print ''.dol_print_size(dol_filesize($tfile)).' | ';
print ''.dol_print_date(dol_filemtime($tfile),"dayhour").' |
';
}
diff --git a/htdocs/compta/prelevement/bons.php b/htdocs/compta/prelevement/bons.php
index dbbf9d09ac7..973135765dc 100644
--- a/htdocs/compta/prelevement/bons.php
+++ b/htdocs/compta/prelevement/bons.php
@@ -129,14 +129,12 @@ if ($result)
print '';
print '';
- $var=True;
while ($i < min($num,$limit))
{
- $obj = $db->fetch_object($result);
-
+ $obj = $db->fetch_object($result);
- print "| ";
+ print ' |
| ';
print $bon->LibStatut($obj->statut,2);
print " ";
diff --git a/htdocs/compta/prelevement/fiche-rejet.php b/htdocs/compta/prelevement/fiche-rejet.php
index 064f41e41e8..f2240a070e6 100644
--- a/htdocs/compta/prelevement/fiche-rejet.php
+++ b/htdocs/compta/prelevement/fiche-rejet.php
@@ -138,7 +138,6 @@ if ($resql)
print ' | '.$langs->trans("Line").' | '.$langs->trans("ThirdParty").' | '.$langs->trans("Amount").' | ';
print ''.$langs->trans("Reason").' | '.$langs->trans("ToBill").' | '.$langs->trans("Invoice").' |
';
- $var=True;
$total = 0;
if ($num > 0)
@@ -148,7 +147,7 @@ if ($resql)
{
$obj = $db->fetch_object($resql);
- print "| ";
+ print ' |
';
print '';
print img_picto('', 'statut'.$obj->statut).' ';
diff --git a/htdocs/compta/prelevement/fiche-stat.php b/htdocs/compta/prelevement/fiche-stat.php
index c5d441e3260..7e0c4f81e4b 100644
--- a/htdocs/compta/prelevement/fiche-stat.php
+++ b/htdocs/compta/prelevement/fiche-stat.php
@@ -127,13 +127,11 @@ if ($prev_id)
print '';
print '| '.$langs->trans("Status").' | '.$langs->trans("Amount").' | % | ';
- $var=false;
-
while ($i < $num)
{
$row = $db->fetch_row($resql);
- print "| ";
+ print ' | | ';
print $ligne->LibStatut($row[1],1);
diff --git a/htdocs/compta/prelevement/ligne.php b/htdocs/compta/prelevement/ligne.php
index 64ddb12a7bc..933c23b0e7e 100644
--- a/htdocs/compta/prelevement/ligne.php
+++ b/htdocs/compta/prelevement/ligne.php
@@ -298,16 +298,13 @@ if ($id)
print ' | '.$langs->trans("Invoice").' | '.$langs->trans("ThirdParty").' | '.$langs->trans("Amount").' | '.$langs->trans("Status").' | ';
print ' ';
- $var=True;
-
$total = 0;
- $var=false;
while ($i < min($num,$conf->liste_limit))
{
$obj = $db->fetch_object($result);
- print "| ";
+ print ' | | ';
print '';
print img_object($langs->trans("ShowBill"),"bill");
diff --git a/htdocs/compta/prelevement/list.php b/htdocs/compta/prelevement/list.php
index f7fe4b77e7d..2fa8a255407 100644
--- a/htdocs/compta/prelevement/list.php
+++ b/htdocs/compta/prelevement/list.php
@@ -159,15 +159,11 @@ if ($result)
print ' | ';
print ' ';
- $var=True;
-
while ($i < min($num,$limit))
{
- $obj = $db->fetch_object($result);
+ $obj = $db->fetch_object($result);
-
-
- print "| ";
+ print ' | | ';
print $ligne->LibStatut($obj->statut_ligne,2);
print " ";
diff --git a/htdocs/compta/prelevement/rejets.php b/htdocs/compta/prelevement/rejets.php
index ef72ca8f6e5..0f737a50f22 100644
--- a/htdocs/compta/prelevement/rejets.php
+++ b/htdocs/compta/prelevement/rejets.php
@@ -94,15 +94,13 @@ if ($result)
print_liste_field_titre($langs->trans("Reason"),$_SERVER["PHP_SELF"],"pr.motif","",$urladd);
print " | \n";
- $var=True;
-
$total = 0;
while ($i < min($num,$conf->liste_limit))
{
$obj = $db->fetch_object($result);
- print "| ";
+ print ' | | ';
print $ligne->LibStatut($obj->statut,2).' ';
print '';
diff --git a/htdocs/compta/prelevement/stats.php b/htdocs/compta/prelevement/stats.php
index b666b355e24..406c2303b6a 100644
--- a/htdocs/compta/prelevement/stats.php
+++ b/htdocs/compta/prelevement/stats.php
@@ -96,13 +96,11 @@ if ($resql)
print ' | '.$langs->trans("Status").' | '.$langs->trans("Number").' | % | ';
print ''.$langs->trans("Amount").' | % | ';
- $var=false;
-
while ($i < $num)
{
$row = $db->fetch_row($resql);
- print "| ";
+ print ' | | ';
print $ligne->LibStatut($row[2],1);
//print $st[$row[2]];
@@ -119,7 +117,6 @@ if ($resql)
print ' | ';
print round($row[0]/$total*100,2)." %";
print ' | ';
-
$i++;
}
@@ -192,8 +189,6 @@ if ($resql)
print ' | '.$langs->trans("Status").' | '.$langs->trans("Number").' | ';
print '% | '.$langs->trans("Amount").' | % |
';
- $var=True;
-
require_once DOL_DOCUMENT_ROOT.'/compta/prelevement/class/rejetprelevement.class.php';
$Rejet = new RejetPrelevement($db, $user);
@@ -201,7 +196,7 @@ if ($resql)
{
$row = $db->fetch_row($resql);
- print "| ";
+ print ' |
| ';
print $Rejet->motifs[$row[2]];
print ' | '.$row[1];
@@ -215,9 +210,7 @@ if ($resql)
print ' | ';
print round($row[0]/$total*100,2)." %";
-
print ' |
';
-
$i++;
}