Fix doxygen and warnings

This commit is contained in:
Laurent Destailleur 2022-12-30 01:58:13 +01:00
parent 3dfe09d1fe
commit b8092f1eae
6 changed files with 9 additions and 13 deletions

View File

@ -844,10 +844,10 @@ if ($mode == 'common' || $mode == 'commonkanban') {
}
}
}
} elseif (preg_match('/^([^@]+)@([^@]+)$/i', $objMod->config_page_url, $regs)) {
} elseif (preg_match('/^([^@]+)@([^@]+)$/i', (string) $objMod->config_page_url, $regs)) {
$codetoconfig .= '<a class="valignmiddle" href="'.dol_buildpath('/'.$regs[2].'/admin/'.$regs[1], 1).'?save_lastsearch_values=1&backtopage='.urlencode($backtourl).'" title="'.$langs->trans("Setup").'">'.img_picto($langs->trans("Setup"), "setup", 'style="padding-right: 6px"', false, 0, 0, '', 'fa-15').'</a>';
} else {
$codetoconfig .= '<a class="valignmiddle" href="'.$objMod->config_page_url.'?save_lastsearch_values=1&backtopage='.urlencode($backtourl).'" title="'.$langs->trans("Setup").'">'.img_picto($langs->trans("Setup"), "setup", 'style="padding-right: 6px"', false, 0, 0, '', 'fa-15').'</a>';
$codetoconfig .= '<a class="valignmiddle" href="'.((string) $objMod->config_page_url).'?save_lastsearch_values=1&backtopage='.urlencode($backtourl).'" title="'.$langs->trans("Setup").'">'.img_picto($langs->trans("Setup"), "setup", 'style="padding-right: 6px"', false, 0, 0, '', 'fa-15').'</a>';
}
} else {
$codetoconfig .= img_picto($langs->trans("NothingToSetup"), "setup", 'class="opacitytransp" style="padding-right: 6px"', false, 0, 0, '', 'fa-15');

View File

@ -7720,7 +7720,7 @@ class Form
}
}
if (!is_object($objecttmp)) {
dol_syslog('Error bad setup of type for field '.$InfoFieldList, LOG_WARNING);
dol_syslog('Error bad setup of type for field '.join(',', $InfoFieldList), LOG_WARNING);
return 'Error bad setup of type for field '.join(',', $InfoFieldList);
}
@ -9870,7 +9870,7 @@ class Form
method: "POST",
dataType: "json",
data: { fk_c_exp_tax_cat: $(this).val(), token: \''.currentToken().'\' },
url: "'.(DOL_URL_ROOT.'/expensereport/ajax/ajaxik.php?'.$params).'",
url: "'.(DOL_URL_ROOT.'/expensereport/ajax/ajaxik.php?'.join('&', $params)).'",
}).done(function( data, textStatus, jqXHR ) {
console.log(data);
if (typeof data.up != "undefined") {

View File

@ -78,10 +78,6 @@ class modHoliday extends DolibarrModules
// Config pages
$this->config_page_url = array("holiday.php");
// Config pages. Put here list of php page names stored in admmin directory used to setup module.
// $this->config_page_url = array("holiday.php?leftmenu=setup@holiday");
// Dependencies
$this->hidden = false; // A condition to hide module
$this->depends = array(); // List of module class names as string that must be enabled if this module is enabled

View File

@ -1208,7 +1208,7 @@ if ($resql) {
include DOL_DOCUMENT_ROOT.'/core/tpl/massactions_pre.tpl.php';
if ($massaction == 'prevalidate') {
print $form->formconfirm($_SERVER["PHP_SELF"].$fieldstosearchall, $langs->trans("ConfirmMassValidation"), $langs->trans("ConfirmMassValidationQuestion"), "validate", null, '', 0, 200, 500, 1);
print $form->formconfirm($_SERVER["PHP_SELF"], $langs->trans("ConfirmMassValidation"), $langs->trans("ConfirmMassValidationQuestion"), "validate", null, '', 0, 200, 500, 1);
}
if ($massaction == 'createbills') {

View File

@ -114,7 +114,7 @@ class KnowledgeManagement extends DolibarrApi
}
if ($result < 0) {
throw new RestException(503, 'Error when retrieve category list : '.array_merge(array($categories->error), $categories->errors));
throw new RestException(503, 'Error when retrieve category list : '.join(',', array_merge(array($categories->error), $categories->errors)));
}
return $result;

View File

@ -595,7 +595,7 @@ class Products extends DolibarrApi
}
if ($result < 0) {
throw new RestException(503, 'Error when retrieve category list : '.array_merge(array($categories->error), $categories->errors));
throw new RestException(503, 'Error when retrieve category list : '.join(',', array_merge(array($categories->error), $categories->errors)));
}
return $result;
@ -628,7 +628,7 @@ class Products extends DolibarrApi
}
if ($result < 0) {
throw new RestException(503, 'Error when retrieve prices list : '.array_merge(array($this->product->error), $this->product->errors));
throw new RestException(503, 'Error when retrieve prices list : '.join(',', array_merge(array($this->product->error), $this->product->errors)));
}
return array(
@ -719,7 +719,7 @@ class Products extends DolibarrApi
}
if ($result < 0) {
throw new RestException(503, 'Error when retrieve prices list : '.array_merge(array($this->product->error), $this->product->errors));
throw new RestException(503, 'Error when retrieve prices list : '.join(',', array_merge(array($this->product->error), $this->product->errors)));
}
return array(