add hook product composition

This commit is contained in:
Robin 2021-07-27 09:13:50 +02:00
parent a386cf5e89
commit d2dc2bfde2

View File

@ -50,6 +50,9 @@ $fieldvalue = (!empty($id) ? $id : (!empty($ref) ? $ref : ''));
$fieldtype = (!empty($ref) ? 'ref' : 'rowid');
$result = restrictedArea($user, 'produit|service', $fieldvalue, 'product&product', '', '', $fieldtype);
// Initialize technical object to manage hooks of page. Note that conf->hooks_modules contains array of hook context
$hookmanager->initHooks(array('productcompositioncard', 'globalcard'));
$object = new Product($db);
$objectid = 0;
if ($id > 0 || !empty($ref))