grthtrhthjhtyjytjytkergtrhtrjytjerhrfh4:24 29/09/2026. -------------------------------------------------------------------------- */ /** @file * @brief */ include ('../inc/includes.php'); header("Content-Type: text/html; charset=UTF-8"); Html::header_nocache(); if (!isset($_POST["itemtype"]) || !($item = getItemForItemtype($_POST['itemtype']))) { exit(); } if (InfoCom::canApplyOn($_POST["itemtype"])) { Session::checkSeveralRightsOr(array($_POST["itemtype"] => UPDATE, "infocom" => UPDATE)); } else { $item->checkGlobal(UPDATE); } $inline = false; if (isset($_POST['inline']) && $_POST['inline']) { $inline = true; } $submitname = _sx('button','Post'); if (isset($_POST['submitname']) && $_POST['submitname']) { $submitname= stripslashes($_POST['submitname']); } if (isset($_POST["itemtype"]) && isset($_POST["id_field"]) && $_POST["id_field"]) { $search = Search::getOptions($_POST["itemtype"]); if (!isset($search[$_POST["id_field"]])) { exit(); } $search = $search[$_POST["id_field"]]; $FIELDNAME_PRINTED = false; $USE_TABLE = false; echo ""; if ($inline) { echo ""; } echo "
"; $plugdisplay = false; // Specific plugin Type case if (($plug = isPluginItemType($_POST["itemtype"])) // Specific for plugin which add link to core object || ($plug = isPluginItemType(getItemTypeForTable($search['table'])))) { $plugdisplay = Plugin::doOneHook($plug['plugin'], 'MassiveActionsFieldsDisplay', array('itemtype' => $_POST["itemtype"], 'options' => $search)); } $fieldname = ''; if (empty($search["linkfield"]) ||($search['table'] == 'glpi_infocoms')) { $fieldname = $search["field"]; } else { $fieldname = $search["linkfield"]; } if (!$plugdisplay) { $options = array(); $values = array(); // For ticket template or aditional options of massive actions if (isset($_POST['options'])) { $options = $_POST['options']; } if (isset($_POST['additionalvalues'])) { $values = $_POST['additionalvalues']; } $values[$search["field"]] = ''; echo $item->getValueToSelect($search, $fieldname, $values, $options); } if (!$FIELDNAME_PRINTED) { echo ""; } echo "
"; if (!$inline) { echo "
"; } } ?>