move phpcs:ignore

This commit is contained in:
Frédéric FRANCE 2018-09-02 18:18:10 +02:00
parent 2a5c994009
commit 61c4e9831f
No known key found for this signature in database
GPG Key ID: 06809324E4B2ABC1
3 changed files with 31 additions and 20 deletions

View File

@ -41,12 +41,12 @@ class Contact extends CommonObject
* @var string ID to identify managed object * @var string ID to identify managed object
*/ */
public $element='contact'; public $element='contact';
/** /**
* @var string Name of table without prefix where object is stored * @var string Name of table without prefix where object is stored
*/ */
public $table_element='socpeople'; public $table_element='socpeople';
public $ismultientitymanaged = 1; // 0=No test on entity, 1=Test with field entity, 2=Test with link by societe public $ismultientitymanaged = 1; // 0=No test on entity, 1=Test with field entity, 2=Test with link by societe
public $picto = 'contact'; public $picto = 'contact';
@ -131,9 +131,6 @@ class Contact extends CommonObject
public $oldcopy; // To contains a clone of this when we need to save old properties of object public $oldcopy; // To contains a clone of this when we need to save old properties of object
/** /**
* Constructor * Constructor
* *
@ -145,14 +142,15 @@ class Contact extends CommonObject
$this->statut = 1; // By default, status is enabled $this->statut = 1; // By default, status is enabled
} }
// phpcs:disable PEAR.NamingConventions.ValidFunctionName.NotCamelCaps
/** /**
* Load indicators into this->nb for board * Load indicators into this->nb for board
* *
* @return int <0 if KO, >0 if OK * @return int <0 if KO, >0 if OK
*/ */
// phpcs:ignore PEAR.NamingConventions.ValidFunctionName.NotCamelCaps
function load_state_board() function load_state_board()
{ {
// phpcs:enable
global $user; global $user;
$this->nb=array(); $this->nb=array();
@ -475,6 +473,7 @@ class Contact extends CommonObject
} }
// phpcs:disable PEAR.NamingConventions.ValidFunctionName.NotCamelCaps
/** /**
* Retourne chaine DN complete dans l'annuaire LDAP pour l'objet * Retourne chaine DN complete dans l'annuaire LDAP pour l'objet
* *
@ -484,9 +483,9 @@ class Contact extends CommonObject
* 2=Return key only (uid=qqq) * 2=Return key only (uid=qqq)
* @return string DN * @return string DN
*/ */
// phpcs:ignore PEAR.NamingConventions.ValidFunctionName.NotCamelCaps
function _load_ldap_dn($info,$mode=0) function _load_ldap_dn($info,$mode=0)
{ {
// phpcs:enable
global $conf; global $conf;
$dn=''; $dn='';
if ($mode==0) $dn=$conf->global->LDAP_KEY_CONTACTS."=".$info[$conf->global->LDAP_KEY_CONTACTS].",".$conf->global->LDAP_CONTACT_DN; if ($mode==0) $dn=$conf->global->LDAP_KEY_CONTACTS."=".$info[$conf->global->LDAP_KEY_CONTACTS].",".$conf->global->LDAP_CONTACT_DN;
@ -496,14 +495,15 @@ class Contact extends CommonObject
} }
// phpcs:disable PEAR.NamingConventions.ValidFunctionName.NotCamelCaps
/** /**
* Initialise tableau info (tableau des attributs LDAP) * Initialise tableau info (tableau des attributs LDAP)
* *
* @return array Tableau info des attributs * @return array Tableau info des attributs
*/ */
// phpcs:ignore PEAR.NamingConventions.ValidFunctionName.NotCamelCaps
function _load_ldap_info() function _load_ldap_info()
{ {
// phpcs:enable
global $conf,$langs; global $conf,$langs;
$info = array(); $info = array();
@ -570,6 +570,7 @@ class Contact extends CommonObject
} }
// phpcs:disable PEAR.NamingConventions.ValidFunctionName.NotCamelCaps
/** /**
* Update field alert birthday * Update field alert birthday
* *
@ -578,9 +579,9 @@ class Contact extends CommonObject
* @param int $notrigger 0=no, 1=yes * @param int $notrigger 0=no, 1=yes
* @return int <0 if KO, >=0 if OK * @return int <0 if KO, >=0 if OK
*/ */
// phpcs:ignore PEAR.NamingConventions.ValidFunctionName.NotCamelCaps
function update_perso($id, $user=null, $notrigger=0) function update_perso($id, $user=null, $notrigger=0)
{ {
// phpcs:enable
$error=0; $error=0;
$result=false; $result=false;
@ -726,7 +727,7 @@ class Contact extends CommonObject
$this->date_creation = $this->db->jdate($obj->date_creation); $this->date_creation = $this->db->jdate($obj->date_creation);
$this->date_modification = $this->db->jdate($obj->date_modification); $this->date_modification = $this->db->jdate($obj->date_modification);
$this->fk_departement = $obj->fk_departement; // deprecated $this->fk_departement = $obj->fk_departement; // deprecated
$this->state_id = $obj->fk_departement; $this->state_id = $obj->fk_departement;
$this->departement_code = $obj->state_code; // deprecated $this->departement_code = $obj->state_code; // deprecated
@ -852,6 +853,7 @@ class Contact extends CommonObject
} }
} }
// phpcs:disable PEAR.NamingConventions.ValidFunctionName.NotCamelCaps
/** /**
* Load number of elements the contact is used as a link for * Load number of elements the contact is used as a link for
* ref_facturation * ref_facturation
@ -861,9 +863,9 @@ class Contact extends CommonObject
* *
* @return int <0 if KO, >=0 if OK * @return int <0 if KO, >=0 if OK
*/ */
// phpcs:ignore PEAR.NamingConventions.ValidFunctionName.NotCamelCaps
function load_ref_elements() function load_ref_elements()
{ {
// phpcs:enable
// Compte les elements pour lesquels il est contact // Compte les elements pour lesquels il est contact
$sql ="SELECT tc.element, count(ec.rowid) as nb"; $sql ="SELECT tc.element, count(ec.rowid) as nb";
$sql.=" FROM ".MAIN_DB_PREFIX."element_contact as ec, ".MAIN_DB_PREFIX."c_type_contact as tc"; $sql.=" FROM ".MAIN_DB_PREFIX."element_contact as ec, ".MAIN_DB_PREFIX."c_type_contact as tc";
@ -1194,6 +1196,7 @@ class Contact extends CommonObject
return $this->LibStatut($this->statut,$mode); return $this->LibStatut($this->statut,$mode);
} }
// phpcs:disable PEAR.NamingConventions.ValidFunctionName.NotCamelCaps
/** /**
* Renvoi le libelle d'un statut donne * Renvoi le libelle d'un statut donne
* *
@ -1201,9 +1204,9 @@ class Contact extends CommonObject
* @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=libelle long, 1=libelle court, 2=Picto + Libelle court, 3=Picto, 4=Picto + Libelle long, 5=Libelle court + Picto
* @return string Libelle * @return string Libelle
*/ */
// phpcs:ignore PEAR.NamingConventions.ValidFunctionName.NotCamelCaps
function LibStatut($statut,$mode) function LibStatut($statut,$mode)
{ {
// phpcs:enable
global $langs; global $langs;
if ($mode == 0) if ($mode == 0)
@ -1240,15 +1243,16 @@ class Contact extends CommonObject
} }
// phpcs:disable PEAR.NamingConventions.ValidFunctionName.NotCamelCaps
/** /**
* Return translated label of Public or Private * Return translated label of Public or Private
* *
* @param int $statut Type (0 = public, 1 = private) * @param int $statut Type (0 = public, 1 = private)
* @return string Label translated * @return string Label translated
*/ */
// phpcs:ignore PEAR.NamingConventions.ValidFunctionName.NotCamelCaps
function LibPubPriv($statut) function LibPubPriv($statut)
{ {
// phpcs:enable
global $langs; global $langs;
if ($statut=='1') return $langs->trans('ContactPrivate'); if ($statut=='1') return $langs->trans('ContactPrivate');
else return $langs->trans('ContactPublic'); else return $langs->trans('ContactPublic');

View File

@ -70,6 +70,7 @@ class Export
} }
// phpcs:disable PEAR.NamingConventions.ValidFunctionName.NotCamelCaps
/** /**
* Load an exportable dataset * Load an exportable dataset
* *
@ -77,9 +78,9 @@ class Export
* @param string $filter Load a particular dataset only * @param string $filter Load a particular dataset only
* @return int <0 if KO, >0 if OK * @return int <0 if KO, >0 if OK
*/ */
// phpcs:ignore PEAR.NamingConventions.ValidFunctionName.NotCamelCaps
function load_arrays($user,$filter='') function load_arrays($user,$filter='')
{ {
// phpcs:enable
global $langs,$conf,$mysoc; global $langs,$conf,$mysoc;
dol_syslog(get_class($this)."::load_arrays user=".$user->id." filter=".$filter); dol_syslog(get_class($this)."::load_arrays user=".$user->id." filter=".$filter);
@ -208,6 +209,7 @@ class Export
} }
// phpcs:disable PEAR.NamingConventions.ValidFunctionName.NotCamelCaps
/** /**
* Build the sql export request. * Build the sql export request.
* Arrays this->array_export_xxx are already loaded for required datatoexport * Arrays this->array_export_xxx are already loaded for required datatoexport
@ -217,9 +219,9 @@ class Export
* @param array $array_filterValue Filter records on array of value for fields * @param array $array_filterValue Filter records on array of value for fields
* @return string SQL String. Example "select s.rowid as r_rowid, s.status as s_status from ..." * @return string SQL String. Example "select s.rowid as r_rowid, s.status as s_status from ..."
*/ */
// phpcs:ignore PEAR.NamingConventions.ValidFunctionName.NotCamelCaps
function build_sql($indice, $array_selected, $array_filterValue) function build_sql($indice, $array_selected, $array_filterValue)
{ {
// phpcs:enable
// Build the sql request // Build the sql request
$sql=$this->array_export_sql_start[$indice]; $sql=$this->array_export_sql_start[$indice];
$i=0; $i=0;
@ -271,6 +273,7 @@ class Export
return $sql; return $sql;
} }
// phpcs:disable PEAR.NamingConventions.ValidFunctionName.NotCamelCaps
/** /**
* Build the conditionnal string from filter the query * Build the conditionnal string from filter the query
* *
@ -279,9 +282,9 @@ class Export
* @param string $ValueField Value of the field for filter. Must not be '' * @param string $ValueField Value of the field for filter. Must not be ''
* @return string sql string of then field ex : "field='xxx'>" * @return string sql string of then field ex : "field='xxx'>"
*/ */
// phpcs:ignore PEAR.NamingConventions.ValidFunctionName.NotCamelCaps
function build_filterQuery($TypeField, $NameField, $ValueField) function build_filterQuery($TypeField, $NameField, $ValueField)
{ {
// phpcs:enable
//print $TypeField." ".$NameField." ".$ValueField; //print $TypeField." ".$NameField." ".$ValueField;
$InfoFieldList = explode(":", $TypeField); $InfoFieldList = explode(":", $TypeField);
// build the input field on depend of the type of file // build the input field on depend of the type of file
@ -365,6 +368,7 @@ class Export
return $Condition; return $Condition;
} }
// phpcs:disable PEAR.NamingConventions.ValidFunctionName.NotCamelCaps
/** /**
* Build an input field used to filter the query * Build an input field used to filter the query
* *
@ -373,9 +377,9 @@ class Export
* @param string $ValueField Initial value of the field to filter * @param string $ValueField Initial value of the field to filter
* @return string html string of the input field ex : "<input type=text name=... value=...>" * @return string html string of the input field ex : "<input type=text name=... value=...>"
*/ */
// phpcs:ignore PEAR.NamingConventions.ValidFunctionName.NotCamelCaps
function build_filterField($TypeField, $NameField, $ValueField) function build_filterField($TypeField, $NameField, $ValueField)
{ {
// phpcs:enable
global $conf,$langs; global $conf,$langs;
$szFilterField=''; $szFilterField='';
@ -514,6 +518,7 @@ class Export
return $szMsg; return $szMsg;
} }
// phpcs:disable PEAR.NamingConventions.ValidFunctionName.NotCamelCaps
/** /**
* Build export file. * Build export file.
* File is built into directory $conf->export->dir_temp.'/'.$user->id * File is built into directory $conf->export->dir_temp.'/'.$user->id
@ -527,9 +532,9 @@ class Export
* @param string $sqlquery If set, transmit the sql request for select (otherwise, sql request is generated from arrays) * @param string $sqlquery If set, transmit the sql request for select (otherwise, sql request is generated from arrays)
* @return int <0 if KO, >0 if OK * @return int <0 if KO, >0 if OK
*/ */
// phpcs:ignore PEAR.NamingConventions.ValidFunctionName.NotCamelCaps
function build_file($user, $model, $datatoexport, $array_selected, $array_filterValue, $sqlquery = '') function build_file($user, $model, $datatoexport, $array_selected, $array_filterValue, $sqlquery = '')
{ {
// phpcs:enable
global $conf,$langs; global $conf,$langs;
$indice=0; $indice=0;
@ -825,15 +830,16 @@ class Export
} }
} }
// phpcs:disable PEAR.NamingConventions.ValidFunctionName.NotCamelCaps
/** /**
* Output list all export models * Output list all export models
* TODO Move this into a class htmlxxx.class.php * TODO Move this into a class htmlxxx.class.php
* *
* @return void * @return void
*/ */
// phpcs:ignore PEAR.NamingConventions.ValidFunctionName.NotCamelCaps
function list_export_model() function list_export_model()
{ {
// phpcs:enable
global $conf, $langs; global $conf, $langs;
$sql = "SELECT em.rowid, em.field, em.label, em.type, em.filter"; $sql = "SELECT em.rowid, em.field, em.label, em.type, em.filter";

View File

@ -461,14 +461,15 @@ class LoanSchedule extends CommonObject
} }
} }
// phpcs:disable PEAR.NamingConventions.ValidFunctionName.NotCamelCaps
/** /**
* trans_paiment * trans_paiment
* *
* @return void * @return void
*/ */
// phpcs:disable PEAR.NamingConventions.ValidFunctionName.NotCamelCaps
function trans_paiment() function trans_paiment()
{ {
// phpcs:enable
require_once DOL_DOCUMENT_ROOT.'/loan/class/loan.class.php'; require_once DOL_DOCUMENT_ROOT.'/loan/class/loan.class.php';
require_once DOL_DOCUMENT_ROOT.'/core/lib/loan.lib.php'; require_once DOL_DOCUMENT_ROOT.'/core/lib/loan.lib.php';
require_once DOL_DOCUMENT_ROOT.'/core/lib/date.lib.php'; require_once DOL_DOCUMENT_ROOT.'/core/lib/date.lib.php';