| '.$langs->trans("ThirdParty").' | ';
@@ -262,8 +262,8 @@ print '';
print ' ';
//}
-print ' ';
-print '';
+print '';
+print '';
print '| '.$langs->trans("Year").' | ';
print ''.$langs->trans("NbOfProposals").' | ';
print '% | ';
@@ -274,13 +274,15 @@ print '% | ';
print ' ';
$oldyear=0;
+$var=true;
foreach ($data as $val)
{
$year = $val['year'];
while (! empty($year) && $oldyear > $year+1)
{ // If we have empty year
$oldyear--;
- print '';
+ $var=!$var;
+ print ' ';
print '| 0?'&socid='.$socid:'').($userid>0?'&userid='.$userid:'').'">'.$oldyear.' | ';
print '0 | ';
print ' | ';
@@ -290,7 +292,7 @@ foreach ($data as $val)
print ' | ';
print ' ';
}
- print '';
+ print ' ';
print '| 0?'&socid='.$socid:'').($userid>0?'&userid='.$userid:'').'">'.$year.' | ';
print ''.$val['nb'].' | ';
print ''.round($val['nb_diff']).' | ';
diff --git a/htdocs/commande/list.php b/htdocs/commande/list.php
index 200f9e66362..29d58eaf467 100644
--- a/htdocs/commande/list.php
+++ b/htdocs/commande/list.php
@@ -273,15 +273,15 @@ if ($resql)
$moreforfilter.=$formother->select_salesrepresentatives($search_sale, 'search_sale', $user, 0, 1, 'maxwidth300');
$moreforfilter.='';
}
- // If the user can view prospects other than his'
- if ($user->rights->societe->client->voir || $socid)
+ // If the user can view other users
+ if ($user->rights->user->user->lire)
{
$moreforfilter.='';
$moreforfilter.=$langs->trans('LinkedToSpecificUsers'). ': ';
$moreforfilter.=$form->select_dolusers($search_user, 'search_user', 1, '', 0, '', '', 0, 0, 0, '', 0, '', 'maxwidth300');
$moreforfilter.=' ';
}
- // If the user can view prospects other than his'
+ // If the user can view categories or products
if ($conf->categorie->enabled && $user->rights->produit->lire)
{
include_once DOL_DOCUMENT_ROOT.'/categories/class/categorie.class.php';
diff --git a/htdocs/commande/stats/index.php b/htdocs/commande/stats/index.php
index c4d48d8f72e..04cfad1732d 100644
--- a/htdocs/commande/stats/index.php
+++ b/htdocs/commande/stats/index.php
@@ -250,7 +250,7 @@ print '';
// Show filter box
print ' |