Merge pull request #1973 from jfefe/patch-6

Avoid missing class error for fetch_thirdparty method
This commit is contained in:
Laurent Destailleur 2014-10-30 18:07:49 +01:00
commit aac24c887f

View File

@ -575,6 +575,9 @@ abstract class CommonObject
global $conf;
if (empty($this->socid)) return 0;
if (!class_exists('Societe'))
require_once DOL_DOCUMENT_ROOT.'/societe/class/societe.class.php';
$thirdparty = new Societe($this->db);
$result=$thirdparty->fetch($this->socid);