Clean libelle into label

This commit is contained in:
Laurent Destailleur 2023-04-08 15:08:55 +02:00
parent 6aae32e39e
commit a4a014cfd5
50 changed files with 211 additions and 216 deletions

View File

@ -816,8 +816,8 @@ class AccountancyExport
// Keep correct quadra named field instead of anon filler libelle_ecriture2 is 30 char not 32 !!!! // Keep correct quadra named field instead of anon filler libelle_ecriture2 is 30 char not 32 !!!!
// as we use utf8, we must remove accent to have only one ascii char instead of utf8 2 chars for specials that report wrong line size that will exceed import format spec // as we use utf8, we must remove accent to have only one ascii char instead of utf8 2 chars for specials that report wrong line size that will exceed import format spec
// TODO: we should filter more than only accent to avoid wrong line size // TODO: we should filter more than only accent to avoid wrong line size
// TODO: remove invoice number doc_ref in libelle, // TODO: remove invoice number doc_ref in label,
// TODO: we should offer an option for customer to build the libelle using invoice number / name / date in accounting software // TODO: we should offer an option for customer to build the label using invoice number / name / date in accounting software
//$Tab['libelle_ecriture2'] = str_pad(self::trunc($data->doc_ref . ' ' . $data->label_operation, 30), 30); //$Tab['libelle_ecriture2'] = str_pad(self::trunc($data->doc_ref . ' ' . $data->label_operation, 30), 30);
$Tab['libelle_ecriture2'] = str_pad(self::trunc($data->label_operation, 30), 30); $Tab['libelle_ecriture2'] = str_pad(self::trunc($data->label_operation, 30), 30);
$Tab['codetva'] = str_repeat(' ', 2); $Tab['codetva'] = str_repeat(' ', 2);

View File

@ -684,9 +684,9 @@ class AccountingAccount extends CommonObject
} }
/** /**
* Retourne le libelle du statut d'un user (actif, inactif) * Return the label of the status
* *
* @param int $mode 0=libelle long, 1=libelle court, 2=Picto + Libelle court, 3=Picto, 4=Picto + Libelle long, 5=Libelle court + Picto * @param int $mode 0=long label, 1=short label, 2=Picto + short label, 3=Picto, 4=Picto + long label, 5=Short label + Picto, 6=Long label + Picto
* @return string Label of status * @return string Label of status
*/ */
public function getLibStatut($mode = 0) public function getLibStatut($mode = 0)
@ -696,10 +696,10 @@ class AccountingAccount extends CommonObject
// phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps // phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps
/** /**
* Renvoi le libelle d'un statut donne * Return the label of a given status
* *
* @param int $status Id status * @param int $status Id status
* @param int $mode 0=libelle long, 1=libelle court, 2=Picto + Libelle court, 3=Picto, 4=Picto + Libelle long, 5=Libelle court + Picto * @param int $mode 0=long label, 1=short label, 2=Picto + short label, 3=Picto, 4=Picto + long label, 5=Short label + Picto, 6=Long label + Picto
* @return string Label of status * @return string Label of status
*/ */
public function LibStatut($status, $mode = 0) public function LibStatut($status, $mode = 0)

View File

