diff --git a/htdocs/core/modules/modCategorie.class.php b/htdocs/core/modules/modCategorie.class.php index a640a8edb882560708e30f5fa2b4a99696e78a55..ab8ac1cc8e157f55ea4651b3d54ae94b943e986d 100644 --- a/htdocs/core/modules/modCategorie.class.php +++ b/htdocs/core/modules/modCategorie.class.php @@ -1,7 +1,7 @@ <?php /* Copyright (C) 2005 Matthieu Valleton <mv@seeschloss.org> * Copyright (C) 2005-2014 Laurent Destailleur <eldy@users.sourceforge.net> - * Copyright (C) 2012 Juanjo Menent <jmenent@2byte.es> + * Copyright (C) 2012-2016 Juanjo Menent <jmenent@2byte.es> * * 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 @@ -302,6 +302,7 @@ class modCategorie extends DolibarrModules $this->export_sql_end[$r] = ' FROM ' . MAIN_DB_PREFIX . 'categorie as u, '.MAIN_DB_PREFIX . 'categorie_contact as cp, '.MAIN_DB_PREFIX . 'socpeople as p'; $this->export_sql_end[$r] .= ' LEFT JOIN ' . MAIN_DB_PREFIX . 'c_country as country ON p.fk_pays = country.rowid'; $this->export_sql_end[$r] .= ' LEFT JOIN ' . MAIN_DB_PREFIX . 'societe as s ON s.rowid = p.fk_soc'; + $this->export_sql_end[$r] .= ' LEFT JOIN ' . MAIN_DB_PREFIX . 'socpeople_extrafields as extra ON extra.fk_object = p.rowid'; $this->export_sql_end[$r] .= ' WHERE u.rowid = cp.fk_categorie AND cp.fk_socpeople = p.rowid AND u.entity IN ('.getEntity('category',1).')'; $this->export_sql_end[$r] .= ' AND u.type = 4'; // contact categories