diff --git a/ChangeLog b/ChangeLog index 3225203c90c..efdc41b902a 100644 --- a/ChangeLog +++ b/ChangeLog @@ -20,6 +20,7 @@ Fix: [ bug #1043 ] Bad interventions ref numbering Fix: Mailing module : if an email is already in destinaires list all other email from selector was not inserted Fix: Localtaxes balance not showing Fix: Intervention box links to contracts id +Fix: Compatiblity with multicompany module ***** ChangeLog for 3.4 compared to 3.3.* ***** For users: diff --git a/htdocs/categories/class/categorie.class.php b/htdocs/categories/class/categorie.class.php index f8091fa8fa6..5a239f5eb21 100644 --- a/htdocs/categories/class/categorie.class.php +++ b/htdocs/categories/class/categorie.class.php @@ -5,6 +5,7 @@ * Copyright (C) 2006-2012 Regis Houssin * Copyright (C) 2006-2012 Laurent Destailleur * Copyright (C) 2007 Patrick Raguin + * Copyright (C) 2013 Juanjo Menent * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by @@ -520,8 +521,8 @@ class Categorie $sql = "SELECT fk_parent as id_parent, rowid as id_son"; $sql.= " FROM ".MAIN_DB_PREFIX."categorie"; $sql.= " WHERE fk_parent != 0"; - $sql.= " AND entity = ".$conf->entity; - + $sql.= " AND entity IN (".getEntity('category',1).")"; + dol_syslog(get_class($this)."::load_motherof sql=".$sql); $resql = $this->db->query($sql); if ($resql)