Ver código fonte

english language standardization

Grand Philippe 12 anos atrás
pai
commit
dfae543d5e

+ 2 - 2
htdocs/adherents/cartes/carte.php

@@ -62,7 +62,7 @@ if ((! empty($foruserid) || ! empty($foruserlogin) || ! empty($mode)) && ! $mesg
 
     // requete en prenant que les adherents a jour de cotisation
     $sql = "SELECT d.rowid, d.firstname, d.lastname, d.login, d.societe as company, d.datefin,";
-    $sql.= " d.address, d.cp as zip, d.town, d.naiss, d.email, d.photo,";
+    $sql.= " d.address, d.zip, d.town, d.naiss, d.email, d.photo,";
     $sql.= " t.libelle as type,";
     $sql.= " p.code as country_code, p.libelle as country";
     $sql.= " FROM ".MAIN_DB_PREFIX."adherent_type as t, ".MAIN_DB_PREFIX."adherent as d";
@@ -110,7 +110,7 @@ if ((! empty($foruserid) || ! empty($foruserlogin) || ! empty($mode)) && ! $mesg
             '%SERVER%'=>"http://".$_SERVER["SERVER_NAME"]."/",	// deprecated
             // For backward compatibility
             '%SOCIETE%'=>$objp->company,
-            '%CP%'=>$objp->zip,
+            '%ZIP%'=>$objp->zip,
             '%PAYS%'=>$objp->country,
             '%ANNEE%'=>$year,
             '%SERVEUR%'=>"http://".$_SERVER["SERVER_NAME"]."/"	// deprecated

+ 4 - 6
htdocs/adherents/class/adherent.class.php

@@ -50,7 +50,6 @@ class Adherent extends CommonObject
     var $pass;
     var $societe;
     var $address;
-    var $cp;
     var $zip;
     var $town;
 
@@ -227,7 +226,7 @@ class Adherent extends CommonObject
 				// For backward compatibility
 				'%INFOS%'=>$msgishtml?dol_htmlentitiesbr($infos):$infos,
 				'%SOCIETE%'=>$msgishtml?dol_htmlentitiesbr($this->societe):$this->societe,
-				'%CP%'=>$msgishtml?dol_htmlentitiesbr($this->zip):$this->zip,
+				'%ZIP%'=>$msgishtml?dol_htmlentitiesbr($this->zip):$this->zip,
 				'%PAYS%'=>$msgishtml?dol_htmlentitiesbr($this->country):$this->country,
 		);
 
@@ -397,7 +396,7 @@ class Adherent extends CommonObject
 		$this->lastname=trim($this->lastname)?trim($this->lastname):trim($this->lastname);
 		$this->firstname=trim($this->firstname)?trim($this->firstname):trim($this->firstname);
 		$this->address=($this->address?$this->address:$this->address);
-		$this->zip=($this->zip?$this->zip:$this->cp);
+		$this->zip=($this->zip?$this->zip:$this->zip);
 		$this->town=($this->town?$this->town:$this->town);
 		$this->country_id=($this->country_id > 0?$this->country_id:$this->fk_pays);
 		$this->state_id=($this->state_id > 0?$this->state_id:$this->fk_departement);
@@ -1009,7 +1008,7 @@ class Adherent extends CommonObject
     {
         global $langs;
 
-        $sql = "SELECT d.rowid, d.civilite, d.firstname, d.lastname, d.societe, d.fk_soc, d.statut, d.public, d.address, d.cp as zip, d.town, d.note,";
+        $sql = "SELECT d.rowid, d.civilite, d.firstname, d.lastname, d.societe, d.fk_soc, d.statut, d.public, d.address, d.zip, d.town, d.note,";
         $sql.= " d.email, d.phone, d.phone_perso, d.phone_mobile, d.login, d.pass,";
         $sql.= " d.photo, d.fk_adherent_type, d.morphy, d.entity,";
         $sql.= " d.datec as datec,";
@@ -1054,7 +1053,6 @@ class Adherent extends CommonObject
                 $this->societe			= $obj->societe;
                 $this->fk_soc			= $obj->fk_soc;
                 $this->address			= $obj->address;
-                $this->cp				= $obj->zip;		// deprecated
                 $this->zip				= $obj->zip;
                 $this->town				= $obj->town;
 
@@ -1811,7 +1809,7 @@ class Adherent extends CommonObject
         if ($this->pass && ! empty($conf->global->LDAP_MEMBER_FIELD_PASSWORD))    $info[$conf->global->LDAP_MEMBER_FIELD_PASSWORD] = $this->pass;	// this->pass = mot de passe non crypte
         if ($this->poste && ! empty($conf->global->LDAP_MEMBER_FIELD_TITLE))      $info[$conf->global->LDAP_MEMBER_FIELD_TITLE] = $this->poste;
         if ($this->address && ! empty($conf->global->LDAP_MEMBER_FIELD_ADDRESS))  $info[$conf->global->LDAP_MEMBER_FIELD_ADDRESS] = $this->address;
-        if ($this->cp && ! empty($conf->global->LDAP_MEMBER_FIELD_ZIP))           $info[$conf->global->LDAP_MEMBER_FIELD_ZIP] = $this->cp;
+        if ($this->zip && ! empty($conf->global->LDAP_MEMBER_FIELD_ZIP))           $info[$conf->global->LDAP_MEMBER_FIELD_ZIP] = $this->zip;
         if ($this->town && ! empty($conf->global->LDAP_MEMBER_FIELD_TOWN))        $info[$conf->global->LDAP_MEMBER_FIELD_TOWN] = $this->town;
         if ($this->country_code && ! empty($conf->global->LDAP_MEMBER_FIELD_COUNTRY))     $info[$conf->global->LDAP_MEMBER_FIELD_COUNTRY] = $this->country_code;
         if ($this->email && ! empty($conf->global->LDAP_MEMBER_FIELD_MAIL))       $info[$conf->global->LDAP_MEMBER_FIELD_MAIL] = $this->email;

+ 0 - 2
htdocs/adherents/fiche.php

@@ -258,7 +258,6 @@ if ($action == 'update' && ! $_POST["cancel"] && $user->rights->adherent->creer)
 
 		$object->societe     = trim($_POST["societe"]);
 		$object->address     = trim($_POST["address"]);
-		$object->cp          = trim($_POST["zipcode"]);    // deprecated
 		$object->zip         = trim($_POST["zipcode"]);
 		$object->town        = trim($_POST["town"]);
 		$object->state_id    = $_POST["departement_id"];
@@ -435,7 +434,6 @@ if ($action == 'add' && $user->rights->adherent->creer)
 	$object->lastname    = $lastname;
 	$object->societe     = $societe;
 	$object->address     = $address;
-	$object->cp          = $zip;     // deprecated
 	$object->zip         = $zip;
 	$object->town        = $town;
 	$object->fk_departement = $state_id;

+ 1 - 0
htdocs/install/mysql/migration/3.3.0-3.4.0.sql

@@ -53,6 +53,7 @@ alter table llx_adherent CHANGE COLUMN adresse address text;
 alter table llx_adherent CHANGE COLUMN nom lastname varchar(50);
 alter table llx_adherent CHANGE COLUMN prenom firstname varchar(50);
 alter table llx_adherent CHANGE COLUMN ville town text;
+alter table llx_adherent CHANGE COLUMN cp zip varchar(10);
 alter table llx_mailing_cibles CHANGE COLUMN nom lastname varchar(50);
 alter table llx_mailing_cibles CHANGE COLUMN prenom firstname varchar(50);
 alter table llx_user     CHANGE COLUMN name lastname varchar(50);