Debug v20

This commit is contained in:
Laurent Destailleur
2024-05-05 18:04:46 +02:00
parent a6f15b6a19
commit fa86f753f6
4 changed files with 21 additions and 9 deletions

View File

@@ -234,10 +234,16 @@ class FormAdmin
$prefix = '3';
}
$morelabel = '';
if (preg_match('/^auguria/i', $file)) {
$morelabel .= ' <span class="opacitymedium">('.$langs->trans("Unstable").')</span>';
}
if ($file == $selected) {
$menuarray[$prefix.'_'.$file] = '<option value="'.$file.'" selected>'.$filelib.'</option>';
$menuarray[$prefix.'_'.$file] = '<option value="'.$file.'" selected data-html="'.dol_escape_htmltag($filelib.$morelabel).'">'.$filelib.$morelabel;
$menuarray[$prefix.'_'.$file] .= '</option>';
} else {
$menuarray[$prefix.'_'.$file] = '<option value="'.$file.'">'.$filelib.'</option>';
$menuarray[$prefix.'_'.$file] = '<option value="'.$file.'" data-html="'.dol_escape_htmltag($filelib.$morelabel).'">'.$filelib.$morelabel;
$menuarray[$prefix.'_'.$file] .= '</option>';
}
}
}
@@ -254,6 +260,7 @@ class FormAdmin
foreach ($menuarray as $key => $val) {
$tab = explode('_', $key);
$newprefix = $tab[0];
if ($newprefix == '1' && (getDolGlobalInt('MAIN_FEATURES_LEVEL') < 1)) {
continue;
}
@@ -262,7 +269,7 @@ class FormAdmin
}
if ($newprefix != $oldprefix) { // Add separators
// Affiche titre
print '<option value="-1" disabled>';
print '<option value="-2" disabled>';
if ($newprefix == '0') {
print '-- '.$langs->trans("VersionRecommanded").' --';
}
@@ -278,10 +285,13 @@ class FormAdmin
print '</option>';
$oldprefix = $newprefix;
}
print $val."\n"; // Show menu entry
print $val."\n"; // Show menu entry ($val contains the <option> tags
}
print '</select>';
print ajax_combobox($htmlname);
return;
}