From 7a68d9a940fb5a3431368545ae4b62fc20cb55d7 Mon Sep 17 00:00:00 2001 From: Laurent Destailleur Date: Thu, 16 Oct 2014 20:55:13 +0200 Subject: [PATCH] Miscellaneous fixes --- htdocs/adherents/index.php | 2 +- htdocs/categories/index.php | 2 +- htdocs/compta/bank/index.php | 6 +++++- htdocs/core/class/html.form.class.php | 2 +- htdocs/core/lib/company.lib.php | 11 ++++++----- htdocs/core/lib/functions.lib.php | 2 +- htdocs/product/index.php | 2 +- htdocs/societe/consumption.php | 4 ++-- htdocs/societe/index.php | 2 +- 9 files changed, 19 insertions(+), 14 deletions(-) diff --git a/htdocs/adherents/index.php b/htdocs/adherents/index.php index 1ec3d71c664..62e54c17948 100644 --- a/htdocs/adherents/index.php +++ b/htdocs/adherents/index.php @@ -159,7 +159,7 @@ if ($conf->use_javascript_ajax) print '
'; print ''; print ''; - print ''; } diff --git a/htdocs/compta/bank/index.php b/htdocs/compta/bank/index.php index 921b1739767..e6961ed97dd 100644 --- a/htdocs/compta/bank/index.php +++ b/htdocs/compta/bank/index.php @@ -233,7 +233,11 @@ foreach ($accounts as $key=>$type) $total[$acc->currency_code] += $solde; } } -if (! $found) print ''; +if (! $found) +{ + $var = !$var; + print ''; +} // Total foreach ($total as $key=>$solde) { diff --git a/htdocs/core/class/html.form.class.php b/htdocs/core/class/html.form.class.php index d4effca3905..b26147918ca 100644 --- a/htdocs/core/class/html.form.class.php +++ b/htdocs/core/class/html.form.class.php @@ -193,7 +193,7 @@ class Form { $ret.=''; } diff --git a/htdocs/core/lib/company.lib.php b/htdocs/core/lib/company.lib.php index c5ba612b60f..7236d411c22 100644 --- a/htdocs/core/lib/company.lib.php +++ b/htdocs/core/lib/company.lib.php @@ -128,7 +128,7 @@ function societe_prepare_head($object) else { dol_print_error($db); } - + $head[$h][0] = DOL_URL_ROOT.'/societe/notify/card.php?socid='.$object->id; $head[$h][1] = $langs->trans("Notifications"); if($nbNote > 0) $head[$h][1].= ' ('.$nbNote.')'; @@ -492,7 +492,7 @@ function show_projects($conf,$langs,$db,$object,$backtopage='') $projectstatic = new Project($db); $i=0; - $var=true; + $var=false; while ($i < $num) { $obj = $db->fetch_object($result); @@ -521,8 +521,9 @@ function show_projects($conf,$langs,$db,$object,$backtopage='') } } else - { - print ''; + { + $var = false; + print ''; } $db->free($result); } @@ -680,7 +681,7 @@ function show_contacts($conf,$langs,$db,$object,$backtopage='') $result = $db->query($sql); $num = $db->num_rows($result); - $var=true; + $var=false; if ($num) { $i=0; diff --git a/htdocs/core/lib/functions.lib.php b/htdocs/core/lib/functions.lib.php index 7b79adc86c4..1b76d0e3572 100644 --- a/htdocs/core/lib/functions.lib.php +++ b/htdocs/core/lib/functions.lib.php @@ -670,7 +670,7 @@ function dol_get_fiche_head($links=array(), $active='0', $title='', $notab=0, $p { $isactive=(is_numeric($active) && $i == $active) || (! is_numeric($active) && $active == $links[$i][2]); - $out.='
'; + $out.='
'; if (isset($links[$i][2]) && $links[$i][2] == 'image') { if (!empty($links[$i][0])) diff --git a/htdocs/product/index.php b/htdocs/product/index.php index 3e18cc5d042..45f90823747 100644 --- a/htdocs/product/index.php +++ b/htdocs/product/index.php @@ -173,7 +173,7 @@ if (! empty($conf->categorie->enabled)) print '
'; print '
'.$langs->trans("Statistics").'
'; + print '
'; $SommeA=0; $SommeB=0; diff --git a/htdocs/categories/index.php b/htdocs/categories/index.php index eceeb2890bc..76a19c91d7d 100644 --- a/htdocs/categories/index.php +++ b/htdocs/categories/index.php @@ -171,7 +171,7 @@ $nbofentries=(count($data) - 1); if ($nbofentries > 0) { - print '
'; + print '
'; tree_recur($data,$data[0],0); print '
'.$langs->trans("None").'
'.$langs->trans("None").'
'; $ret.=''; - $ret.='
'."\n"; + //$ret.='
'."\n"; $ret.=''; $ret.='
'.$langs->trans("None").'
'.$langs->trans("None").'
'; print ''; - print ''; + print ''; } else { - print ''; + print ''; } print "
'.$langs->trans("Categories").'
'; + print '
'; $sql = "SELECT c.label, count(*) as nb"; $sql.= " FROM ".MAIN_DB_PREFIX."categorie_product as cs"; $sql.= " LEFT JOIN ".MAIN_DB_PREFIX."categorie as c ON cs.fk_categorie = c.rowid"; diff --git a/htdocs/societe/consumption.php b/htdocs/societe/consumption.php index 0aa9f0e5979..f89212e5fbc 100644 --- a/htdocs/societe/consumption.php +++ b/htdocs/societe/consumption.php @@ -494,10 +494,10 @@ if ($sql_select) } else if (empty($type_element) || $type_element == -1) { - print '
'.$langs->trans("SelectElementAndClickRefresh").'
'.$langs->trans("SelectElementAndClickRefresh").'
'.$langs->trans("FeatureNotYetAvailable").'
'.$langs->trans("FeatureNotYetAvailable").'
"; diff --git a/htdocs/societe/index.php b/htdocs/societe/index.php index 740a6157809..243b55f01ca 100644 --- a/htdocs/societe/index.php +++ b/htdocs/societe/index.php @@ -183,7 +183,7 @@ if (! empty($conf->categorie->enabled)) print '
'; print ''; print ''; - print '
'.$langs->trans("Categories").'
'; + print '
'; $sql = "SELECT c.label, count(*) as nb"; $sql.= " FROM ".MAIN_DB_PREFIX."categorie_societe as cs"; $sql.= " LEFT JOIN ".MAIN_DB_PREFIX."categorie as c ON cs.fk_categorie = c.rowid";