Changes

m
no edit summary
Line 1: Line 1: −
==Tips Tricks and Hacks about MultiEntity module==
+
= How to make your module compatible with MultiCompany =
 +
When you forge a SELECT SQL request, to have it compatible with the multicompany module you must add a criteria in the WHERE
 +
 
 +
"WHERE...AND entity IN (".getEntity($object->table_name).")";
 +
 
 +
If the object you read is a data that should never be shared with another entity (for example the accountancy), you must use
 +
 
 +
"WHERE...AND entity = ".((int) $conf->entity);
 +
 
 +
 
 +
=Tips Tricks and Hacks about MultiEntity module=
    
Permettre à un module externe d'ajouter son option de partage dans l'onglet options du module
 
Permettre à un module externe d'ajouter son option de partage dans l'onglet options du module