implement cache managed by current object
This commit is contained in:
parent
ad145c94ca
commit
59fec7d094
@ -3779,6 +3779,10 @@ abstract class CommonObject
|
||||
{
|
||||
global $conf, $hookmanager, $action;
|
||||
|
||||
// important for pdf generation time reduction
|
||||
// this boolean is true if $this->linkedObjects has already been loaded with all objects linked without filter
|
||||
if ($this->linkedObjectsFullLoaded) return 1;
|
||||
|
||||
$this->linkedObjectsIds = array();
|
||||
$this->linkedObjects = array();
|
||||
|
||||
|
||||
@ -2282,9 +2282,7 @@ function pdf_getLinkedObjects(&$object, $outputlangs)
|
||||
|
||||
$linkedobjects = array();
|
||||
|
||||
if (empty($object->linkedObjectsFullLoaded)) {
|
||||
$object->fetchObjectLinked();
|
||||
}
|
||||
$object->fetchObjectLinked();
|
||||
|
||||
foreach ($object->linkedObjects as $objecttype => $objects) {
|
||||
if ($objecttype == 'facture') {
|
||||
|
||||
Loading…
Reference in New Issue
Block a user