This commit is contained in:
Laurent Destailleur 2025-12-13 11:04:16 +01:00
parent 2d0c554011
commit 7bd0a8a76e
2 changed files with 3 additions and 3 deletions

View file

@ -1024,7 +1024,7 @@ foreach ($fieldlist as $field => $value) {
print $form->select_dolusers($search_fk_user, 'search_fk_user', 1, null, 0, ($user->admin ? '' : 'hierarchyme'), array(), '0', 0, 0, '', 0, '', 'maxwidth100', 1);
print '</td>';
} elseif ($value == 'topic') {
print '<td class="liste_titre"><input type="text" name="search_topic" value="'.dol_escape_htmltag($search_topic).'" spellcheck="false"></td>';
print '<td class="liste_titre"><input type="text" class="maxwidth150" name="search_topic" value="'.dol_escape_htmltag($search_topic).'" spellcheck="false"></td>';
} elseif ($value == 'type_template') {
print '<td class="liste_titre center">';
// @phan-suppress-next-line PhanPluginSuspiciousParamOrder
@ -1594,7 +1594,7 @@ function fieldList($fieldlist, $obj = null, $tabname = '', $context = '')
}
print '<td'.($classtd ? ' class="'.$classtd.'"' : '').'>';
if ($value == 'private' && $context != 'preview') {
if (in_array($value, array('defaultfortype', 'private')) && $context != 'preview') {
if (empty($user->admin)) {
// @phan-suppress-next-line PhanPluginSuspiciousParamPosition
print $form->selectyesno($value, GETPOSTISSET($value) ? GETPOSTINT($value) : (($context != 'add' && isset($obj->$value)) ? $obj->$value : '1'), 1, false, 0, 1);

View file

@ -10735,7 +10735,7 @@ class Form
* @param string $labelno Label for No
* @return string See option
*/
public function selectyesno($htmlname, $value = '', $option = 0, $disabled = false, $useempty = 0, $addjscombo = 0, $morecss = 'width75', $labelyes = 'Yes', $labelno = 'No')
public function selectyesno($htmlname, $value = '', $option = 0, $disabled = false, $useempty = 0, $addjscombo = 0, $morecss = 'yesno width75', $labelyes = 'Yes', $labelno = 'No')
{
global $langs;