diff --git a/htdocs/telephonie/contrat/fiche.php b/htdocs/telephonie/contrat/fiche.php index bcfbb57090f..13c6a4609d1 100644 --- a/htdocs/telephonie/contrat/fiche.php +++ b/htdocs/telephonie/contrat/fiche.php @@ -963,26 +963,29 @@ print "\n
\n
\n"; if ($_GET["action"] == '') { - if ($user->rights->telephonie->ligne->creer) + if ($user->rights->telephonie->ligne->creer && $contrat->statut <> 6) { print 'Nouvelle ligne'; } - print "id\">".$langs->trans("Contact").""; + if ($user->rights->telephonie->ligne->creer && $contrat->statut <> 6) + { + print "id\">".$langs->trans("Contact").""; + } - if ($user->rights->telephonie->ligne->creer && $po == 0) + if ($user->rights->telephonie->ligne->creer && $po == 0 && $contrat->statut <> 6) { print "id\">Ajouter une prise d'ordre"; } - - print "id\">".$langs->trans("Edit").""; - - if ($user->rights->telephonie->ligne->creer && $numlignes == 0) + if ($user->rights->telephonie->ligne->creer && $contrat->statut <> 6) { - print "id\">".$langs->trans("Delete").""; + print "id\">".$langs->trans("Edit").""; } - + if ($user->rights->telephonie->ligne->creer && $numlignes == 0 && $contrat->statut <> 6) + { + print "id\">".$langs->trans("Delete").""; + } } print "
";