Merge pull request #698 from grandoc/develop
english language standardization
This commit is contained in:
commit
0a62832f06
@ -68,7 +68,7 @@ if ( ($action == 'update' && empty($_POST["cancel"]))
|
||||
dolibarr_set_const($db, "MAIN_INFO_SOCIETE_ADDRESS",$_POST["address"],'chaine',0,'',$conf->entity);
|
||||
dolibarr_set_const($db, "MAIN_INFO_SOCIETE_TOWN",$_POST["town"],'chaine',0,'',$conf->entity);
|
||||
dolibarr_set_const($db, "MAIN_INFO_SOCIETE_ZIP",$_POST["zipcode"],'chaine',0,'',$conf->entity);
|
||||
dolibarr_set_const($db, "MAIN_INFO_SOCIETE_DEPARTEMENT",$_POST["departement_id"],'chaine',0,'',$conf->entity);
|
||||
dolibarr_set_const($db, "MAIN_INFO_SOCIETE_STATE",$_POST["state_id"],'chaine',0,'',$conf->entity);
|
||||
dolibarr_set_const($db, "MAIN_MONNAIE",$_POST["currency"],'chaine',0,'',$conf->entity);
|
||||
dolibarr_set_const($db, "MAIN_INFO_SOCIETE_TEL",$_POST["tel"],'chaine',0,'',$conf->entity);
|
||||
dolibarr_set_const($db, "MAIN_INFO_SOCIETE_FAX",$_POST["fax"],'chaine',0,'',$conf->entity);
|
||||
@ -296,7 +296,7 @@ if ($action == 'edit' || $action == 'updateedit')
|
||||
|
||||
$var=!$var;
|
||||
print '<tr '.$bc[$var].'><td>'.$langs->trans("State").'</td><td>';
|
||||
$formcompany->select_departement($conf->global->MAIN_INFO_SOCIETE_DEPARTEMENT,$mysoc->country_code,'departement_id');
|
||||
$formcompany->select_departement($conf->global->MAIN_INFO_SOCIETE_STATE,$mysoc->country_code,'state_id');
|
||||
print '</td></tr>'."\n";
|
||||
|
||||
$var=!$var;
|
||||
@ -667,7 +667,7 @@ else
|
||||
|
||||
$var=!$var;
|
||||
print '<tr '.$bc[$var].'><td>'.$langs->trans("State").'</td><td>';
|
||||
if (! empty($conf->global->MAIN_INFO_SOCIETE_DEPARTEMENT)) print getState($conf->global->MAIN_INFO_SOCIETE_DEPARTEMENT);
|
||||
if (! empty($conf->global->MAIN_INFO_SOCIETE_STATE)) print getState($conf->global->MAIN_INFO_SOCIETE_STATE);
|
||||
else print ' ';
|
||||
print '</td></tr>';
|
||||
|
||||
|
||||
@ -41,8 +41,8 @@ $socname = GETPOST("socname",'alpha');
|
||||
$stcomm = GETPOST("stcomm",'int');
|
||||
$search_nom = GETPOST("search_nom");
|
||||
$search_zipcode = GETPOST("search_zipcode");
|
||||
$search_town = GETPOST("search_town");
|
||||
$search_departement = GETPOST("search_departement");
|
||||
$search_town = GETPOST("search_town");
|
||||
$search_state = GETPOST("search_state");
|
||||
$search_datec = GETPOST("search_datec");
|
||||
$search_categ = GETPOST("search_categ",'int');
|
||||
$catid = GETPOST("catid",'int');
|
||||
@ -195,7 +195,7 @@ if ($search_categ == -2) $sql.= " AND cs.fk_categorie IS NULL";
|
||||
if ($search_nom) $sql .= " AND s.nom LIKE '%".$db->escape(strtolower($search_nom))."%'";
|
||||
if ($search_zipcode) $sql .= " AND s.zip LIKE '".$db->escape(strtolower($search_zipcode))."%'";
|
||||
if ($search_town) $sql .= " AND s.town LIKE '%".$db->escape(strtolower($search_town))."%'";
|
||||
if ($search_departement) $sql .= " AND d.nom LIKE '%".$db->escape(strtolower($search_departement))."%'";
|
||||
if ($search_state) $sql .= " AND d.nom LIKE '%".$db->escape(strtolower($search_state))."%'";
|
||||
if ($search_datec) $sql .= " AND s.datec LIKE '%".$db->escape($search_datec)."%'";
|
||||
// Insert levels filters
|
||||
if ($search_levels)
|
||||
@ -318,7 +318,7 @@ if ($resql)
|
||||
print '<input type="text" class="flat" name="search_town" size="10" value="'.$search_town.'">';
|
||||
print '</td>';
|
||||
print '<td class="liste_titre" align="center">';
|
||||
print '<input type="text" class="flat" name="search_departement" size="10" value="'.$search_departement.'">';
|
||||
print '<input type="text" class="flat" name="search_state" size="10" value="'.$search_state.'">';
|
||||
print '</td>';
|
||||
print '<td align="center" class="liste_titre">';
|
||||
print '<input class="flat" type="text" size="10" name="search_datec" value="'.$search_datec.'">';
|
||||
|
||||
@ -65,7 +65,7 @@ if ($action == 'update' && ! $_POST["cancel"])
|
||||
$account->domiciliation = trim($_POST["domiciliation"]);
|
||||
$account->proprio = trim($_POST["proprio"]);
|
||||
$account->owner_address = trim($_POST["owner_address"]);
|
||||
$account->fk_departement = trim($_POST["fk_departement"]);
|
||||
$account->state_id = trim($_POST["state_id"]);
|
||||
//$account->country_id = trim($_POST["country_id"]); // We do not change this.
|
||||
|
||||
if ($account->id)
|
||||
|
||||
@ -62,10 +62,6 @@ class Account extends CommonObject
|
||||
var $proprio;
|
||||
var $owner_address;
|
||||
|
||||
|
||||
var $fk_departement; // deprecated
|
||||
var $departement_code; // deprecated
|
||||
var $departement; // deprecated
|
||||
var $state_id;
|
||||
var $state_code;
|
||||
var $state;
|
||||
@ -351,7 +347,7 @@ class Account extends CommonObject
|
||||
// Clean parameters
|
||||
if (! $this->min_allowed) $this->min_allowed=0;
|
||||
if (! $this->min_desired) $this->min_desired=0;
|
||||
$this->state_id = ($this->state_id?$this->state_id:$this->fk_departement);
|
||||
$this->state_id = ($this->state_id?$this->state_id:$this->state_id);
|
||||
$this->country_id = ($this->country_id?$this->country_id:$this->country_id);
|
||||
|
||||
// Check parameters
|
||||
@ -390,7 +386,7 @@ class Account extends CommonObject
|
||||
$sql.= ", min_allowed";
|
||||
$sql.= ", min_desired";
|
||||
$sql.= ", comment";
|
||||
$sql.= ", fk_departement";
|
||||
$sql.= ", state_id";
|
||||
$sql.= ", fk_pays";
|
||||
$sql.= ") VALUES (";
|
||||
$sql.= "'".$this->db->idate($now)."'";
|
||||
@ -475,7 +471,7 @@ class Account extends CommonObject
|
||||
// Clean parameters
|
||||
if (! $this->min_allowed) $this->min_allowed=0;
|
||||
if (! $this->min_desired) $this->min_desired=0;
|
||||
$this->state_id = ($this->state_id?$this->state_id:$this->fk_departement);
|
||||
$this->state_id = ($this->state_id?$this->state_id:$this->state_id);
|
||||
$this->country_id = ($this->country_id?$this->country_id:$this->country_id);
|
||||
|
||||
// Check parameters
|
||||
@ -510,7 +506,7 @@ class Account extends CommonObject
|
||||
$sql.= ",min_desired = '".price2num($this->min_desired)."'";
|
||||
$sql.= ",comment = '".$this->db->escape($this->comment)."'";
|
||||
|
||||
$sql.= ",fk_departement = ".($this->state_id>0?"'".$this->state_id."'":"null");
|
||||
$sql.= ",state_id = ".($this->state_id>0?"'".$this->state_id."'":"null");
|
||||
$sql.= ",fk_pays = ".$this->country_id;
|
||||
|
||||
$sql.= " WHERE rowid = ".$this->id;
|
||||
@ -542,7 +538,7 @@ class Account extends CommonObject
|
||||
global $conf,$langs;
|
||||
|
||||
// Clean parameters
|
||||
$this->state_id = ($this->state_id?$this->state_id:$this->fk_departement);
|
||||
$this->state_id = ($this->state_id?$this->state_id:$this->state_id);
|
||||
$this->country_id = ($this->country_id?$this->country_id:$this->country_id);
|
||||
|
||||
// Chargement librairie pour acces fonction controle RIB
|
||||
@ -568,7 +564,7 @@ class Account extends CommonObject
|
||||
$sql.= ",domiciliation='".$this->db->escape($this->domiciliation)."'";
|
||||
$sql.= ",proprio = '".$this->db->escape($this->proprio)."'";
|
||||
$sql.= ",owner_address = '".$this->db->escape($this->owner_address)."'";
|
||||
$sql.= ",fk_departement = ".($this->state_id>0?"'".$this->state_id."'":"null");
|
||||
$sql.= ",state_id = ".($this->state_id>0?"'".$this->state_id."'":"null");
|
||||
$sql.= ",fk_pays = ".$this->country_id;
|
||||
$sql.= " WHERE rowid = ".$this->id;
|
||||
$sql.= " AND entity = ".$conf->entity;
|
||||
@ -608,14 +604,14 @@ class Account extends CommonObject
|
||||
|
||||
$sql = "SELECT ba.rowid, ba.ref, ba.label, ba.bank, ba.number, ba.courant, ba.clos, ba.rappro, ba.url,";
|
||||
$sql.= " ba.code_banque, ba.code_guichet, ba.cle_rib, ba.bic, ba.iban_prefix as iban,";
|
||||
$sql.= " ba.domiciliation, ba.proprio, ba.owner_address, ba.fk_departement, ba.fk_pays as country_id,";
|
||||
$sql.= " ba.domiciliation, ba.proprio, ba.owner_address, ba.state_id, ba.fk_pays as country_id,";
|
||||
$sql.= " ba.account_number, ba.currency_code,";
|
||||
$sql.= " ba.min_allowed, ba.min_desired, ba.comment,";
|
||||
$sql.= ' p.code as country_code, p.libelle as country,';
|
||||
$sql.= ' d.code_departement as state_code, d.nom as state';
|
||||
$sql.= " FROM ".MAIN_DB_PREFIX."bank_account as ba";
|
||||
$sql.= ' LEFT JOIN '.MAIN_DB_PREFIX.'c_pays as p ON ba.fk_pays = p.rowid';
|
||||
$sql.= ' LEFT JOIN '.MAIN_DB_PREFIX.'c_departements as d ON ba.fk_departement = d.rowid';
|
||||
$sql.= ' LEFT JOIN '.MAIN_DB_PREFIX.'c_departements as d ON ba.state_id = d.rowid';
|
||||
$sql.= " WHERE entity = ".$conf->entity;
|
||||
if ($id) $sql.= " AND ba.rowid = ".$id;
|
||||
if ($ref) $sql.= " AND ba.ref = '".$this->db->escape($ref)."'";
|
||||
@ -650,10 +646,7 @@ class Account extends CommonObject
|
||||
$this->proprio = $obj->proprio;
|
||||
$this->owner_address = $obj->owner_address;
|
||||
|
||||
$this->fk_departement = $obj->fk_departement; // deprecated
|
||||
$this->departement_code= $obj->state_code; // deprecated
|
||||
$this->departement = $obj->state; // deprecated
|
||||
$this->state_id = $obj->fk_departement;
|
||||
$this->state_id = $obj->state_id;
|
||||
$this->state_code = $obj->state_code;
|
||||
$this->state = $obj->state;
|
||||
|
||||
|
||||
@ -69,7 +69,7 @@ if ($_POST["action"] == 'add')
|
||||
|
||||
$account->currency_code = trim($_POST["account_currency_code"]);
|
||||
|
||||
$account->fk_departement = $_POST["account_departement_id"];
|
||||
$account->state_id = $_POST["account_departement_id"];
|
||||
$account->country_id = $_POST["account_country_id"];
|
||||
|
||||
$account->min_allowed = $_POST["account_min_allowed"];
|
||||
@ -140,7 +140,7 @@ if ($_POST["action"] == 'update' && ! $_POST["cancel"])
|
||||
|
||||
$account->currency_code = trim($_POST["account_currency_code"]);
|
||||
|
||||
$account->state_id = $_POST["account_departement_id"];
|
||||
$account->state_id = $_POST["account_state_id"];
|
||||
$account->country_id = $_POST["account_country_id"];
|
||||
|
||||
$account->min_allowed = $_POST["account_min_allowed"];
|
||||
@ -282,7 +282,7 @@ if ($action == 'create')
|
||||
print '<tr><td>'.$langs->trans('State').'</td><td colspan="3">';
|
||||
if ($selectedcode)
|
||||
{
|
||||
$formcompany->select_departement(isset($_POST["account_departement_id"])?$_POST["account_departement_id"]:'',$selectedcode,'account_departement_id');
|
||||
$formcompany->select_departement(isset($_POST["account_state_id"])?$_POST["account_state_id"]:'',$selectedcode,'account_state_id');
|
||||
}
|
||||
else
|
||||
{
|
||||
@ -555,7 +555,7 @@ else
|
||||
print '<tr><td>'.$langs->trans('State').'</td><td colspan="3">';
|
||||
if ($selectedcode)
|
||||
{
|
||||
print $formcompany->select_state(isset($_POST["account_departement_id"])?$_POST["account_departement_id"]:$account->fk_departement,$selectedcode,'account_departement_id');
|
||||
print $formcompany->select_state(isset($_POST["account_state_id"])?$_POST["account_state_id"]:$account->state_id,$selectedcode,'account_state_id');
|
||||
}
|
||||
else
|
||||
{
|
||||
|
||||
@ -301,9 +301,9 @@ if ($action == 'create')
|
||||
|
||||
// Zip / Town
|
||||
print '<tr><td>'.$langs->trans("Zip").' / '.$langs->trans("Town").'</td><td>';
|
||||
print $formcompany->select_ziptown((isset($_POST["zipcode"])?$_POST["zipcode"]:$don->zip),'zipcode',array('town','selectcountry_id','departement_id'),6);
|
||||
print $formcompany->select_ziptown((isset($_POST["zipcode"])?$_POST["zipcode"]:$don->zip),'zipcode',array('town','selectcountry_id','state_id'),6);
|
||||
print ' ';
|
||||
print $formcompany->select_ziptown((isset($_POST["town"])?$_POST["town"]:$don->town),'town',array('zipcode','selectcountry_id','departement_id'));
|
||||
print $formcompany->select_ziptown((isset($_POST["town"])?$_POST["town"]:$don->town),'town',array('zipcode','selectcountry_id','state_id'));
|
||||
print '</tr>';
|
||||
|
||||
print "<tr>".'<td>'.$langs->trans("Country").'</td><td><input type="text" name="country" value="'.$_POST["country"].'" size="40"></td></tr>';
|
||||
@ -391,9 +391,9 @@ if (! empty($id) && $action == 'edit')
|
||||
|
||||
// Zip / Town
|
||||
print '<tr><td>'.$langs->trans("Zip").' / '.$langs->trans("Town").'</td><td>';
|
||||
print $formcompany->select_ziptown((isset($_POST["zipcode"])?$_POST["zipcode"]:$don->zip),'zipcode',array('town','selectcountry_id','departement_id'),6);
|
||||
print $formcompany->select_ziptown((isset($_POST["zipcode"])?$_POST["zipcode"]:$don->zip),'zipcode',array('town','selectcountry_id','state_id'),6);
|
||||
print ' ';
|
||||
print $formcompany->select_ziptown((isset($_POST["town"])?$_POST["town"]:$don->town),'town',array('zipcode','selectcountry_id','departement_id'));
|
||||
print $formcompany->select_ziptown((isset($_POST["town"])?$_POST["town"]:$don->town),'town',array('zipcode','selectcountry_id','state_id'));
|
||||
print '</tr>';
|
||||
|
||||
print "<tr>".'<td>'.$langs->trans("Country").'</td><td><input type="text" name="country" size="40" value="'.$don->country.'"></td></tr>';
|
||||
|
||||
@ -35,6 +35,7 @@ UPDATE llx_const set name='MAIN_INFO_SOCIETE_ADDRESS' where name='MAIN_INFO_SOCI
|
||||
UPDATE llx_const set name='MAIN_INFO_SOCIETE_TOWN' where name='MAIN_INFO_SOCIETE_VILLE';
|
||||
UPDATE llx_const set name='MAIN_INFO_SOCIETE_ZIP' where name='MAIN_INFO_SOCIETE_CP';
|
||||
UPDATE llx_const set name='MAIN_INFO_SOCIETE_COUNTRY' where name='MAIN_INFO_SOCIETE_PAYS';
|
||||
UPDATE llx_const set name='MAIN_INFO_SOCIETE_STATE' where name='MAIN_INFO_SOCIETE_DEPARTEMENT';
|
||||
|
||||
ALTER TABLE llx_user add COLUMN fk_user integer;
|
||||
|
||||
@ -72,6 +73,7 @@ alter table llx_socpeople CHANGE COLUMN name lastname varchar(50);
|
||||
alter table llx_socpeople CHANGE COLUMN ville town text;
|
||||
alter table llx_socpeople CHANGE COLUMN cp zip varchar(10);
|
||||
alter table llx_bank_account CHANGE COLUMN adresse_proprio owner_address text;
|
||||
alter table llx_bank_account CHANGE COLUMN fk_departement state_id varchar(50);
|
||||
alter table llx_societe_rib CHANGE COLUMN adresse_proprio owner_address text;
|
||||
alter table llx_societe_address CHANGE COLUMN ville town text;
|
||||
alter table llx_societe_address CHANGE COLUMN cp zip varchar(10);
|
||||
|
||||
Loading…
Reference in New Issue
Block a user