Bonjour
Je suis admin j’ai tout les droits d’accès.
Je cherche les contacts d’une société COMPANY via le moteur de recherche donc je saisi COMPANY rechercher contacts.
J’ai alors une liste de contacts appartenant à COMPANY.
Je clique sur le nom de la société COMPANY et arrive sur la page comm/card.php?socid=x avec le message Accès refusé.
Après observation je me dis c’est normal car c’est un fournisseur et me demande pourquoi dans la page contact/list.php?search_all=COMPANY j’ai le code suivant :
// Company
if (!empty($arrayfields['p.fk_soc']['checked']) || !empty($arrayfields['s.nom']['checked'])) {
print '<td class="tdoverflowmax200">';
if ($obj->socid) {
$objsoc = new Societe($db);
$objsoc->fetch($obj->socid);
print $objsoc->getNomUrl(1, 'customer', 100, 0, 1, empty($arrayfields['s.name_alias']['checked']) ? 0 : 1);
} else {
print ' ';
}
print '</td>';
if (!$i) {
$totalarray['nbfield']++;
}
}
et non pas dans le getNomUrl:
// Company
if (!empty($arrayfields['p.fk_soc']['checked']) || !empty($arrayfields['s.nom']['checked'])) {
print '<td class="tdoverflowmax200">';
if ($obj->socid) {
$objsoc = new Societe($db);
$objsoc->fetch($obj->socid);
print $objsoc->getNomUrl(1, '', 100, 0, 1, empty($arrayfields['s.name_alias']['checked']) ? 0 : 1);
} else {
print ' ';
}
print '</td>';
if (!$i) {
$totalarray['nbfield']++;
}
}
Merci à vous