Merge pull request #18243 from Robin-Yann/13-hook
13 - add hook product part
This commit is contained in:
commit
583f1ccc1a
@ -51,6 +51,9 @@ if (!empty($user->socid)) {
|
|||||||
$fieldvalue = (!empty($id) ? $id : (!empty($ref) ? $ref : ''));
|
$fieldvalue = (!empty($id) ? $id : (!empty($ref) ? $ref : ''));
|
||||||
$fieldtype = (!empty($ref) ? 'ref' : 'rowid');
|
$fieldtype = (!empty($ref) ? 'ref' : 'rowid');
|
||||||
|
|
||||||
|
// 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);
|
$object = new Product($db);
|
||||||
$objectid = 0;
|
$objectid = 0;
|
||||||
if ($id > 0 || !empty($ref)) {
|
if ($id > 0 || !empty($ref)) {
|
||||||
|
|||||||
@ -59,6 +59,9 @@ if (!empty($user->socid)) {
|
|||||||
$fieldvalue = (!empty($id) ? $id : $ref);
|
$fieldvalue = (!empty($id) ? $id : $ref);
|
||||||
$fieldtype = (!empty($ref) ? 'ref' : 'rowid');
|
$fieldtype = (!empty($ref) ? 'ref' : 'rowid');
|
||||||
|
|
||||||
|
// Initialize technical object to manage hooks of page. Note that conf->hooks_modules contains array of hook context
|
||||||
|
$hookmanager->initHooks(array('productstatscard', 'globalcard'));
|
||||||
|
|
||||||
$tmp = dol_getdate(dol_now());
|
$tmp = dol_getdate(dol_now());
|
||||||
$currentyear = $tmp['year'];
|
$currentyear = $tmp['year'];
|
||||||
if (empty($search_year)) {
|
if (empty($search_year)) {
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user