@ -312,10 +312,10 @@ class AccountingJournal extends CommonObject
} }
/** /**
* Retourne le libelle du statut d'un user (actif, inactif) * Return the label of the status
* *
* @param int $mode 0=libelle long, 1=libelle court * @param int $mode 0=long label, 1=short label, 2=Picto + short label, 3=Picto, 4=Picto + long label, 5=Short label + Picto, 6=Long label + Picto
* @return string Label of type * @return string Label of status
*/ */
public function getLibType($mode = 0) public function getLibType($mode = 0)
{ {
@ -327,7 +327,7 @@ class AccountingJournal extends CommonObject
* Return type of an accounting journal * Return type of an accounting journal
* *
* @param int $nature Id type * @param int $nature Id type
* @param int $mode 0=libelle long, 1=libelle court * @param int $mode 0=label long, 1=label short
* @return string Label of type * @return string Label of type
*/ */
public function LibType($nature, $mode = 0) public function LibType($nature, $mode = 0)

View File

@ -103,7 +103,7 @@ if (!GETPOSTISSET('date_startmonth') && (empty($date_start) || empty($date_end))
$date_end = dol_get_last_day($pastmonthyear, $pastmonth, false); $date_end = dol_get_last_day($pastmonthyear, $pastmonth, false);
} }
$sql = "SELECT f.rowid, f.ref as ref, f.type, f.datef as df, f.libelle,f.ref_supplier, f.date_lim_reglement as dlr, f.close_code,"; $sql = "SELECT f.rowid, f.ref as ref, f.type, f.datef as df, f.libelle as label, f.ref_supplier, f.date_lim_reglement as dlr, f.close_code,";
$sql .= " fd.rowid as fdid, fd.description, fd.product_type, fd.total_ht, fd.tva as total_tva, fd.total_localtax1, fd.total_localtax2, fd.tva_tx, fd.total_ttc, fd.vat_src_code, fd.info_bits,"; $sql .= " fd.rowid as fdid, fd.description, fd.product_type, fd.total_ht, fd.tva as total_tva, fd.total_localtax1, fd.total_localtax2, fd.tva_tx, fd.total_ttc, fd.vat_src_code, fd.info_bits,";
$sql .= " s.rowid as socid, s.nom as name, s.fournisseur, s.code_client, s.code_fournisseur,"; $sql .= " s.rowid as socid, s.nom as name, s.fournisseur, s.code_client, s.code_fournisseur,";
if (!empty($conf->global->MAIN_COMPANY_PERENTITY_SHARED)) { if (!empty($conf->global->MAIN_COMPANY_PERENTITY_SHARED)) {

View File

@ -452,10 +452,10 @@ class Subscription extends CommonObject
/** /**
* Retourne le libelle du statut d'une adhesion * Return the label of the status
* *
* @param int $mode 0=libelle long, 1=libelle court, 2=Picto + Libelle court, 3=Picto, 4=Picto + Libelle long, 5=Libelle court + Picto * @param int $mode 0=long label, 1=short label, 2=Picto + short label, 3=Picto, 4=Picto + long label, 5=Short label + Picto, 6=Long label + Picto
* @return string Label * @return string Label of status
*/ */
public function getLibStatut($mode = 0) public function getLibStatut($mode = 0)
{ {
@ -464,16 +464,19 @@ class Subscription extends CommonObject
// phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps // phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps
/** /**
* Renvoi le libelle d'un statut donne * Return the label of a given status
* *
* @param int $status Id status * @param int $status Id status
* @return string Label * @param int $mode 0=long label, 1=short label, 2=Picto + short label, 3=Picto, 4=Picto + long label, 5=Short label + Picto, 6=Long label + Picto
* @return string Label of status
*/ */
public function LibStatut($status) public function LibStatut($status, $mode = 0)
{ {
// phpcs:enable // phpcs:enable
global $langs; global $langs;
$langs->load("members");
//$langs->load("members");
return ''; return '';
} }

View File

@ -268,10 +268,10 @@ class Bookmark extends CommonObject
} }
/** /**
* Return label of contact status * Return the label of the status
* *
* @param int $mode 0=libelle long, 1=libelle court, 2=Picto + Libelle court, 3=Picto, 4=Picto + Libelle long, 5=Libelle court + Picto * @param int $mode 0=long label, 1=short label, 2=Picto + short label, 3=Picto, 4=Picto + long label, 5=Short label + Picto, 6=Long label + Picto
* @return string Label of contact status * @return string Label of status
*/ */
public function getLibStatut($mode) public function getLibStatut($mode)
{ {

View File

@ -2589,10 +2589,10 @@ class AccountLine extends CommonObjectLine
/** /**
* Return label of status (activity, closed) * Return the label of the status
* *
* @param int $mode 0=libelle long, 1=libelle court, 2=Picto + Libelle court, 3=Picto, 4=Picto + Libelle long * @param int $mode 0=long label, 1=short label, 2=Picto + short label, 3=Picto, 4=Picto + long label, 5=Short label + Picto, 6=Long label + Picto
* @return string Libelle * @return string Label of status
*/ */
public function getLibStatut($mode = 0) public function getLibStatut($mode = 0)
{ {
@ -2601,11 +2601,11 @@ class AccountLine extends CommonObjectLine
// phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps // phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps
/** /**
* Renvoi le libelle d'un statut donne * Return the label of a given status
* *
* @param int $status Id statut * @param int $status Id status
* @param int $mode 0=libelle long, 1=libelle court, 2=Picto + Libelle court, 3=Picto, 4=Picto + Libelle long, 5=Libelle court + Picto * @param int $mode 0=long label, 1=short label, 2=Picto + short label, 3=Picto, 4=Picto + long label, 5=Short label + Picto, 6=Long label + Picto
* @return string Libelle du statut * @return string Label of status
*/ */
public function LibStatut($status, $mode = 0) public function LibStatut($status, $mode = 0)
{ {

View File

@ -603,10 +603,10 @@ class PaymentVarious extends CommonObject
/** /**
* Retourne le libelle du statut * Return the label of the status
* *
* @param int $mode 0=long label, 1=short label, 2=Picto + short label, 3=Picto, 4=Picto + long label, 5=Short label + Picto * @param int $mode 0=long label, 1=short label, 2=Picto + short label, 3=Picto, 4=Picto + long label, 5=Short label + Picto, 6=Long label + Picto
* @return string Libelle * @return string Label of status
*/ */
public function getLibStatut($mode = 0) public function getLibStatut($mode = 0)
{ {
@ -615,11 +615,11 @@ class PaymentVarious extends CommonObject
// phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps // phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps
/** /**
* Renvoi le libelle d'un statut donne * Return the label of a given status
* *
* @param int $status Id status * @param int $status Id status
* @param int $mode 0=long label, 1=short label, 2=Picto + short label, 3=Picto, 4=Picto + long label, 5=Short label + Picto * @param int $mode 0=long label, 1=short label, 2=Picto + short label, 3=Picto, 4=Picto + long label, 5=Short label + Picto, 6=Long label + Picto
* @return string Libelle * @return string Label of status
*/ */
public function LibStatut($status, $mode = 0) public function LibStatut($status, $mode = 0)
{ {

View File

@ -338,10 +338,10 @@ class Deplacement extends CommonObject
/** /**
* Retourne le libelle du statut * Return the label of the status
* *
* @param int $mode 0=long label, 1=short label, 2=Picto + short label, 3=Picto, 4=Picto + long label, 5=Short label + Picto * @param int $mode 0=long label, 1=short label, 2=Picto + short label, 3=Picto, 4=Picto + long label, 5=Short label + Picto, 6=Long label + Picto
* @return string Libelle * @return string Label of status
*/ */
public function getLibStatut($mode = 0) public function getLibStatut($mode = 0)
{ {
@ -350,11 +350,11 @@ class Deplacement extends CommonObject
// phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps // phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps
/** /**
* Renvoi le libelle d'un statut donne * Return the label of a given status
* *
* @param int $status Id status * @param int $status Id status
* @param int $mode 0=long label, 1=short label, 2=Picto + short label, 3=Picto, 4=Picto + long label, 5=Short label + Picto * @param int $mode 0=long label, 1=short label, 2=Picto + short label, 3=Picto, 4=Picto + long label, 5=Short label + Picto, 6=Long label + Picto
* @return string Libelle * @return string Label of status
*/ */
public function LibStatut($status, $mode = 0) public function LibStatut($status, $mode = 0)
{ {

View File

@ -604,10 +604,10 @@ class Localtax extends CommonObject
} }
/** /**
* Retourne le libelle du statut d'une facture (brouillon, validee, abandonnee, payee) * Return the label of the status
* *
* @param int $mode 0=libelle long, 1=libelle court, 2=Picto + Libelle court, 3=Picto, 4=Picto + Libelle long, 5=Libelle court + Picto * @param int $mode 0=long label, 1=short label, 2=Picto + short label, 3=Picto, 4=Picto + long label, 5=Short label + Picto, 6=Long label + Picto
* @return string Libelle * @return string Label of status
*/ */
public function getLibStatut($mode = 0) public function getLibStatut($mode = 0)
{ {
@ -616,16 +616,16 @@ class Localtax extends CommonObject
// phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps // phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps
/** /**
* Renvoi le libelle d'un statut donne * Return the label of a given status
* *
* @param int $status Statut * @param int $status Id status
* @param int $mode 0=libelle long, 1=libelle court, 2=Picto + Libelle court, 3=Picto, 4=Picto + Libelle long, 5=Libelle court + Picto * @param int $mode 0=long label, 1=short label, 2=Picto + short label, 3=Picto, 4=Picto + long label, 5=Short label + Picto, 6=Long label + Picto
* @return string Libelle du statut * @return string Label of status
*/ */
public function LibStatut($status, $mode = 0) public function LibStatut($status, $mode = 0)
{ {
// phpcs:enable // phpcs:enable
global $langs; // TODO Renvoyer le libelle anglais et faire traduction a affichage //global $langs;
return ''; return '';
} }

View File

@ -995,10 +995,10 @@ class RemiseCheque extends CommonObject
} }
/** /**
* Retourne le libelle du statut d'une facture (brouillon, validee, abandonnee, payee) * Return the label of the status
* *
* @param int $mode 0=libelle long, 1=libelle court, 2=Picto + Libelle court, 3=Picto, 4=Picto + Libelle long, 5=Libelle court + Picto * @param int $mode 0=long label, 1=short label, 2=Picto + short label, 3=Picto, 4=Picto + long label, 5=Short label + Picto, 6=Long label + Picto
* @return string Libelle * @return string Label of status
*/ */
public function getLibStatut($mode = 0) public function getLibStatut($mode = 0)
{ {
@ -1007,11 +1007,11 @@ class RemiseCheque extends CommonObject
// phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps // phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps
/** /**
* Return label of a status * Return the label of a given status
* *
* @param int $status Id status * @param int $status Id status
* @param int $mode 0=long label, 1=short label, 2=Picto + short label, 3=Picto, 4=Picto + long label, 5=short label + picto, 6=Long label + picto * @param int $mode 0=long label, 1=short label, 2=Picto + short label, 3=Picto, 4=Picto + long label, 5=Short label + Picto, 6=Long label + Picto
* @return string Libelle du statut * @return string Label of status
*/ */
public function LibStatut($status, $mode = 0) public function LibStatut($status, $mode = 0)
{ {

View File

@ -1303,10 +1303,10 @@ class Paiement extends CommonObject
} }
/** /**
* Retourne le libelle du statut d'une facture (brouillon, validee, abandonnee, payee) * Return the label of the status
* *
* @param int $mode 0=libelle long, 1=libelle court, 2=Picto + Libelle court, 3=Picto, 4=Picto + Libelle long, 5=Libelle court + Picto * @param int $mode 0=long label, 1=short label, 2=Picto + short label, 3=Picto, 4=Picto + long label, 5=Short label + Picto, 6=Long label + Picto
* @return string Libelle * @return string Label of status
*/ */
public function getLibStatut($mode = 0) public function getLibStatut($mode = 0)
{ {
@ -1315,11 +1315,11 @@ class Paiement extends CommonObject
// phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps // phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps
/** /**
* Renvoi le libelle d'un statut donne * Return the label of a given status
* *
* @param int $status Statut * @param int $status Id status
* @param int $mode 0=libelle long, 1=libelle court, 2=Picto + Libelle court, 3=Picto, 4=Picto + Libelle long, 5=Libelle court + Picto * @param int $mode 0=long label, 1=short label, 2=Picto + short label, 3=Picto, 4=Picto + long label, 5=Short label + Picto, 6=Long label + Picto
* @return string Libelle du statut * @return string Label of status
*/ */
public function LibStatut($status, $mode = 0) public function LibStatut($status, $mode = 0)
{ {

View File

@ -222,11 +222,8 @@ print dol_get_fiche_end();
$disable_delete = 0; $disable_delete = 0;
$sql = 'SELECT f.rowid as scid, f.label as label, f.paye, f.amount as tva_amount, pf.amount'; $sql = 'SELECT f.rowid as scid, f.label as label, f.paye, f.amount as tva_amount, pf.amount';
//$sql .= ', pc.libelle as sc_type';
$sql .= ' FROM '.MAIN_DB_PREFIX.'payment_vat as pf,'.MAIN_DB_PREFIX.'tva as f'; $sql .= ' FROM '.MAIN_DB_PREFIX.'payment_vat as pf,'.MAIN_DB_PREFIX.'tva as f';
//$sql .= ', '.MAIN_DB_PREFIX.'c_chargesociales as pc';
$sql .= ' WHERE pf.fk_tva = f.rowid'; $sql .= ' WHERE pf.fk_tva = f.rowid';
//$sql .= ' AND f.fk_type = pc.id';
$sql .= ' AND f.entity = '.$conf->entity; $sql .= ' AND f.entity = '.$conf->entity;
$sql .= ' AND pf.rowid = '.((int) $object->id); $sql .= ' AND pf.rowid = '.((int) $object->id);

View File

@ -1888,7 +1888,7 @@ class BonPrelevement extends CommonObject
fputs($this->file, substr("000000000000000".$montant, -16)); fputs($this->file, substr("000000000000000".$montant, -16));
// Libelle F // Label F
fputs($this->file, substr("*_".$ref."_RDVnet".$rowid." ", 0, 31)); fputs($this->file, substr("*_".$ref."_RDVnet".$rowid." ", 0, 31));

View File

@ -441,9 +441,9 @@ class Cchargesociales
} }
/** /**
* Retourne le libelle du status d'un user (actif, inactif) * Return the label of the status
* *
* @param int $mode 0=libelle long, 1=libelle court, 2=Picto + Libelle court, 3=Picto, 4=Picto + Libelle long, 5=Libelle court + Picto * @param int $mode 0=long label, 1=short label, 2=Picto + short label, 3=Picto, 4=Picto + long label, 5=Short label + Picto, 6=Long label + Picto
* @return string Label of status * @return string Label of status
*/ */
public function getLibStatut($mode = 0) public function getLibStatut($mode = 0)
@ -453,10 +453,10 @@ class Cchargesociales
// phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps // phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps
/** /**
* Renvoi le libelle d'un status donne * Return the label of a given status
* *
* @param int $status Id status * @param int $status Id status
* @param int $mode 0=libelle long, 1=libelle court, 2=Picto + Libelle court, 3=Picto, 4=Picto + Libelle long, 5=Libelle court + Picto * @param int $mode 0=long label, 1=short label, 2=Picto + short label, 3=Picto, 4=Picto + long label, 5=Short label + Picto, 6=Long label + Picto
* @return string Label of status * @return string Label of status
*/ */
public function LibStatut($status, $mode = 0) public function LibStatut($status, $mode = 0)

View File

@ -664,10 +664,10 @@ class PaymentSocialContribution extends CommonObject
/** /**
* Retourne le libelle du statut d'une facture (brouillon, validee, abandonnee, payee) * Return the label of the status
* *
* @param int $mode 0=libelle long, 1=libelle court, 2=Picto + Libelle court, 3=Picto, 4=Picto + Libelle long, 5=Libelle court + Picto * @param int $mode 0=long label, 1=short label, 2=Picto + short label, 3=Picto, 4=Picto + long label, 5=Short label + Picto, 6=Long label + Picto
* @return string Libelle * @return string Label of status
*/ */
public function getLibStatut($mode = 0) public function getLibStatut($mode = 0)
{ {
@ -676,11 +676,11 @@ class PaymentSocialContribution extends CommonObject
// phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps // phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps
/** /**
* Renvoi le libelle d'un statut donne * Return the label of a given status
* *
* @param int $status Statut * @param int $status Id status
* @param int $mode 0=libelle long, 1=libelle court, 2=Picto + Libelle court, 3=Picto, 4=Picto + Libelle long, 5=Libelle court + Picto * @param int $mode 0=long label, 1=short label, 2=Picto + short label, 3=Picto, 4=Picto + long label, 5=Short label + Picto, 6=Long label + Picto
* @return string Libelle du statut * @return string Label of status
*/ */
public function LibStatut($status, $mode = 0) public function LibStatut($status, $mode = 0)
{ {

View File

@ -663,16 +663,16 @@ class PaymentVAT extends CommonObject
// phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps // phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps
/** /**
* Renvoi le libelle d'un statut donne * Return the label of a given status
* *
* @param int $status Statut * @param int $status Id status
* @param int $mode 0=libelle long, 1=libelle court, 2=Picto + Libelle court, 3=Picto, 4=Picto + Libelle long, 5=Libelle court + Picto * @param int $mode 0=long label, 1=short label, 2=Picto + short label, 3=Picto, 4=Picto + long label, 5=Short label + Picto, 6=Long label + Picto
* @return string Libelle du statut * @return string Label of status
*/ */
public function LibStatut($status, $mode = 0) public function LibStatut($status, $mode = 0)
{ {
// phpcs:enable // phpcs:enable
global $langs; // TODO Renvoyer le libelle anglais et faire traduction a affichage global $langs;
$langs->load('compta'); $langs->load('compta');
/*if ($mode == 0) /*if ($mode == 0)

View File

@ -849,7 +849,7 @@ class Tva extends CommonObject
} }
/** /**
* Retourne le libelle du statut d'une TVA (impaye, payee) * Return the label of the VAT status f object
* *
* @param int $mode 0=long label, 1=short label, 2=Picto + short label, 3=Picto, 4=Picto + long label, 5=short label + picto, 6=Long label + picto * @param int $mode 0=long label, 1=short label, 2=Picto + short label, 3=Picto, 4=Picto + long label, 5=short label + picto, 6=Long label + picto
* @param double $alreadypaid 0=No payment already done, >0=Some payments were already done (we recommand to put here amount payed if you have it, 1 otherwise) * @param double $alreadypaid 0=No payment already done, >0=Some payments were already done (we recommand to put here amount payed if you have it, 1 otherwise)
@ -862,7 +862,7 @@ class Tva extends CommonObject
// phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps // phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps
/** /**
* Renvoi le libelle d'un statut donne * Return the label of a given VAT status
* *
* @param int $status Id status * @param int $status Id status
* @param int $mode 0=long label, 1=short label, 2=Picto + short label, 3=Picto, 4=Picto + long label, 5=short label + picto, 6=Long label + picto * @param int $mode 0=long label, 1=short label, 2=Picto + short label, 3=Picto, 4=Picto + long label, 5=short label + picto, 6=Long label + picto

View File

@ -1580,10 +1580,10 @@ class Contact extends CommonObject
} }
/** /**
* Return label of contact status * Return the label of the status
* *
* @param int $mode 0=libelle long, 1=libelle court, 2=Picto + Libelle court, 3=Picto, 4=Picto + Libelle long, 5=Libelle court + Picto * @param int $mode 0=long label, 1=short label, 2=Picto + short label, 3=Picto, 4=Picto + long label, 5=Short label + Picto, 6=Long label + Picto
* @return string Label of contact status * @return string Label of status
*/ */
public function getLibStatut($mode) public function getLibStatut($mode)
{ {
@ -1592,11 +1592,11 @@ class Contact extends CommonObject
// phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps // phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps
/** /**
* Renvoi le libelle d'un statut donne * Return the label of a given status
* *
* @param int $status Id statut * @param int $status Id status
* @param int $mode 0=libelle long, 1=libelle court, 2=Picto + Libelle court, 3=Picto, 4=Picto + Libelle long, 5=Libelle court + Picto * @param int $mode 0=long label, 1=short label, 2=Picto + short label, 3=Picto, 4=Picto + long label, 5=Short label + Picto, 6=Long label + Picto
* @return string Libelle * @return string Label of status
*/ */
public function LibStatut($status, $mode) public function LibStatut($status, $mode)
{ {
@ -2009,9 +2009,9 @@ class Contact extends CommonObject
/** /**
* Return status of prospect * Return status of prospect
* *
* @param int $mode 0=libelle long, 1=libelle court, 2=Picto + Libelle court, 3=Picto, 4=Picto + Libelle long * @param int $mode 0=label long, 1=label short, 2=Picto + Label short, 3=Picto, 4=Picto + Label long
* @param string $label Label to use for status for added status * @param string $label Label to use for status for added status
* @return string Libelle * @return string Label
*/ */
public function getLibProspCommStatut($mode = 0, $label = '') public function getLibProspCommStatut($mode = 0, $label = '')
{ {
@ -2029,7 +2029,7 @@ class Contact extends CommonObject
* Example: picto.png if picto.png is stored into htdocs/theme/mytheme/img * Example: picto.png if picto.png is stored into htdocs/theme/mytheme/img
* Example: picto.png@mymodule if picto.png is stored into htdocs/mymodule/img * Example: picto.png@mymodule if picto.png is stored into htdocs/mymodule/img
* Example: /mydir/mysubdir/picto.png if picto.png is stored into htdocs/mydir/mysubdir (pictoisfullpath must be set to 1) * Example: /mydir/mysubdir/picto.png if picto.png is stored into htdocs/mydir/mysubdir (pictoisfullpath must be set to 1)
* @return string Libelle du statut * @return string Label of status
*/ */
public function libProspCommStatut($statut, $mode = 0, $label = '', $picto = '') public function libProspCommStatut($statut, $mode = 0, $label = '', $picto = '')
{ {

View File

@ -305,9 +305,9 @@ class EmailSenderProfile extends CommonObject
} }
/** /**
* Retourne le libelle du status d'un user (actif, inactif) * Return the label of a given status
* *
* @param int $mode 0=libelle long, 1=libelle court, 2=Picto + Libelle court, 3=Picto, 4=Picto + Libelle long, 5=Libelle court + Picto * @param int $mode 0=long label, 1=short label, 2=Picto + short label, 3=Picto, 4=Picto + long label, 5=Short label + Picto, 6=Long label + Picto
* @return string Label of status * @return string Label of status
*/ */
public function getLibStatut($mode = 0) public function getLibStatut($mode = 0)
@ -317,7 +317,7 @@ class EmailSenderProfile extends CommonObject
// phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps // phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps
/** /**
* Return the status * Return the label of a given status
* *
* @param int $status Id status * @param int $status Id status
* @param int $mode 0=long label, 1=short label, 2=Picto + short label, 3=Picto, 4=Picto + long label, 5=Short label + Picto, 6=Long label + Picto * @param int $mode 0=long label, 1=short label, 2=Picto + short label, 3=Picto, 4=Picto + long label, 5=Short label + Picto, 6=Long label + Picto

View File

@ -1267,7 +1267,7 @@ class ExtraFields
$labeltoshow = ''; $labeltoshow = '';
$obj = $this->db->fetch_object($resql); $obj = $this->db->fetch_object($resql);
// Several field into label (eq table:code|libelle:rowid) // Several field into label (eq table:code|label:rowid)
$notrans = false; $notrans = false;
$fields_label = explode('|', $InfoFieldList[1]); $fields_label = explode('|', $InfoFieldList[1]);
if (is_array($fields_label) && count($fields_label) > 1) { if (is_array($fields_label) && count($fields_label) > 1) {
@ -1487,7 +1487,7 @@ class ExtraFields
$obj = $this->db->fetch_object($resql); $obj = $this->db->fetch_object($resql);
$notrans = false; $notrans = false;
// Several field into label (eq table:code|libelle:rowid) // Several field into label (eq table:code|label:rowid)
$fields_label = explode('|', $InfoFieldList[1]); $fields_label = explode('|', $InfoFieldList[1]);
if (is_array($fields_label)) { if (is_array($fields_label)) {
$notrans = true; $notrans = true;
@ -1722,7 +1722,7 @@ class ExtraFields
$obj = $this->db->fetch_object($resql); $obj = $this->db->fetch_object($resql);
// Several field into label (eq table:code|libelle:rowid) // Several field into label (eq table:code|label:rowid)
$fields_label = explode('|', $InfoFieldList[1]); $fields_label = explode('|', $InfoFieldList[1]);
if (is_array($fields_label) && count($fields_label) > 1) { if (is_array($fields_label) && count($fields_label) > 1) {
@ -1830,7 +1830,7 @@ class ExtraFields
$value = ''; // value was used, so now we reste it to use it to build final output $value = ''; // value was used, so now we reste it to use it to build final output
$toprint = array(); $toprint = array();
while ($obj = $this->db->fetch_object($resql)) { while ($obj = $this->db->fetch_object($resql)) {
// Several field into label (eq table:code|libelle:rowid) // Several field into label (eq table:code|label:rowid)
$fields_label = explode('|', $InfoFieldList[1]); $fields_label = explode('|', $InfoFieldList[1]);
if (is_array($value_arr) && in_array($obj->rowid, $value_arr)) { if (is_array($value_arr) && in_array($obj->rowid, $value_arr)) {
if (is_array($fields_label) && count($fields_label) > 1) { if (is_array($fields_label) && count($fields_label) > 1) {

View File

@ -238,7 +238,7 @@ class CommActionRapport
$sql = "SELECT s.nom as thirdparty, s.rowid as socid, s.client,"; $sql = "SELECT s.nom as thirdparty, s.rowid as socid, s.client,";
$sql .= " a.id, a.datep as dp, a.datep2 as dp2,"; $sql .= " a.id, a.datep as dp, a.datep2 as dp2,";
$sql .= " a.fk_contact, a.note, a.percent as percent, a.fulldayevent, a.label, a.fk_project,"; $sql .= " a.fk_contact, a.note, a.percent as percent, a.fulldayevent, a.label, a.fk_project,";
$sql .= " c.code, c.libelle,"; $sql .= " c.code, c.libelle as label_type,";
$sql .= " u.login"; $sql .= " u.login";
$sql .= " FROM ".MAIN_DB_PREFIX."c_actioncomm as c, ".MAIN_DB_PREFIX."user as u, ".MAIN_DB_PREFIX."actioncomm as a"; $sql .= " FROM ".MAIN_DB_PREFIX."c_actioncomm as c, ".MAIN_DB_PREFIX."user as u, ".MAIN_DB_PREFIX."actioncomm as a";
$sql .= " LEFT JOIN ".MAIN_DB_PREFIX."societe as s ON a.fk_soc = s.rowid"; $sql .= " LEFT JOIN ".MAIN_DB_PREFIX."societe as s ON a.fk_soc = s.rowid";

View File

@ -107,7 +107,7 @@ class ModeleExports extends CommonDocGenerator // This class can't be abstrac
} }
/** /**
* Renvoi libelle d'un driver export * Return label of driver export
* *
* @param string $key Key of driver * @param string $key Key of driver
* @return string Label * @return string Label
@ -140,7 +140,7 @@ class ModeleExports extends CommonDocGenerator // This class can't be abstrac
} }
/** /**
* Renvoi libelle de librairie externe du driver * Renvoi label of driver lib
* *
* @param string $key Key of driver * @param string $key Key of driver
* @return string Label of library * @return string Label of library
@ -151,7 +151,7 @@ class ModeleExports extends CommonDocGenerator // This class can't be abstrac
} }
/** /**
* Renvoi version de librairie externe du driver * Return version of driver lib
* *
* @param string $key Key of driver * @param string $key Key of driver
* @return string Version of library * @return string Version of library

View File

@ -253,7 +253,7 @@ class ModeleImports
} }
/** /**
* Renvoi libelle d'un driver import * Return label of driver import
* *
* @param string $key Key * @param string $key Key
* @return string * @return string
@ -264,7 +264,7 @@ class ModeleImports
} }
/** /**
* Renvoi la description d'un driver import * Return description of import drivervoi la description d'un driver import
* *
* @param string $key Key * @param string $key Key
* @return string * @return string

View File

@ -1479,7 +1479,7 @@ class Cronjob extends CommonObject
// phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps // phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps
/** /**
* Renvoi le libelle d'un statut donne * Return label of a giver status
* *
* @param int $status Id statut * @param int $status Id statut
* @param int $mode 0=long label, 1=short label, 2=Picto + short label, 3=Picto, 4=Picto + long label, 5=Short label + Picto, 6=Long label + Picto * @param int $mode 0=long label, 1=short label, 2=Picto + short label, 3=Picto, 4=Picto + long label, 5=Short label + Picto, 6=Long label + Picto

View File

@ -899,10 +899,10 @@ class Delivery extends CommonObject
/** /**
* Retourne le libelle du statut d'une expedition * Return the label of the status
* *
* @param int $mode Mode * @param int $mode 0=long label, 1=short label, 2=Picto + short label, 3=Picto, 4=Picto + long label, 5=Short label + Picto, 6=Long label + Picto
* @return string Label * @return string Label of status
*/ */
public function getLibStatut($mode = 0) public function getLibStatut($mode = 0)
{ {
@ -911,11 +911,11 @@ class Delivery extends CommonObject
// phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps // phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps
/** /**
* Renvoi le libelle d'un statut donne * Return the label of a given status
* *
* @param int $status Id status * @param int $status Id status
* @param int $mode 0=long label, 1=short label, 2=Picto + short label, 3=Picto, 4=Picto + long label, 5=Short label + Picto, 6=Long label + Picto * @param int $mode 0=long label, 1=short label, 2=Picto + short label, 3=Picto, 4=Picto + long label, 5=Short label + Picto, 6=Long label + Picto
* @return string Label * @return string Label of status
*/ */
public function LibStatut($status, $mode) public function LibStatut($status, $mode)
{ {

View File

@ -507,10 +507,10 @@ class PaymentDonation extends CommonObject
/** /**
* Retourne le libelle du statut d'un don (brouillon, validee, abandonnee, payee) * Return the label of the status
* *
* @param int $mode 0=libelle long, 1=libelle court, 2=Picto + Libelle court, 3=Picto, 4=Picto + Libelle long * @param int $mode 0=long label, 1=short label, 2=Picto + short label, 3=Picto, 4=Picto + long label, 5=Short label + Picto, 6=Long label + Picto
* @return string Libelle * @return string Label of status
*/ */
public function getLibStatut($mode = 0) public function getLibStatut($mode = 0)
{ {
@ -519,11 +519,11 @@ class PaymentDonation extends CommonObject
// phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps // phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps
/** /**
* Renvoi le libelle d'un statut donne * Return the label of a given status
* *
* @param int $status Id status * @param int $status Id status
* @param int $mode 0=libelle long, 1=libelle court, 2=Picto + Libelle court, 3=Picto, 4=Picto + Libelle long, 5=Libelle court + Picto * @param int $mode 0=long label, 1=short label, 2=Picto + short label, 3=Picto, 4=Picto + long label, 5=Short label + Picto, 6=Long label + Picto
* @return string Libelle du statut * @return string Label of status
*/ */
public function LibStatut($status, $mode = 0) public function LibStatut($status, $mode = 0)
{ {

View File

@ -589,9 +589,9 @@ class EcmDirectory extends CommonObject
/** /**
* Retourne le libelle du status d'un user (actif, inactif) * Return the label of the status
* *
* @param int $mode 0=libelle long, 1=libelle court, 2=Picto + Libelle court, 3=Picto, 4=Picto + Libelle long, 5=Libelle court + Picto * @param int $mode 0=long label, 1=short label, 2=Picto + short label, 3=Picto, 4=Picto + long label, 5=Short label + Picto, 6=Long label + Picto
* @return string Label of status * @return string Label of status
*/ */
public function getLibStatut($mode = 0) public function getLibStatut($mode = 0)

View File

@ -918,9 +918,9 @@ class EcmFiles extends CommonObject
} }
/** /**
* Retourne le libelle du status d'un user (actif, inactif) * Return the label of the status
* *
* @param int $mode 0=libelle long, 1=libelle court, 2=Picto + Libelle court, 3=Picto, 4=Picto + Libelle long, 5=Libelle court + Picto * @param int $mode 0=long label, 1=short label, 2=Picto + short label, 3=Picto, 4=Picto + long label, 5=Short label + Picto, 6=Long label + Picto
* @return string Label of status * @return string Label of status
*/ */
public function getLibStatut($mode = 0) public function getLibStatut($mode = 0)

View File

@ -1874,7 +1874,7 @@ class Expedition extends CommonObject
* Return status label * Return status label
* *
* @param int $mode 0=Long label, 1=Short label, 2=Picto + Short label, 3=Picto, 4=Picto + Long label, 5=Short label + Picto * @param int $mode 0=Long label, 1=Short label, 2=Picto + Short label, 3=Picto, 4=Picto + Long label, 5=Short label + Picto
* @return string Libelle * @return string Label
*/ */
public function getLibStatut($mode = 0) public function getLibStatut($mode = 0)
{ {

View File

@ -445,10 +445,10 @@ class PaymentExpenseReport extends CommonObject
/** /**
* Retourne le libelle du statut d'un don (brouillon, validee, abandonnee, payee) * Return the label of the status
* *
* @param int $mode 0=libelle long, 1=libelle court, 2=Picto + Libelle court, 3=Picto, 4=Picto + Libelle long * @param int $mode 0=long label, 1=short label, 2=Picto + short label, 3=Picto, 4=Picto + long label, 5=Short label + Picto, 6=Long label + Picto
* @return string Libelle * @return string Label of status
*/ */
public function getLibStatut($mode = 0) public function getLibStatut($mode = 0)
{ {
@ -457,16 +457,16 @@ class PaymentExpenseReport extends CommonObject
// phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps // phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps
/** /**
* Renvoi le libelle d'un statut donne * Return the label of a given status
* *
* @param int $status Id status * @param int $status Id status
* @param int $mode 0=libelle long, 1=libelle court, 2=Picto + Libelle court, 3=Picto, 4=Picto + Libelle long, 5=Libelle court + Picto * @param int $mode 0=long label, 1=short label, 2=Picto + short label, 3=Picto, 4=Picto + long label, 5=Short label + Picto, 6=Long label + Picto
* @return string Libelle du statut * @return string Label of status
*/ */
public function LibStatut($status, $mode = 0) public function LibStatut($status, $mode = 0)
{ {
// phpcs:enable // phpcs:enable
global $langs; //global $langs;
return ''; return '';
} }

View File

@ -86,6 +86,7 @@ class CommandeFournisseurDispatch extends CommonObjectLine
public $qty_asked; public $qty_asked;
public $libelle; public $libelle;
public $label;
public $desc; public $desc;
public $tva_tx; public $tva_tx;
public $vat_src_code; public $vat_src_code;

View File

@ -581,10 +581,10 @@ class PaiementFourn extends Paiement
} }
/** /**
* Retourne le libelle du statut d'une facture (brouillon, validee, abandonnee, payee) * Return the label of the status
* *
* @param int $mode 0=libelle long, 1=libelle court, 2=Picto + Libelle court, 3=Picto, 4=Picto + Libelle long, 5=Libelle court + Picto * @param int $mode 0=long label, 1=short label, 2=Picto + short label, 3=Picto, 4=Picto + long label, 5=Short label + Picto, 6=Long label + Picto
* @return string Libelle * @return string Label of status
*/ */
public function getLibStatut($mode = 0) public function getLibStatut($mode = 0)
{ {
@ -593,11 +593,11 @@ class PaiementFourn extends Paiement
// phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps // phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps
/** /**
* Renvoi le libelle d'un statut donne * Return the label of a given status
* *
* @param int $status Statut * @param int $status Id status
* @param int $mode 0=libelle long, 1=libelle court, 2=Picto + Libelle court, 3=Picto, 4=Picto + Libelle long, 5=Libelle court + Picto * @param int $mode 0=long label, 1=short label, 2=Picto + short label, 3=Picto, 4=Picto + long label, 5=Short label + Picto, 6=Long label + Picto
* @return string Libelle du statut * @return string Label of status
*/ */
public function LibStatut($status, $mode = 0) public function LibStatut($status, $mode = 0)
{ {

View File

@ -947,7 +947,7 @@ if ($action == 'create') {
} }
$htmltext .= '</i>'; $htmltext .= '</i>';
// Libelle // Label
print '<tr><td class="titlefieldcreate">' . $langs->trans("Label") . '</td><td>'; print '<tr><td class="titlefieldcreate">' . $langs->trans("Label") . '</td><td>';
print '<input class="flat quatrevingtpercent" type="text" name="libelle" value="' . $object->label . '">'; print '<input class="flat quatrevingtpercent" type="text" name="libelle" value="' . $object->label . '">';
print '</td></tr>'; print '</td></tr>';

View File

@ -162,9 +162,9 @@ class Import
$this->array_import_perms[$i] = $user->rights->import->run; $this->array_import_perms[$i] = $user->rights->import->run;
// Icon // Icon
$this->array_import_icon[$i] = (isset($module->import_icon[$r]) ? $module->import_icon[$r] : $module->picto); $this->array_import_icon[$i] = (isset($module->import_icon[$r]) ? $module->import_icon[$r] : $module->picto);
// Code du dataset export // Code of dataset export
$this->array_import_code[$i] = $module->import_code[$r]; $this->array_import_code[$i] = $module->import_code[$r];
// Libelle du dataset export // Label of dataset export
$this->array_import_label[$i] = $module->getImportDatasetLabel($r); $this->array_import_label[$i] = $module->getImportDatasetLabel($r);
// Array of tables to import (key=alias, value=tablename) // Array of tables to import (key=alias, value=tablename)
$this->array_import_tables[$i] = $module->import_tables_array[$r]; $this->array_import_tables[$i] = $module->import_tables_array[$r];

View File

@ -453,10 +453,10 @@ class PaymentLoan extends CommonObject
} }
/** /**
* Retourne le libelle du statut d'une facture (brouillon, validee, abandonnee, payee) * Return the label of the status
* *
* @param int $mode 0=libelle long, 1=libelle court, 2=Picto + Libelle court, 3=Picto, 4=Picto + Libelle long, 5=Libelle court + Picto * @param int $mode 0=long label, 1=short label, 2=Picto + short label, 3=Picto, 4=Picto + long label, 5=Short label + Picto, 6=Long label + Picto
* @return string Libelle * @return string Label of status
*/ */
public function getLibStatut($mode = 0) public function getLibStatut($mode = 0)
{ {

View File

@ -753,13 +753,14 @@ class MyObject extends CommonObject
/** /**
* getTooltipContentArray * getTooltipContentArray
* @param array $params params to construct tooltip data *
* @param array $params Params to construct tooltip data
* @since v18 * @since v18
* @return array * @return array
*/ */
public function getTooltipContentArray($params) public function getTooltipContentArray($params)
{ {
global $conf, $langs, $user; global $conf, $langs;
$datas = []; $datas = [];
@ -959,7 +960,7 @@ class MyObject extends CommonObject
// phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps // phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps
/** /**
* Return the status * Return the label of a given status
* *
* @param int $status Id status * @param int $status Id status
* @param int $mode 0=long label, 1=short label, 2=Picto + short label, 3=Picto, 4=Picto + long label, 5=Short label + Picto, 6=Long label + Picto * @param int $mode 0=long label, 1=short label, 2=Picto + short label, 3=Picto, 4=Picto + long label, 5=Short label + Picto, 6=Long label + Picto

View File

@ -666,8 +666,8 @@ class Opensurveysondage extends CommonObject
/** /**
* Return status label of Order * Return status label of Order
* *
* @param int $mode 0=libelle long, 1=libelle court, 2=Picto + Libelle court, 3=Picto, 4=Picto + Libelle long, 5=Libelle court + Picto * @param int $mode 0=long label, 1=short label, 2=Picto + short label, 3=Picto, 4=Picto + long label, 5=Short label + Picto, 6=Long label + Picto
* @return string Libelle * @return string Label if status
*/ */
public function getLibStatut($mode) public function getLibStatut($mode)
{ {
@ -678,8 +678,8 @@ class Opensurveysondage extends CommonObject
/** /**
* Return label of status * Return label of status
* *
* @param int $status Id statut * @param int $status Id status
* @param int $mode 0=libelle long, 1=libelle court, 2=Picto + Libelle court, 3=Picto, 4=Picto + Libelle long, 5=Libelle court + Picto * @param int $mode 0=long label, 1=short label, 2=Picto + short label, 3=Picto, 4=Picto + long label, 5=Short label + Picto, 6=Long label + Picto
* @return string Label of status * @return string Label of status
*/ */
public function LibStatut($status, $mode) public function LibStatut($status, $mode)

View File

@ -607,9 +607,9 @@ class Inventory extends CommonObject
} }
/** /**
* Retourne le libelle du status d'un user (actif, inactif) * Return the label of the status
* *
* @param int $mode 0=libelle long, 1=libelle court, 2=Picto + Libelle court, 3=Picto, 4=Picto + Libelle long, 5=Libelle court + Picto * @param int $mode 0=long label, 1=short label, 2=Picto + short label, 3=Picto, 4=Picto + long label, 5=Short label + Picto, 6=Long label + Picto
* @return string Label of status * @return string Label of status
*/ */
public function getLibStatut($mode = 0) public function getLibStatut($mode = 0)

View File

@ -1154,9 +1154,9 @@ class MouvementStock extends CommonObject
// phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps // phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps
/** /**
* Renvoi le libelle d'un status donne * Return the label of the status
* *
* @param int $mode 0=libelle long, 1=libelle court, 2=Picto + Libelle court, 3=Picto, 4=Picto + Libelle long, 5=Libelle court + Picto * @param int $mode 0=long label, 1=short label, 2=Picto + short label, 3=Picto, 4=Picto + long label, 5=Short label + Picto, 6=Long label + Picto
* @return string Label of status * @return string Label of status
*/ */
public function LibStatut($mode = 0) public function LibStatut($mode = 0)

View File

@ -532,9 +532,9 @@ class ProductStockEntrepot extends CommonObject
} }
/** /**
* Retourne le libelle du status d'un user (actif, inactif) * Return the label of the status
* *
* @param int $mode 0=libelle long, 1=libelle court, 2=Picto + Libelle court, 3=Picto, 4=Picto + Libelle long, 5=Libelle court + Picto * @param int $mode 0=long label, 1=short label, 2=Picto + short label, 3=Picto, 4=Picto + long label, 5=Short label + Picto, 6=Long label + Picto
* @return string Label of status * @return string Label of status
*/ */
public function getLibStatut($mode = 0) public function getLibStatut($mode = 0)

View File

@ -1383,7 +1383,8 @@ class Reception extends CommonObject
while ($xnbp < $nbp) { while ($xnbp < $nbp) {
$line = new CommandeFournisseurDispatch($this->db); $line = new CommandeFournisseurDispatch($this->db);
$line->desc = $langs->trans("Description")." ".$xnbp; $line->desc = $langs->trans("Description")." ".$xnbp;
$line->libelle = $langs->trans("Description")." ".$xnbp; $line->libelle = $langs->trans("Description")." ".$xnbp; // deprecated
$line->label = $langs->trans("Description")." ".$xnbp;
$line->qty = 10; $line->qty = 10;
$line->fk_product = $this->commande->lines[$xnbp]->fk_product; $line->fk_product = $this->commande->lines[$xnbp]->fk_product;

View File

@ -750,7 +750,7 @@ class Dolresource extends CommonObject
$i = 0; $i = 0;
while ($i < $num) { while ($i < $num) {
$obj = $this->db->fetch_object($resql); $obj = $this->db->fetch_object($resql);
// Si traduction existe, on l'utilise, sinon on prend le libelle par defaut
$label = ($langs->trans("ResourceTypeShort".$obj->code) != ("ResourceTypeShort".$obj->code) ? $langs->trans("ResourceTypeShort".$obj->code) : ($obj->label != '-' ? $obj->label : '')); $label = ($langs->trans("ResourceTypeShort".$obj->code) != ("ResourceTypeShort".$obj->code) ? $langs->trans("ResourceTypeShort".$obj->code) : ($obj->label != '-' ? $obj->label : ''));
$this->cache_code_type_resource[$obj->rowid]['code'] = $obj->code; $this->cache_code_type_resource[$obj->rowid]['code'] = $obj->code;
$this->cache_code_type_resource[$obj->rowid]['label'] = $label; $this->cache_code_type_resource[$obj->rowid]['label'] = $label;
@ -875,9 +875,9 @@ class Dolresource extends CommonObject
/** /**
* Retourne le libelle du status d'un user (actif, inactif) * Return the label of the status
* *
* @param int $mode 0=libelle long, 1=libelle court, 2=Picto + Libelle court, 3=Picto, 4=Picto + Libelle long, 5=Libelle court + Picto * @param int $mode 0=long label, 1=short label, 2=Picto + short label, 3=Picto, 4=Picto + long label, 5=Short label + Picto, 6=Long label + Picto
* @return string Label of status * @return string Label of status
*/ */
public function getLibStatut($mode = 0) public function getLibStatut($mode = 0)

View File

@ -674,9 +674,9 @@ class Salary extends CommonObject
/** /**
* Retourne le libelle du statut d'une facture (brouillon, validee, abandonnee, payee) * Return label of current status
* *
* @param int $mode 0=libelle long, 1=libelle court, 2=Picto + Libelle court, 3=Picto, 4=Picto + Libelle long, 5=Libelle court + Picto * @param int $mode 0=label long, 1=labels short, 2=Picto + Label short, 3=Picto, 4=Picto + Label long, 5=Label short + Picto
* @param double $alreadypaid 0=No payment already done, >0=Some payments were already done (we recommand to put here amount payed if you have it, 1 otherwise) * @param double $alreadypaid 0=No payment already done, >0=Some payments were already done (we recommand to put here amount payed if you have it, 1 otherwise)
* @return string Label * @return string Label
*/ */
@ -687,7 +687,7 @@ class Salary extends CommonObject
// phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps // phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps
/** /**
* Renvoi le libelle d'un statut donne * Return label of a given status
* *
* @param int $status Id status * @param int $status Id status
* @param int $mode 0=long label, 1=short label, 2=Picto + short label, 3=Picto, 4=Picto + long label, 5=short label + picto, 6=Long label + picto * @param int $mode 0=long label, 1=short label, 2=Picto + short label, 3=Picto, 4=Picto + long label, 5=short label + picto, 6=Long label + picto

View File

@ -4616,7 +4616,7 @@ class Societe extends CommonObject
/** /**
* Return prostect level * Return prostect level
* *
* @return string Libelle * @return string Label of prospect status
*/ */
public function getLibProspLevel() public function getLibProspLevel()
{ {
@ -4646,9 +4646,9 @@ class Societe extends CommonObject
/** /**
* Return status of prospect * Return status of prospect
* *
* @param int $mode 0=libelle long, 1=libelle court, 2=Picto + Libelle court, 3=Picto, 4=Picto + Libelle long * @param int $mode 0=label long, 1=label short, 2=Picto + Label short, 3=Picto, 4=Picto + Label long
* @param string $label Label to use for status for added status * @param string $label Label to use for status for added status
* @return string Libelle * @return string Label
*/ */
public function getLibProspCommStatut($mode = 0, $label = '') public function getLibProspCommStatut($mode = 0, $label = '')
{ {

View File

@ -467,9 +467,9 @@ class SocieteAccount extends CommonObject
} }
/** /**
* Retourne le libelle du status d'un user (actif, inactif) * Return the label of a given status
* *
* @param int $mode 0=libelle long, 1=libelle court, 2=Picto + Libelle court, 3=Picto, 4=Picto + Libelle long, 5=Libelle court + Picto * @param int $mode 0=long label, 1=short label, 2=Picto + short label, 3=Picto, 4=Picto + long label, 5=Short label + Picto, 6=Long label + Picto
* @return string Label of status * @return string Label of status
*/ */
public function getLibStatut($mode = 0) public function getLibStatut($mode = 0)

View File

@ -685,17 +685,14 @@ class Ticket extends CommonObject
$this->timing = $obj->timing; $this->timing = $obj->timing;
$this->type_code = $obj->type_code; $this->type_code = $obj->type_code;
// Si traduction existe, on l'utilise, sinon on prend le libelle par defaut
$label_type = ($langs->trans("TicketTypeShort".$obj->type_code) != ("TicketTypeShort".$obj->type_code) ? $langs->trans("TicketTypeShort".$obj->type_code) : ($obj->type_label != '-' ? $obj->type_label : '')); $label_type = ($langs->trans("TicketTypeShort".$obj->type_code) != ("TicketTypeShort".$obj->type_code) ? $langs->trans("TicketTypeShort".$obj->type_code) : ($obj->type_label != '-' ? $obj->type_label : ''));
$this->type_label = $label_type; $this->type_label = $label_type;
$this->category_code = $obj->category_code; $this->category_code = $obj->category_code;
// Si traduction existe, on l'utilise, sinon on prend le libelle par defaut
$label_category = ($langs->trans("TicketCategoryShort".$obj->category_code) != ("TicketCategoryShort".$obj->category_code) ? $langs->trans("TicketCategoryShort".$obj->category_code) : ($obj->category_label != '-' ? $obj->category_label : '')); $label_category = ($langs->trans("TicketCategoryShort".$obj->category_code) != ("TicketCategoryShort".$obj->category_code) ? $langs->trans("TicketCategoryShort".$obj->category_code) : ($obj->category_label != '-' ? $obj->category_label : ''));
$this->category_label = $label_category; $this->category_label = $label_category;
$this->severity_code = $obj->severity_code; $this->severity_code = $obj->severity_code;
// Si traduction existe, on l'utilise, sinon on prend le libelle par defaut
$label_severity = ($langs->trans("TicketSeverityShort".$obj->severity_code) != ("TicketSeverityShort".$obj->severity_code) ? $langs->trans("TicketSeverityShort".$obj->severity_code) : ($obj->severity_label != '-' ? $obj->severity_label : '')); $label_severity = ($langs->trans("TicketSeverityShort".$obj->severity_code) != ("TicketSeverityShort".$obj->severity_code) ? $langs->trans("TicketSeverityShort".$obj->severity_code) : ($obj->severity_label != '-' ? $obj->severity_label : ''));
$this->severity_label = $label_severity; $this->severity_label = $label_severity;
@ -855,17 +852,14 @@ class Ticket extends CommonObject
$line->progress = $obj->progress; $line->progress = $obj->progress;
$line->timing = $obj->timing; $line->timing = $obj->timing;
// Si traduction existe, on l'utilise, sinon on prend le libelle par defaut
$label_type = ($langs->trans("TicketTypeShort".$obj->type_code) != ("TicketTypeShort".$obj->type_code) ? $langs->trans("TicketTypeShort".$obj->type_code) : ($obj->type_label != '-' ? $obj->type_label : '')); $label_type = ($langs->trans("TicketTypeShort".$obj->type_code) != ("TicketTypeShort".$obj->type_code) ? $langs->trans("TicketTypeShort".$obj->type_code) : ($obj->type_label != '-' ? $obj->type_label : ''));
$line->type_label = $label_type; $line->type_label = $label_type;
$this->category_code = $obj->category_code; $this->category_code = $obj->category_code;
// Si traduction existe, on l'utilise, sinon on prend le libelle par defaut
$label_category = ($langs->trans("TicketCategoryShort".$obj->category_code) != ("TicketCategoryShort".$obj->category_code) ? $langs->trans("TicketCategoryShort".$obj->category_code) : ($obj->category_label != '-' ? $obj->category_label : '')); $label_category = ($langs->trans("TicketCategoryShort".$obj->category_code) != ("TicketCategoryShort".$obj->category_code) ? $langs->trans("TicketCategoryShort".$obj->category_code) : ($obj->category_label != '-' ? $obj->category_label : ''));
$line->category_label = $label_category; $line->category_label = $label_category;
$this->severity_code = $obj->severity_code; $this->severity_code = $obj->severity_code;
// Si traduction existe, on l'utilise, sinon on prend le libelle par defaut
$label_severity = ($langs->trans("TicketSeverityShort".$obj->severity_code) != ("TicketSeverityShort".$obj->severity_code) ? $langs->trans("TicketSeverityShort".$obj->severity_code) : ($obj->severity_label != '-' ? $obj->severity_label : '')); $label_severity = ($langs->trans("TicketSeverityShort".$obj->severity_code) != ("TicketSeverityShort".$obj->severity_code) ? $langs->trans("TicketSeverityShort".$obj->severity_code) : ($obj->severity_label != '-' ? $obj->severity_label : ''));
$line->severity_label = $label_severity; $line->severity_label = $label_severity;
@ -1254,7 +1248,6 @@ class Ticket extends CommonObject
$i = 0; $i = 0;
while ($i < $num) { while ($i < $num) {
$obj = $this->db->fetch_object($resql); $obj = $this->db->fetch_object($resql);
// Si traduction existe, on l'utilise, sinon on prend le libelle par defaut
$label = ($langs->trans("TicketTypeShort".$obj->code) != ("TicketTypeShort".$obj->code) ? $langs->trans("TicketTypeShort".$obj->code) : ($obj->label != '-' ? $obj->label : '')); $label = ($langs->trans("TicketTypeShort".$obj->code) != ("TicketTypeShort".$obj->code) ? $langs->trans("TicketTypeShort".$obj->code) : ($obj->label != '-' ? $obj->label : ''));
$this->cache_types_tickets[$obj->rowid]['code'] = $obj->code; $this->cache_types_tickets[$obj->rowid]['code'] = $obj->code;
$this->cache_types_tickets[$obj->rowid]['label'] = $label; $this->cache_types_tickets[$obj->rowid]['label'] = $label;
@ -1343,7 +1336,6 @@ class Ticket extends CommonObject
$obj = $this->db->fetch_object($resql); $obj = $this->db->fetch_object($resql);
$this->cache_severity_tickets[$obj->rowid]['code'] = $obj->code; $this->cache_severity_tickets[$obj->rowid]['code'] = $obj->code;
// Si traduction existe, on l'utilise, sinon on prend le libelle par defaut
$label = ($langs->trans("TicketSeverityShort".$obj->code) != ("TicketSeverityShort".$obj->code) ? $langs->trans("TicketSeverityShort".$obj->code) : ($obj->label != '-' ? $obj->label : '')); $label = ($langs->trans("TicketSeverityShort".$obj->code) != ("TicketSeverityShort".$obj->code) ? $langs->trans("TicketSeverityShort".$obj->code) : ($obj->label != '-' ? $obj->label : ''));
$this->cache_severity_tickets[$obj->rowid]['label'] = $label; $this->cache_severity_tickets[$obj->rowid]['label'] = $label;
$this->cache_severity_tickets[$obj->rowid]['use_default'] = $obj->use_default; $this->cache_severity_tickets[$obj->rowid]['use_default'] = $obj->use_default;

View File

@ -698,9 +698,9 @@ class UserGroup extends CommonObject
/** /**
* Return label of status of user (active, inactive) * Return the label of the status
* *
* @param int $mode 0=libelle long, 1=libelle court, 2=Picto + Libelle court, 3=Picto, 4=Picto + Libelle long, 5=Libelle court + Picto * @param int $mode 0=long label, 1=short label, 2=Picto + short label, 3=Picto, 4=Picto + long label, 5=Short label + Picto, 6=Long label + Picto
* @return string Label of status * @return string Label of status
*/ */
public function getLibStatut($mode = 0) public function getLibStatut($mode = 0)
@ -710,10 +710,10 @@ class UserGroup extends CommonObject
// phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps // phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps
/** /**
* Renvoi le libelle d'un statut donne * Return the label of a given status
* *
* @param int $status Id status * @param int $status Id status
* @param int $mode 0=libelle long, 1=libelle court, 2=Picto + Libelle court, 3=Picto, 4=Picto + Libelle long, 5=Libelle court + Picto * @param int $mode 0=long label, 1=short label, 2=Picto + short label, 3=Picto, 4=Picto + long label, 5=Short label + Picto, 6=Long label + Picto
* @return string Label of status * @return string Label of status
*/ */
public function LibStatut($status, $mode = 0) public function LibStatut($status, $mode = 0)

View File

@ -852,9 +852,9 @@ class Website extends CommonObject
} }
/** /**
* Retourne le libelle du status d'un user (actif, inactif) * Return the label of the status
* *
* @param int $mode 0=libelle long, 1=libelle court, 2=Picto + Libelle court, 3=Picto, 4=Picto + Libelle long, 5=Libelle court + Picto * @param int $mode 0=long label, 1=short label, 2=Picto + short label, 3=Picto, 4=Picto + long label, 5=Short label + Picto, 6=Long label + Picto
* @return string Label of status * @return string Label of status
*/ */
public function getLibStatut($mode = 0) public function getLibStatut($mode = 0)
@ -864,10 +864,10 @@ class Website extends CommonObject
// phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps // phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps
/** /**
* Renvoi le libelle d'un status donne * Return the label of a given status
* *
* @param int $status Id status * @param int $status Id status
* @param int $mode 0=libelle long, 1=libelle court, 2=Picto + Libelle court, 3=Picto, 4=Picto + Libelle long, 5=Libelle court + Picto * @param int $mode 0=long label, 1=short label, 2=Picto + short label, 3=Picto, 4=Picto + long label, 5=Short label + Picto, 6=Long label + Picto
* @return string Label of status * @return string Label of status
*/ */
public function LibStatut($status, $mode = 0) public function LibStatut($status, $mode = 0)

View File

@ -795,9 +795,9 @@ class WebsitePage extends CommonObject
} }
/** /**
* Retourne le libelle du status d'un user (actif, inactif) * Return the label of the status
* *
* @param int $mode 0=libelle long, 1=libelle court, 2=Picto + Libelle court, 3=Picto, 4=Picto + Libelle long, 5=Libelle court + Picto * @param int $mode 0=long label, 1=short label, 2=Picto + short label, 3=Picto, 4=Picto + long label, 5=Short label + Picto, 6=Long label + Picto
* @return string Label of status * @return string Label of status
*/ */
public function getLibStatut($mode = 0) public function getLibStatut($mode = 0)
@ -807,10 +807,10 @@ class WebsitePage extends CommonObject
// phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps // phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps
/** /**
* Renvoi le libelle d'un status donne * Return the label of a given status
* *
* @param int $status Id status * @param int $status Id status
* @param int $mode 0=libelle long, 1=libelle court, 2=Picto + Libelle court, 3=Picto, 4=Picto + Libelle long, 5=Libelle court + Picto * @param int $mode 0=long label, 1=short label, 2=Picto + short label, 3=Picto, 4=Picto + long label, 5=Short label + Picto, 6=Long label + Picto
* @return string Label of status * @return string Label of status
*/ */
public function LibStatut($status, $mode = 0) public function LibStatut($status, $mode = 0)