getSolvedStatusArray() static public method

Get the ITIL object solved status list
static public getSolvedStatusArray ( ) : an
return an array
Ejemplo n.º 1
0
 /**
  * Show tickets for a projecttask
  *
  * @param $projecttask ProjectTask object
  **/
 static function showForProjectTask(ProjectTask $projecttask)
 {
     global $DB, $CFG_GLPI;
     $ID = $projecttask->getField('id');
     if (!$projecttask->can($ID, READ)) {
         return false;
     }
     $canedit = $projecttask->canEdit($ID);
     $rand = mt_rand();
     $query = "SELECT DISTINCT `glpi_projecttasks_tickets`.`id` AS linkID,\n                                `glpi_tickets`.*\n                FROM `glpi_projecttasks_tickets`\n                LEFT JOIN `glpi_tickets`\n                     ON (`glpi_projecttasks_tickets`.`tickets_id` = `glpi_tickets`.`id`)\n                WHERE `glpi_projecttasks_tickets`.`projecttasks_id` = '{$ID}'\n                ORDER BY `glpi_tickets`.`name`";
     $result = $DB->query($query);
     $tickets = array();
     $used = array();
     if ($numrows = $DB->numrows($result)) {
         while ($data = $DB->fetch_assoc($result)) {
             $tickets[$data['id']] = $data;
             $used[$data['id']] = $data['id'];
         }
     }
     if ($canedit) {
         echo "<div class='firstbloc'>";
         echo "<form name='projecttaskticket_form{$rand}' id='projecttaskticket_form{$rand}'\n                method='post' action='" . Toolbox::getItemTypeFormURL(__CLASS__) . "'>";
         echo "<table class='tab_cadre_fixe'>";
         echo "<tr class='tab_bg_2'><th colspan='3'>" . __('Add a ticket') . "</th></tr>";
         echo "<tr class='tab_bg_2'><td class='right'>";
         echo "<input type='hidden' name='projecttasks_id' value='{$ID}'>";
         $condition = "`glpi_tickets`.`status`\n                        NOT IN ('" . implode("', '", array_merge(Ticket::getSolvedStatusArray(), Ticket::getClosedStatusArray())) . "')";
         Ticket::dropdown(array('used' => $used, 'entity' => $projecttask->getEntityID(), 'entity_sons' => $projecttask->isRecursive(), 'condition' => $condition, 'displaywith' => array('id')));
         echo "</td><td width='20%'>";
         echo "<a href='" . Toolbox::getItemTypeFormURL('Ticket') . "?_projecttasks_id={$ID}'>";
         _e('Create a ticket from this task');
         echo "</a>";
         echo "</td><td class='center'>";
         echo "<input type='submit' name='add' value=\"" . _sx('button', 'Add') . "\" class='submit'>";
         echo "</td></tr>";
         echo "</table>";
         Html::closeForm();
         echo "</div>";
     }
     echo "<div class='spaced'>";
     if ($canedit && $numrows) {
         Html::openMassiveActionsForm('mass' . __CLASS__ . $rand);
         $massiveactionparams = array('num_displayed' => $numrows, 'container' => 'mass' . __CLASS__ . $rand);
         Html::showMassiveActions($massiveactionparams);
     }
     echo "<table class='tab_cadre_fixehov'>";
     echo "<tr><th colspan='12'>" . Ticket::getTypeName($numrows) . "</th>";
     echo "</tr>";
     if ($numrows) {
         Ticket::commonListHeader(Search::HTML_OUTPUT, 'mass' . __CLASS__ . $rand);
         Session::initNavigateListItems('Ticket', sprintf(__('%1$s = %2$s'), ProjectTask::getTypeName(1), $projecttask->fields["name"]));
         $i = 0;
         foreach ($tickets as $data) {
             Session::addToNavigateListItems('Ticket', $data["id"]);
             Ticket::showShort($data['id'], array('followups' => false, 'row_num' => $i, 'type_for_massiveaction' => __CLASS__, 'id_for_massiveaction' => $data['linkID']));
             $i++;
         }
     }
     echo "</table>";
     if ($canedit && $numrows) {
         $massiveactionparams['ontop'] = false;
         Html::showMassiveActions($massiveactionparams);
         Html::closeForm();
     }
     echo "</div>";
 }
