diff --git a/htdocs/core/lib/company.lib.php b/htdocs/core/lib/company.lib.php index 9a67065fe64..ce5345854f0 100644 --- a/htdocs/core/lib/company.lib.php +++ b/htdocs/core/lib/company.lib.php @@ -632,40 +632,6 @@ function show_contacts($conf,$langs,$db,$object,$backtopage='') print "\n"; - print ''; - // Name - Position - print ''; - print ''; - print ''; - - // Address / Phone - print ''; - //print ''; - print ''; - - // Email - print ' '; - - // Status - print ''; - print $form->selectarray('search_status', array('-1'=>'','0'=>$contactstatic->LibStatut(0,1),'1'=>$contactstatic->LibStatut(1,1)),$search_status); - print ''; - - // Add to agenda - if (! empty($conf->agenda->enabled) && $user->rights->agenda->myactions->create) - { - $colspan++; - print ' '; - } - - // Edit - print ''; - print ''; - print ''; - - print ""; - - $sql = "SELECT p.rowid, p.lastname, p.firstname, p.fk_pays as country_id, p.civility, p.poste, p.phone as phone_pro, p.phone_mobile, p.phone_perso, p.fax, p.email, p.skype, p.statut "; $sql .= ", p.civility as civility_id, p.address, p.zip, p.town"; $sql .= " FROM ".MAIN_DB_PREFIX."socpeople as p"; @@ -683,6 +649,39 @@ function show_contacts($conf,$langs,$db,$object,$backtopage='') $var=true; if ($num) { + print ''; + // Name - Position + print ''; + print ''; + print ''; + + // Address / Phone + print ''; + //print ''; + print ''; + + // Email + print ' '; + + // Status + print ''; + print $form->selectarray('search_status', array('-1'=>'','0'=>$contactstatic->LibStatut(0,1),'1'=>$contactstatic->LibStatut(1,1)),$search_status); + print ''; + + // Add to agenda + if (! empty($conf->agenda->enabled) && $user->rights->agenda->myactions->create) + { + $colspan++; + print ' '; + } + + // Edit + print ''; + print ''; + print ''; + + print ""; + $i=0; while ($i < $num)