Changes

Line 163: Line 163:  
// Querying the llx_element_element table manually to get the link between the invoice and the linked intervention card (we want the id of the intervention card)
 
// Querying the llx_element_element table manually to get the link between the invoice and the linked intervention card (we want the id of the intervention card)
 
// fetchAny($columns, $table, $where='', $orderby='', $limitby='')
 
// fetchAny($columns, $table, $where='', $orderby='', $limitby='')
$eltrow = $customfields->fetchAny('*', MAIN_DB_PREFIX.'element_element', 'targettype="'.$object->element.'" and fk_target='.$object->id);
+
$eltrow = $customfields->fetchAny('*', MAIN_DB_PREFIX.'element_element', 'targettype="'.$object->element.'" and fk_target='.$object->id.' and sourcetype="fichinter"');
    
// Save the intervention's id
 
// Save the intervention's id
439

edits