fix trad : change adresse versus address

This commit is contained in:
Grand Philippe 2013-02-15 19:56:51 +01:00
parent 785e72d533
commit ab2b06117b
4 changed files with 7 additions and 7 deletions

View File

@ -520,7 +520,7 @@ class Contact extends CommonObject
$this->prenom = $obj->firstname; // TODO deprecated
$this->address = $obj->address;
$this->adresse = $obj->address; // TODO deprecated
//$this->adresse = $obj->address; // TODO deprecated
$this->cp = $obj->zip; // TODO deprecated
$this->zip = $obj->zip;
$this->ville = $obj->town; // TODO deprecated

View File

@ -1020,7 +1020,7 @@ class CMailFile
/**
* Return an address for SMTP protocol
*
* @param string $adresses Example: 'John Doe <john@doe.com>' or 'john@doe.com'
* @param string $address Example: 'John Doe <john@doe.com>' or 'john@doe.com'
* @param int $format 0=auto, 1=emails with <>, 2=emails without <>, 3=auto + label between "
* @param int $encode 1=Encode name to RFC2822
* @return string If format 0: '<john@doe.com>' or 'John Doe <john@doe.com>' or '=?UTF-8?B?Sm9obiBEb2U=?= <john@doe.com>'
@ -1028,13 +1028,13 @@ class CMailFile
* If format 2: 'john@doe.com'
* If format 3: '<john@doe.com>' or '"John Doe" <john@doe.com>' or '"=?UTF-8?B?Sm9obiBEb2U=?=" <john@doe.com>'
*/
function getValidAddress($adresses,$format,$encode='')
function getValidAddress($address,$format,$encode='')
{
global $conf;
$ret='';
$arrayaddress=explode(',',$adresses);
$arrayaddress=explode(',',$address);
// Boucle sur chaque composant de l'adresse
foreach($arrayaddress as $val)

View File

@ -964,7 +964,7 @@ abstract class CommonObject
*/
function setDeliveryAddress($id)
{
$fieldname = 'fk_adresse_livraison';
$fieldname = 'fk_delivery_address';
if ($this->element == 'delivery' || $this->element == 'shipping') $fieldname = 'fk_address';
$sql = "UPDATE ".MAIN_DB_PREFIX.$this->table_element." SET ".$fieldname." = ".$id;

View File

@ -675,7 +675,7 @@ class Expedition extends CommonObject
if (isset($this->socid)) $this->socid=trim($this->socid);
if (isset($this->fk_user_author)) $this->fk_user_author=trim($this->fk_user_author);
if (isset($this->fk_user_valid)) $this->fk_user_valid=trim($this->fk_user_valid);
if (isset($this->fk_adresse_livraison)) $this->fk_adresse_livraison=trim($this->fk_adresse_livraison);
if (isset($this->fk_delivery_address)) $this->fk_delivery_address=trim($this->fk_delivery_address);
if (isset($this->expedition_method_id)) $this->expedition_method_id=trim($this->expedition_method_id);
if (isset($this->tracking_number)) $this->tracking_number=trim($this->tracking_number);
if (isset($this->statut)) $this->statut=trim($this->statut);
@ -706,7 +706,7 @@ class Expedition extends CommonObject
$sql.= " fk_user_valid=".(isset($this->fk_user_valid)?$this->fk_user_valid:"null").",";
$sql.= " date_expedition=".(dol_strlen($this->date_expedition)!=0 ? "'".$this->db->idate($this->date_expedition)."'" : 'null').",";
$sql.= " date_delivery=".(dol_strlen($this->date_delivery)!=0 ? "'".$this->db->idate($this->date_delivery)."'" : 'null').",";
$sql.= " fk_address=".(isset($this->fk_adresse_livraison)?$this->fk_adresse_livraison:"null").",";
$sql.= " fk_address=".(isset($this->fk_delivery_address)?$this->fk_delivery_address:"null").",";
$sql.= " fk_expedition_methode=".((isset($this->expedition_method_id) && $this->expedition_method_id > 0)?$this->expedition_method_id:"null").",";
$sql.= " tracking_number=".(isset($this->tracking_number)?"'".$this->db->escape($this->tracking_number)."'":"null").",";
$sql.= " fk_statut=".(isset($this->statut)?$this->statut:"null").",";