diff --git a/htdocs/comm/clients.php b/htdocs/comm/clients.php index 7da373e9252..847c38999ce 100644 --- a/htdocs/comm/clients.php +++ b/htdocs/comm/clients.php @@ -26,6 +26,12 @@ require("../lib/webcal.class.php"); require("../cactioncomm.class.php"); require("../actioncomm.class.php"); +$user->getrights('propale'); +$user->getrights('fichinter'); +$user->getrights('commande'); +$user->getrights('projet'); + + /* * Sécurité accés client */ diff --git a/htdocs/comm/contact.php b/htdocs/comm/contact.php index 7a8eae35dd8..778bf4160ef 100644 --- a/htdocs/comm/contact.php +++ b/htdocs/comm/contact.php @@ -23,6 +23,12 @@ */ require("./pre.inc.php"); +$user->getrights('propale'); +$user->getrights('fichinter'); +$user->getrights('commande'); +$user->getrights('projet'); + + llxHeader(); /* @@ -49,7 +55,10 @@ $offset = $limit * $page ; if ($type == "c") { - $label = " prospects/clients"; + $label = " clients"; +} +if ($type == "p") { + $label = " prospects"; } if ($type == "f") { $label = " fournisseurs"; @@ -70,6 +79,9 @@ $sql .= " WHERE s.fk_stcomm = st.id AND s.idp = p.fk_soc"; if ($type == "c") { $sql .= " AND s.client = 1"; } +if ($type == "p") { + $sql .= " AND s.client = 2"; +} if ($type == "f") { $sql .= " AND s.fournisseur = 1"; } diff --git a/htdocs/comm/fiche.php b/htdocs/comm/fiche.php index 5ee7e97cc6b..2b07e88581b 100644 --- a/htdocs/comm/fiche.php +++ b/htdocs/comm/fiche.php @@ -26,11 +26,14 @@ require("../lib/webcal.class.php"); require("../cactioncomm.class.php"); require("../actioncomm.class.php"); -llxHeader(); $user->getrights('propale'); +$user->getrights('fichinter'); $user->getrights('commande'); $user->getrights('projet'); + +llxHeader(); + if ($sortorder == "") { $sortorder="ASC"; } diff --git a/htdocs/comm/index.php b/htdocs/comm/index.php index 42bc1d45c33..5ee3869f00b 100644 --- a/htdocs/comm/index.php +++ b/htdocs/comm/index.php @@ -23,6 +23,10 @@ require("./pre.inc.php"); $user->getrights('propale'); +$user->getrights('fichinter'); +$user->getrights('commande'); +$user->getrights('projet'); + if ($user->societe_id > 0) {