From 6b55b9fb28bce93b4951e59b780d620a6d962407 Mon Sep 17 00:00:00 2001 From: Antonin MARCHAL Date: Sat, 8 May 2021 11:45:07 +0200 Subject: [PATCH] add (hooks) init hooks on all tabs for supplier order --- htdocs/fourn/commande/contact.php | 1 + htdocs/fourn/commande/document.php | 1 + htdocs/fourn/commande/info.php | 1 + htdocs/fourn/commande/note.php | 2 ++ 4 files changed, 5 insertions(+) diff --git a/htdocs/fourn/commande/contact.php b/htdocs/fourn/commande/contact.php index f52aa20d494..4e5e6849cb2 100644 --- a/htdocs/fourn/commande/contact.php +++ b/htdocs/fourn/commande/contact.php @@ -45,6 +45,7 @@ if ($user->socid) { $socid = $user->socid; } $result = restrictedArea($user, 'fournisseur', $id, 'commande_fournisseur', 'commande'); +$hookmanager->initHooks(array('ordersuppliercardcontact')); $object = new CommandeFournisseur($db); diff --git a/htdocs/fourn/commande/document.php b/htdocs/fourn/commande/document.php index f3dc1d26496..219c215143e 100644 --- a/htdocs/fourn/commande/document.php +++ b/htdocs/fourn/commande/document.php @@ -70,6 +70,7 @@ if (!$sortfield) { $sortfield = "name"; } +$hookmanager->initHooks(array('ordersuppliercarddocument')); $object = new CommandeFournisseur($db); if ($object->fetch($id, $ref) < 0) { diff --git a/htdocs/fourn/commande/info.php b/htdocs/fourn/commande/info.php index 9260dab0b42..f35455f11d9 100644 --- a/htdocs/fourn/commande/info.php +++ b/htdocs/fourn/commande/info.php @@ -78,6 +78,7 @@ if (!$user->rights->fournisseur->commande->lire) { accessforbidden(); } +$hookmanager->initHooks(array('ordersuppliercardinfo')); diff --git a/htdocs/fourn/commande/note.php b/htdocs/fourn/commande/note.php index c4cc134fee7..b272b94eddf 100644 --- a/htdocs/fourn/commande/note.php +++ b/htdocs/fourn/commande/note.php @@ -48,6 +48,8 @@ $result = restrictedArea($user, 'fournisseur', $id, 'commande_fournisseur', 'com $object = new CommandeFournisseur($db); $object->fetch($id, $ref); +$hookmanager->initHooks(array('ordersuppliercardnote')); + $permissionnote = ($user->rights->fournisseur->commande->creer || $user->rights->supplier_order->creer); // Used by the include of actions_setnotes.inc.php