Modif des actions possibles suivants les permissions
This commit is contained in:
parent
698de1cbba
commit
c22e32a40d
@ -22,6 +22,7 @@
|
|||||||
require("./pre.inc.php");
|
require("./pre.inc.php");
|
||||||
|
|
||||||
$user->getrights('commande');
|
$user->getrights('commande');
|
||||||
|
$user->getrights('facture');
|
||||||
if (!$user->rights->commande->lire)
|
if (!$user->rights->commande->lire)
|
||||||
accessforbidden();
|
accessforbidden();
|
||||||
|
|
||||||
@ -71,7 +72,7 @@ if ($_GET["id"] > 0)
|
|||||||
$author->fetch();
|
$author->fetch();
|
||||||
|
|
||||||
|
|
||||||
$head[0][0] = DOL_URL_ROOT.'/comm/propal.php?propalid='.$propal->id;
|
$head[0][0] = DOL_URL_ROOT.'/compta/commande.php?id='.$commande->id;
|
||||||
$head[0][1] = "Commande : $commande->ref";
|
$head[0][1] = "Commande : $commande->ref";
|
||||||
$h = 1;
|
$h = 1;
|
||||||
$a = 0;
|
$a = 0;
|
||||||
@ -308,12 +309,14 @@ if ($_GET["id"] > 0)
|
|||||||
{
|
{
|
||||||
print "<br><div class=\"tabsAction\">\n";
|
print "<br><div class=\"tabsAction\">\n";
|
||||||
|
|
||||||
print '<a class="tabAction" href="'.DOL_URL_ROOT.'/compta/facture.php?action=create&commandeid='.$commande->id.'&socidp='.$commande->soc_id.'">Facturer</a>';
|
|
||||||
|
if ($user->rights->facture->creer)
|
||||||
|
print '<a class="tabAction" href="'.DOL_URL_ROOT.'/compta/facture.php?action=create&commandeid='.$commande->id.'&socidp='.$commande->soc_id.'">Facturer</a>';
|
||||||
|
|
||||||
if (!$commande->facturee && $num_fac_asso)
|
if (!$commande->facturee && $num_fac_asso)
|
||||||
{
|
{
|
||||||
|
if ($user->rights->commande->creer)
|
||||||
print '<a class="tabAction" href="'.DOL_URL_ROOT.'/compta/commande.php?action=facturee&id='.$commande->id.'">Classer comme facturée</a>';
|
print '<a class="tabAction" href="'.DOL_URL_ROOT.'/compta/commande.php?action=facturee&id='.$commande->id.'">Classer comme facturée</a>';
|
||||||
|
|
||||||
}
|
}
|
||||||
print '</div>';
|
print '</div>';
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user