FIX hidden option MAIN_PROPAGATE_CONTACTS_FROM_ORIGIN
This commit is contained in:
parent
7d42a58230
commit
59ab52c718
@ -398,6 +398,7 @@ if (empty($reshook))
|
||||
}
|
||||
|
||||
// Now we create same links to contact than the ones found on origin object
|
||||
/* Useless, already into the create
|
||||
if (! empty($conf->global->MAIN_PROPAGATE_CONTACTS_FROM_ORIGIN))
|
||||
{
|
||||
$originforcontact = $object->origin;
|
||||
@ -420,7 +421,7 @@ if (empty($reshook))
|
||||
}
|
||||
}
|
||||
else dol_print_error($resqlcontact);
|
||||
}
|
||||
}*/
|
||||
|
||||
// Hooks
|
||||
$parameters = array('objFrom' => $srcobject);
|
||||
|
||||
@ -920,7 +920,8 @@ class Commande extends CommonOrder
|
||||
foreach ($exp->linkedObjectsIds['commande'] as $key => $value)
|
||||
{
|
||||
$originforcontact = 'commande';
|
||||
$originidforcontact = $value->id;
|
||||
if (is_object($value)) $originidforcontact = $value->id;
|
||||
else $originidforcontact = $value;
|
||||
break; // We take first one
|
||||
}
|
||||
}
|
||||
|
||||
@ -1299,6 +1299,7 @@ if (empty($reshook))
|
||||
}
|
||||
|
||||
// Now we create same links to contact than the ones found on origin object
|
||||
/* Useless, already into the create
|
||||
if (! empty($conf->global->MAIN_PROPAGATE_CONTACTS_FROM_ORIGIN))
|
||||
{
|
||||
$originforcontact = $object->origin;
|
||||
@ -1321,7 +1322,7 @@ if (empty($reshook))
|
||||
}
|
||||
}
|
||||
else dol_print_error($resqlcontact);
|
||||
}
|
||||
}*/
|
||||
|
||||
// Hooks
|
||||
$parameters = array('objFrom' => $srcobject);
|
||||
|
||||
@ -498,7 +498,8 @@ class Facture extends CommonInvoice
|
||||
foreach ($exp->linkedObjectsIds['commande'] as $key => $value)
|
||||
{
|
||||
$originforcontact = 'commande';
|
||||
$originidforcontact = $value->id;
|
||||
if (is_object($value)) $originidforcontact = $value->id;
|
||||
else $originidforcontact = $value;
|
||||
break; // We take first one
|
||||
}
|
||||
}
|
||||
|
||||
Loading…
Reference in New Issue
Block a user