Ejemplo n.º 2
0
 static function afterUpdate(Ticket $ticket)
 {
     // Toolbox::logDebug("PluginBehaviorsTicket::afterUpdate(), Ticket=", $ticket);
     $config = PluginBehaviorsConfig::getInstance();
     if ($config->getField('add_notif') && in_array('status', $ticket->updates) && in_array($ticket->oldvalues['status'], array(implode("','", Ticket::getSolvedStatusArray()), implode("','", Ticket::getclosedStatusArray()))) && !in_array($ticket->input['status'], array(implode("','", Ticket::getSolvedStatusArray()), implode("','", Ticket::getclosedStatusArray())))) {
         NotificationEvent::raiseEvent('plugin_behaviors_ticketreopen', $ticket);
     }
 }
Ejemplo n.º 3
0
 static function pdfStat(PluginPdfSimplePDF $pdf, Ticket $job)
 {
     $pdf->setColumnsSize(100);
     $pdf->displayTitle("<b>" . _n('Date', 'Dates', 2) . "</b>");
     $pdf->setColumnsSize(50, 50);
     $pdf->displayLine(sprintf(__('%1$s: %2$s'), __('Opening date'), Html::convDateTime($job->fields['date'])));
     $pdf->displayLine(sprintf(__('%1$s: %2$s'), __('Due date'), Html::convDateTime($job->fields['due_date'])));
     if (in_array($job->fields["status"], $job->getSolvedStatusArray()) || in_array($job->fields["status"], $job->getClosedStatusArray())) {
         $pdf->displayLine(sprintf(__('%1$s: %2$s'), __('Solution date'), Html::convDateTime($job->fields['solvedate'])));
     }
     if (in_array($job->fields["status"], $job->getClosedStatusArray())) {
         $pdf->displayLine(sprintf(__('%1$s: %2$s'), __('Closing date'), Html::convDateTime($job->fields['closedate'])));
     }
     $pdf->setColumnsSize(100);
     $pdf->displayTitle("<b>" . _n('Time', 'Times', 2) . "</b>");
     $pdf->setColumnsSize(50, 50);
     if ($job->fields['takeintoaccount_delay_stat'] > 0) {
         $pdf->displayLine(sprintf(__('%1$s: %2$s'), __('Take into account'), Html::clean(Html::timestampToString($job->fields['takeintoaccount_delay_stat'], 0))));
     }
     if (in_array($job->fields["status"], $job->getSolvedStatusArray()) || in_array($job->fields["status"], $job->getClosedStatusArray())) {
         if ($job->fields['solve_delay_stat'] > 0) {
             $pdf->displayLine(sprintf(__('%1$s: %2$s'), __('Solution'), Html::clean(Html::timestampToString($job->fields['solve_delay_stat'], 0))));
         }
     }
     if (in_array($job->fields["status"], $job->getClosedStatusArray())) {
         if ($job->fields['close_delay_stat'] > 0) {
             $pdf->displayLine(sprintf(__('%1$s: %2$s'), __('Closing'), Html::clean(Html::timestampToString($job->fields['close_delay_stat'], 0))));
         }
     }
     if ($job->fields['waiting_duration'] > 0) {
         $pdf->displayLine(sprintf(__('%1$s: %2$s'), __('Pending'), Html::clean(Html::timestampToString($job->fields['waiting_duration'], 0))));
     }
     $pdf->displaySpace();
 }
