mirror of
https://github.com/Dolibarr/dolibarr.git
synced 2025-12-07 01:58:09 +01:00
Standardize code
This commit is contained in:
@@ -3316,10 +3316,10 @@ function print_liste_field_titre($name, $file="", $field="", $begin="", $morepar
|
||||
* @param string $field Field to use for new sorting. Empty if this field is not sortable.
|
||||
* @param string $begin ("" by defaut)
|
||||
* @param string $moreparam Add more parameters on sort url links ("" by default)
|
||||
* @param string $moreattrib Add more attributes on th ("" by defaut). To add more css class, use param $prefix.
|
||||
* @param string $moreattrib Add more attributes on th ("" by defaut, example: 'align="center"'). To add more css class, use param $prefix.
|
||||
* @param string $sortfield Current field used to sort (Ex: 'd.datep,d.id')
|
||||
* @param string $sortorder Current sort order (Ex: 'asc,desc')
|
||||
* @param string $prefix Prefix for css. Use space after prefix to add your own CSS tag.
|
||||
* @param string $prefix Prefix for css. Use space after prefix to add your own CSS tag, for example 'mycss '.
|
||||
* @param string $disablesortlink 1=Disable sort link
|
||||
* @param string $tooltip Tooltip
|
||||
* @return string
|
||||
@@ -3342,7 +3342,6 @@ function getTitleFieldOfList($name, $thead=0, $file="", $field="", $begin="", $m
|
||||
$field1=trim($tmpfield[0]); // If $field is 'd.datep,d.id', it becomes 'd.datep'
|
||||
|
||||
//var_dump('field='.$field.' field1='.$field1.' sortfield='.$sortfield.' sortfield1='.$sortfield1);
|
||||
|
||||
// If field is used as sort criteria we use a specific css class liste_titre_sel
|
||||
// Example if (sortfield,field)=("nom","xxx.nom") or (sortfield,field)=("nom","nom")
|
||||
if ($field1 && ($sortfield1 == $field1 || $sortfield1 == preg_replace("/^[^\.]+\./","",$field1))) $out.= '<'.$tag.' class="'.$prefix.'liste_titre_sel" '. $moreattrib.'>';
|
||||
|
||||
Reference in New Issue
Block a user