From 68e42bc24e5817458445925bcbecf20839809be4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?C=C3=A9dric=20Salvador?= Date: Mon, 6 Jan 2014 11:28:41 +0100 Subject: [PATCH 1/2] fixed wrong thumbnails directory --- htdocs/product/class/product.class.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/htdocs/product/class/product.class.php b/htdocs/product/class/product.class.php index 748388ff99c..ecb90bb66ce 100644 --- a/htdocs/product/class/product.class.php +++ b/htdocs/product/class/product.class.php @@ -2946,7 +2946,7 @@ class Product extends CommonObject // Objet $obj=array(); $obj['photo']=$photo; - if ($photo_vignette && dol_is_file($dirthumb.$photo_vignette)) $obj['photo_vignette']=$dirthumb . $photo_vignette; + if ($photo_vignette && dol_is_file($dirthumb.$photo_vignette)) $obj['photo_vignette']='thumbs/' . $photo_vignette; else $obj['photo_vignette']=""; $tabobj[$nbphoto-1]=$obj; From e959568a1d75dae9f1d3acc96b7074ac781510fb Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?C=C3=A9dric=20Salvador?= Date: Wed, 8 Jan 2014 17:06:52 +0100 Subject: [PATCH 2/2] Added details to the contact created by create_individual --- htdocs/societe/class/societe.class.php | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/htdocs/societe/class/societe.class.php b/htdocs/societe/class/societe.class.php index 664be4b9a05..941a5445ff1 100644 --- a/htdocs/societe/class/societe.class.php +++ b/htdocs/societe/class/societe.class.php @@ -306,6 +306,12 @@ class Societe extends CommonObject $contact->socid = $this->id; // fk_soc $contact->statut = 1; $contact->priv = 0; + $contact->country_id = $this->country_id; + $contact->address = $this->address; + $contact->email = $this->email; + $contact->zip = $this->zip; + $contact->town = $this->town; + $contact->phone_pro = $this->phone; $result = $contact->create($user); if ($result < 0) { $this->error = $contact->error;