439
edits
(Added llx_element_element php code example) |
(→Linking Dolibarr objects from two different modules: fixed a mistake) |
||
| 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', 'fk_target='.$object->id); | $eltrow = $customfields->fetchAny('*', MAIN_DB_PREFIX.'element_element', 'targettype="'.$object->element.'" and fk_target='.$object->id); | ||
// Save the intervention's id | // Save the intervention's id | ||
edits