Merge branch '18.0' of git@github.com:Dolibarr/dolibarr.git into 19.0

This commit is contained in:
Laurent Destailleur
2025-11-12 21:50:04 +01:00
4 changed files with 11 additions and 9 deletions

View File

@@ -8232,6 +8232,8 @@ class Form
if ($tmpfieldstoshow) {
$fieldstoshow = $tmpfieldstoshow;
}
} elseif ($objecttmp->element === 'category') {
$fieldstoshow = 't.label';
} else {
// For backward compatibility
$objecttmp->fields['ref'] = array('type' => 'varchar(30)', 'label' => 'Ref', 'showoncombobox' => 1);

View File

@@ -259,7 +259,7 @@ if (empty($reshook) && !empty($object->table_element) && isset($extrafields->att
} else {
//var_dump($tmpkeyextra.'-'.$value.'-'.$object->table_element);
print $extrafields->showOutputField($tmpkeyextra, $value, '', $object->table_element);
print '<input type="hidden" value="' . $value . '" name="options_' . $tmpkeyextra . '" id="options_' . $tmpkeyextra . '"/>'; // it's needed when to get parent value when extra-field list depend on parent extra-field list
print '<input type="hidden" value="' . dol_escape_htmltag($value) . '" name="options_' . dol_escape_htmltag($tmpkeyextra) . '" id="options_' . dol_escape_htmltag($tmpkeyextra) . '"/>'; // it's needed when to get parent value when extra-field list depend on parent extra-field list
}
print '</td>';

View File

@@ -86,6 +86,7 @@ $search_array_options = $extrafields->getOptionalsFromPost($object->table_elemen
// Load object
include DOL_DOCUMENT_ROOT.'/core/actions_fetchobject.inc.php'; // Must be include, not include_once.
$upload_dir = $conf->eventorganization->multidir_output[isset($object->entity) ? $object->entity : 1];
if ($id > 0 || !empty($ref)) {
$upload_dir = $conf->eventorganization->multidir_output[$object->entity ? $object->entity : $conf->entity]."/conferenceorbooth/".get_exdir(0, 0, 0, 1, $object);
}
@@ -96,7 +97,6 @@ $permissiontoadd = $user->rights->eventorganization->write; // Used by the inclu
$permissiontodelete = $user->rights->eventorganization->delete || ($permissiontoadd && isset($object->status) && $object->status == $object::STATUS_DRAFT);
$permissionnote = $user->rights->eventorganization->write; // Used by the include of actions_setnotes.inc.php
$permissiondellink = $user->rights->eventorganization->write; // Used by the include of actions_dellink.inc.php
$upload_dir = $conf->eventorganization->multidir_output[isset($object->entity) ? $object->entity : 1];
// Security check
if ($user->socid > 0) {

View File

@@ -1403,13 +1403,13 @@ if ($reshook == 0) { //add buttons
$menus[$r++] = $butmenu;
}
}
} elseif ($reshook == 1) {
$r = 0; //replace buttons
if (is_array($hookmanager->resArray)) {
foreach ($hookmanager->resArray as $resArray) {
foreach ($resArray as $butmenu) {
$menus[$r++] = $butmenu;
}
}
} elseif ($reshook == 1) {
$r = 0; //replace buttons
if (is_array($hookmanager->resArray) ) {
foreach ($hookmanager->resArray as $resArray) {
foreach ($resArray as $butmenu) {
$menus[$r++] = $butmenu;
}
}
}