Ejemplo n.º 4
0
 /**
  * List the tickets for an authenticated user
  *
  * @param $params    array of options (author, group, category, status, startdate, enddate, itemtype)
  * @param $protocol        the communication protocol used
  *
  * @return array of hashtable
  **/
 static function methodListTickets($params, $protocol)
 {
     global $DB, $CFG_GLPI;
     if (isset($params['help'])) {
         return array('count' => 'bool,optional', 'start' => 'integer,optional', 'limit' => 'integer,optional', 'user' => 'integer,optional', 'recipient' => 'integer,optional', 'mine' => 'bool,optional', 'group' => 'integer,optional', 'mygroups' => 'bool,optional', 'category' => 'integer,optional', 'status' => 'integer,optional', 'startdate' => 'datetime,optional', 'enddate' => 'datetime,optional', 'itemtype' => 'string,optional', 'item' => 'integer,optional', 'entity' => 'integer,optional', 'satisfaction' => 'integer,optional', 'approval' => 'text,optional', 'approver' => 'integer,optional', 'id2name' => 'bool,optional', 'order' => 'array,optional', 'help' => 'bool,optional');
     }
     if (!Session::getLoginUserID()) {
         return self::Error($protocol, WEBSERVICES_ERROR_NOTAUTHENTICATED);
     }
     $resp = array();
     $start = 0;
     if (isset($params['start']) && is_numeric($params['start'])) {
         $start = $params['start'];
     }
     $limit = $_SESSION['glpilist_limit'];
     if (isset($params['limit']) && is_numeric($params['limit'])) {
         $limit = $params['limit'];
     }
     $where = $join = '';
     // User (victim)
     if (isset($params['user'])) {
         if (!is_numeric($params['user']) || $params['user'] < 0) {
             return self::Error($protocol, WEBSERVICES_ERROR_BADPARAMETER, '', 'user');
         }
         if (Session::haveRight('show_all_ticket', '1') || Session::haveRight('show_group_ticket', '1') || $params['user'] == Session::getLoginUserID()) {
             // restrict to author parameter
             $where = " AND `glpi_tickets_users_request`.`users_id` = '" . $params['user'] . "'";
         } else {
             return self::Error($protocol, WEBSERVICES_ERROR_NOTALLOWED);
         }
     } else {
         if (Session::haveRight('show_all_ticket', '1') || Session::haveRight('show_group_ticket', '1')) {
             $where = '';
             // Restrict will come from group (if needed)
         } else {
             // Only connected user's tickets'
             $where = " AND `glpi_tickets_users_request`.`users_id`\n                           = '" . Session::getLoginUserID() . "'";
         }
     }
     // Group
     if (isset($params['group'])) {
         if (!is_numeric($params['group']) || $params['group'] < 0) {
             return self::Error($protocol, WEBSERVICES_ERROR_BADPARAMETER, '', 'group');
         }
         if (Session::haveRight('show_all_ticket', '1') || Session::haveRight('show_group_ticket', '1') && in_array($params['group'], $_SESSION['glpigroups'])) {
             // restrict to group parameter
             $where = " AND `glpi_groups_tickets_request`.`groups_id` = '" . $params['group'] . "'";
         } else {
             return self::Error($protocol, WEBSERVICES_ERROR_NOTALLOWED);
         }
     } else {
         if (Session::haveRight('show_group_ticket', '1') && !Session::haveRight('show_all_ticket', '1')) {
             // Connected user's group'
             if (count($_SESSION['glpigroups']) > 0) {
                 $where = " AND `glpi_groups_tickets_request`.`groups_id`\n                              IN (" . implode(',', $_SESSION['glpigroups']) . ")";
             } else {
                 $where = " AND `glpi_tickets_users_request`.`users_id`\n                              = '" . Session::getLoginUserID() . "'";
             }
         }
     }
     // Security
     if (empty($where) && !Session::haveRight('show_all_ticket', '1')) {
         return self::Error($protocol, WEBSERVICES_ERROR_NOTALLOWED, '', 'profil');
     }
     // Recipient (person creating the ticket)
     if (isset($params['recipient'])) {
         if (!is_numeric($params['recipient']) || $params['recipient'] < 0) {
             return self::Error($protocol, WEBSERVICES_ERROR_BADPARAMETER, '', 'recipient');
         }
         // restrict to recipient parameter
         $where = " AND `users_id_recipient`='" . $params['recipient'] . "'";
     }
     // Mine (user or recipient for the ticket)
     if (isset($params['mine'])) {
         $where = " AND (`glpi_tickets_users_request`.`users_id` = '" . Session::getLoginUserID() . "'\n                         OR `users_id_recipient` = '" . Session::getLoginUserID() . "')";
     }
     // Mygroups
     if (isset($param['mygroups'])) {
         $where = " AND `glpi_groups_tickets`.`groups_id`\n                        IN (" . implode(',', $_SESSION['glpigroups']) . ")";
     }
     // Entity
     if (isset($params['entity'])) {
         if (!Session::haveAccessToEntity($params['entity'])) {
             return self::Error($protocol, WEBSERVICES_ERROR_NOTALLOWED, '', 'entity');
         }
         $where = getEntitiesRestrictRequest("WHERE", "glpi_tickets", '', $params['entity']) . $where;
     } else {
         $where = getEntitiesRestrictRequest("WHERE", "glpi_tickets") . $where;
     }
     // Category
     if (isset($params['category'])) {
         if (!is_numeric($params['category']) || $params['category'] <= 0) {
             return self::Error($protocol, WEBSERVICES_ERROR_BADPARAMETER, '', 'category');
         }
         $where .= " AND " . getRealQueryForTreeItem("glpi_itilcategories", $params['category'], "glpi_tickets.itilcategories_id");
     }
     if (isset($params['approval']) || isset($params['approver'])) {
         $join .= "INNER JOIN `glpi_ticketvalidations`\n                         ON (`glpi_tickets`.`id` = `glpi_ticketvalidations`.`tickets_id` ) ";
         if (isset($params['approver']) && is_numeric($params['approver'])) {
             $where .= " AND `glpi_ticketvalidations`.`users_id_validate`=" . $params['approver'];
         }
         $tabstatus = TicketValidation::getAllStatusArray();
         if (isset($params['approval']) && isset($tabstatus[$params['approval']])) {
             $where .= " AND `glpi_ticketvalidations`.`status`='" . $params['approval'] . "'";
         }
     }
     if (isset($params['satisfaction'])) {
         $join .= "INNER JOIN `glpi_ticketsatisfactions`\n                        ON (`glpi_tickets`.`id` = `glpi_ticketsatisfactions`.`tickets_id` ) ";
         switch ($params['satisfaction']) {
             case 1:
                 $where .= " AND `glpi_ticketsatisfactions`.`date_answered` IS NULL";
                 break;
             case 2:
                 $where .= " AND `glpi_ticketsatisfactions`.`date_answered` IS NOT NULL";
                 break;
             default:
                 // survey exists (by Inner Join)
         }
         $params['status'] = Ticket::CLOSED;
     }
     // Status
     if (isset($params['status'])) {
         if (!in_array($params['status'], Ticket::getAllowedStatusArray(true))) {
             return self::Error($protocol, WEBSERVICES_ERROR_BADPARAMETER, '', 'status');
         }
         switch ($params['status']) {
             case 'all':
                 // No restriction
                 break;
             case 'notclosed':
                 $status = Ticket::getAllStatusArray();
                 unset($status[CLOSED]);
                 $where .= " AND `glpi_tickets`.`status` IN ('" . implode("','", $status) . "') ";
                 break;
             case 'notold':
                 $status = Ticket::getAllStatusArray();
                 unset($status[SOLVED], $status[CLOSED]);
                 $where .= " AND `glpi_tickets`.`status` IN ('" . implode("','", $status) . "') ";
                 break;
             case 'old':
                 $status = array_merge(Ticket::getSolvedStatusArray(), Ticket::getClosedStatusArray());
                 $where .= " AND `glpi_tickets`.`status` IN ('" . implode("','", $status) . "') ";
                 break;
             case 'process':
                 $status = Ticket::getProcessStatusArray();
                 $where .= " AND `glpi_tickets`.`status` IN ('" . implode("','", $status) . "') ";
                 break;
             default:
                 $where .= " AND `glpi_tickets`.`status` = '" . $params['status'] . "' ";
         }
     }
     // Dates
     if (isset($params["startdate"])) {
         if (preg_match(WEBSERVICES_REGEX_DATETIME, $params["startdate"]) || preg_match(WEBSERVICES_REGEX_DATE, $params["startdate"])) {
             $where .= " AND `glpi_tickets`.`date` >= '" . $params['startdate'] . "' ";
         } else {
             return self::Error($protocol, WEBSERVICES_ERROR_BADPARAMETER, '', 'date');
         }
     }
     if (isset($params["enddate"])) {
         if (preg_match(WEBSERVICES_REGEX_DATETIME, $params["enddate"]) || preg_match(WEBSERVICES_REGEX_DATE, $params["enddate"])) {
             $where .= " AND `glpi_tickets`.`date` <= '" . $params['enddate'] . "' ";
         } else {
             return self::Error($protocol, WEBSERVICES_ERROR_BADPARAMETER, '', 'date');
         }
     }
     if (isset($params['itemtype'])) {
         if (!empty($params['itemtype']) && !class_exists($params['itemtype'])) {
             return self::Error($protocol, WEBSERVICES_ERROR_BADPARAMETER, '', 'itemtype');
         }
         $where .= " AND `glpi_tickets`.`itemtype`='" . $params['itemtype'] . "'";
     }
     if (isset($params['item'])) {
         if (!isset($params['itemtype'])) {
             return self::Error($protocol, WEBSERVICES_ERROR_MISSINGPARAMETER, '', 'itemtype');
         }
         if (!is_numeric($params['item']) || $params['item'] <= 0) {
             return self::Error($protocol, WEBSERVICES_ERROR_BADPARAMETER, '', 'item');
         }
         $where .= " AND `glpi_tickets`.`items_id`='" . $params['item'] . "'";
     }
     $orders = array();
     if (isset($params['order'])) {
         if (is_array($params['order'])) {
             $tab = $params['order'];
         } else {
             $tab = array($params['order'] => 'DESC');
         }
         foreach ($tab as $key => $val) {
             if ($val != 'ASC') {
                 $val = 'DESC';
             }
             $sqlkey = array('id' => '`glpi_tickets`.`id`', 'date' => '`glpi_tickets`.`date`', 'closedate' => '`glpi_tickets`.`closedate`', 'date_mod' => '`glpi_tickets`.`date_mod`', 'status' => '`glpi_tickets`.`status`', 'entities_id' => '`glpi_tickets`.`entities_id`', 'priority' => '`glpi_tickets`.`priority`');
             if (isset($sqlkey[$key])) {
                 $orders[] = $sqlkey[$key] . " {$val}";
             } else {
                 return self::Error($protocol, WEBSERVICES_ERROR_BADPARAMETER, '', 'order=$key');
             }
         }
     }
     if (count($orders)) {
         $order = implode(',', $orders);
     } else {
         $order = "`glpi_tickets`.`date_mod` DESC";
     }
     $resp = array();
     if (isset($params['count'])) {
         $query = "SELECT COUNT(DISTINCT `glpi_tickets`.`id`) AS count\n                   FROM `glpi_tickets`\n                   {$join}\n                   LEFT JOIN `glpi_tickets_users` AS glpi_tickets_users_request\n                        ON (`glpi_tickets`.`id` = `glpi_tickets_users_request`.`tickets_id`\n                            AND `glpi_tickets_users_request`.`type` = 1)\n                   LEFT JOIN `glpi_groups_tickets` AS glpi_groups_tickets_request\n                        ON (`glpi_tickets`.`id` = `glpi_groups_tickets_request`.`tickets_id`\n                            AND `glpi_groups_tickets_request`.`type` = 1 )\n                   {$where}";
         $resp = $DB->request($query)->next();
         //debug $resp['query'] = $query;
     } else {
         $query = "SELECT `glpi_tickets`.*,\n                          GROUP_CONCAT(DISTINCT `glpi_tickets_users_request`.`users_id` SEPARATOR ',')\n                                 AS users_id_request,\n                          GROUP_CONCAT(DISTINCT `glpi_tickets_users_observer`.`users_id` SEPARATOR ',')\n                                 AS users_id_observer,\n                          GROUP_CONCAT(DISTINCT `glpi_tickets_users_assign`.`users_id` SEPARATOR ',')\n                                 AS users_id_assign,\n                          GROUP_CONCAT(DISTINCT `glpi_groups_tickets_request`.`groups_id` SEPARATOR ',')\n                                 AS groups_id_request,\n                          GROUP_CONCAT(DISTINCT `glpi_groups_tickets_observer`.`groups_id` SEPARATOR ',')\n                                 AS groups_id_observer,\n                          GROUP_CONCAT(DISTINCT `glpi_groups_tickets_assign`.`groups_id` SEPARATOR ',')\n                                 AS groups_id_assign\n                   FROM `glpi_tickets`\n                   {$join}\n                   LEFT JOIN `glpi_tickets_users` AS glpi_tickets_users_request\n                        ON (`glpi_tickets`.`id` = `glpi_tickets_users_request`.`tickets_id`\n                            AND `glpi_tickets_users_request`.`type` = 1)\n                   LEFT JOIN `glpi_tickets_users` AS glpi_tickets_users_assign\n                        ON (`glpi_tickets`.`id` = `glpi_tickets_users_assign`.`tickets_id`\n                            AND `glpi_tickets_users_assign`.`type` = 2)\n                   LEFT JOIN `glpi_tickets_users` AS glpi_tickets_users_observer\n                        ON (`glpi_tickets`.`id` = `glpi_tickets_users_observer`.`tickets_id`\n                            AND `glpi_tickets_users_observer`.`type` = 3)\n                   LEFT JOIN `glpi_groups_tickets` AS glpi_groups_tickets_request\n                        ON (`glpi_tickets`.`id` = `glpi_groups_tickets_request`.`tickets_id`\n                            AND `glpi_groups_tickets_request`.`type` = 1)\n                   LEFT JOIN `glpi_groups_tickets` AS glpi_groups_tickets_assign\n                        ON (`glpi_tickets`.`id` = `glpi_groups_tickets_assign`.`tickets_id`\n                            AND `glpi_groups_tickets_assign`.`type` = 2)\n                   LEFT JOIN `glpi_groups_tickets` AS glpi_groups_tickets_observer\n                        ON (`glpi_tickets`.`id` = `glpi_groups_tickets_observer`.`tickets_id`\n                            AND `glpi_groups_tickets_observer`.`type` = 3)\n                   {$where}\n                   GROUP BY `glpi_tickets`.`id`\n                   ORDER BY {$order}\n                   LIMIT {$start},{$limit}";
         foreach ($DB->request($query) as $data) {
             $tmp = explode(',', $data['users_id_request']);
             $data['users']['requester'] = array();
             foreach ($tmp as $id) {
                 $data['users']['requester'][]['id'] = $id;
             }
             $tmp = explode(',', $data['users_id_observer']);
             $data['users']['observer'] = array();
             foreach ($tmp as $id) {
                 $data['users']['observer'][]['id'] = $id;
             }
             $tmp = explode(',', $data['users_id_assign']);
             $data['users']['assign'] = array();
             foreach ($tmp as $id) {
                 $data['users']['assign'][]['id'] = $id;
             }
             $tmp = explode(',', $data['groups_id_request']);
             $data['groups']['requester'] = array();
             foreach ($tmp as $id) {
                 $data['groups']['requester'][]['id'] = $id;
             }
             $tmp = explode(',', $data['groups_id_observer']);
             $data['groups']['observer'] = array();
             foreach ($tmp as $id) {
                 $data['groups']['observer'][]['id'] = $id;
             }
             $tmp = explode(',', $data['groups_id_assign']);
             $data['groups']['assign'] = array();
             foreach ($tmp as $id) {
                 $data['groups']['assign'][]['id'] = $id;
             }
             unset($data['groups_id_request'], $data['groups_id_observer'], $data['groups_id_assign'], $data['users_id_request'], $data['users_id_observer'], $data['users_id_assign']);
             $data['solution'] = Html::clean(Toolbox::unclean_cross_side_scripting_deep($data['solution']));
             if (isset($params['id2name'])) {
                 if ($data['itemtype'] && ($item = getItemForItemtype($data['itemtype']))) {
                     $data['itemtype_name'] = Html::clean($item->getTypeName());
                     if ($item->getFromDB($data['items_id'])) {
                         $data['items_name'] = Html::clean($item->getNameID());
                     } else {
                         $data['items_name'] = NOT_AVAILABLE;
                     }
                 }
                 foreach ($data['groups'] as $type => $tab) {
                     foreach ($tab as $key => $grp) {
                         $data['groups'][$type][$key]['name'] = Html::clean(Dropdown::getDropdownName('glpi_groups', $grp['id']));
                     }
                 }
                 foreach ($data['users'] as $type => $tab) {
                     foreach ($tab as $key => $usr) {
                         $data['users'][$type][$key]['name'] = Html::clean(getUserName($usr['id']));
                     }
                 }
                 $data['status_name'] = Html::clean(Ticket::getStatus($data['status']));
                 $data['urgency_name'] = Ticket::getUrgencyName($data['urgency']);
                 $data['impact_name'] = Ticket::getImpactName($data['impact']);
                 $data['priority_name'] = Ticket::getPriorityName($data['priority']);
                 $data['users_name_recipient'] = Html::clean(getUserName($data['users_id_recipient']));
                 $data['entities_name'] = Html::clean(Dropdown::getDropdownName('glpi_entities', $data['entities_id']));
                 $data['suppliers_name_assign'] = Html::clean(Dropdown::getDropdownName('glpi_suppliers', $data['suppliers_id_assign']));
                 $data['ticketcategories_name'] = Html::clean(Dropdown::getDropdownName('glpi_itilcategories', $data['itilcategories_id']));
                 $data['requesttypes_name'] = Html::clean(Dropdown::getDropdownName('glpi_requesttypes', $data['requesttypes_id']));
                 $data['solutiontypes_name'] = Html::clean(Dropdown::getDropdownName('glpi_solutiontypes', $data['solutiontypes_id']));
                 $data['slas_name'] = Html::clean(Dropdown::getDropdownName('glpi_slas', $data['slas_id']));
                 $data['slalevels_name'] = Html::clean(Dropdown::getDropdownName('glpi_slalevels', $data['slalevels_id']));
             }
             $resp[] = $data;
         }
     }
     return $resp;
 }