diff --git a/htdocs/ticketsup/class/ticketsup.class.php b/htdocs/ticketsup/class/ticketsup.class.php index 76902714a9e9f..ed27003846bba 100644 --- a/htdocs/ticketsup/class/ticketsup.class.php +++ b/htdocs/ticketsup/class/ticketsup.class.php @@ -1339,7 +1339,7 @@ function getNomUrl($withpicto=0, $option='', $notooltip=0, $morecss='', $save_la $label = '' . $langs->trans("ShowTicket") . ''; $label.= '
'; $label.= '' . $langs->trans('Ref') . ': ' . $this->ref.'
'; - $label.= '' . $langs->trans('TrackID') . ': ' . $this->track_id.'
'; + $label.= '' . $langs->trans('TicketTrackId') . ': ' . $this->track_id.'
'; $label.= '' . $langs->trans('Subject') . ': ' . $this->subject; $url = dol_buildpath('/ticketsup/card.php',1).'?id='.$this->id; diff --git a/htdocs/ticketsup/index.php b/htdocs/ticketsup/index.php index b98a81f204e75..16c4fc15bf70d 100644 --- a/htdocs/ticketsup/index.php +++ b/htdocs/ticketsup/index.php @@ -67,6 +67,7 @@ */ $form = new Form($db); +$tickesupstatic = new Ticketsup($db); llxHeader('', $langs->trans('TicketsIndex'), ''); @@ -264,8 +265,8 @@ * Last tickets */ $max = 15; -$sql = "SELECT t.rowid, t.ref, t.track_id, t.datec, t.subject, t.type_code, t.category_code, t.severity_code"; -$sql .= ", type.label as type_label, category.label as category_label, severity.label as severity_label"; +$sql = "SELECT t.rowid, t.ref, t.track_id, t.datec, t.subject, t.type_code, t.category_code, t.severity_code, t.fk_statut, t.progress,"; +$sql .= " type.label as type_label, category.label as category_label, severity.label as severity_label"; $sql .= " FROM " . MAIN_DB_PREFIX . "ticketsup as t"; $sql .= " LEFT JOIN " . MAIN_DB_PREFIX . "c_ticketsup_type as type ON type.code=t.type_code"; $sql .= " LEFT JOIN " . MAIN_DB_PREFIX . "c_ticketsup_category as category ON category.code=t.category_code"; @@ -308,15 +309,21 @@ print '' . $langs->trans('Type') . ''; print '' . $langs->trans('Category') . ''; print '' . $langs->trans('Severity') . ''; + print ''; print ''; if ($num > 0) { - $var = true; while ($i < $num) { $objp = $db->fetch_object($result); - $var = !$var; - print ""; + $tickesupstatic->id = $objp->rowid; + $tickesupstatic->ref = $objp->ref; + $tickesupstatic->track_id = $objp->track_id; + $tickesupstatic->fk_statut = $objp->fk_statut; + $tickesupstatic->progress = $objp->progress; + $tickesupstatic->subject = $objp->subject; + + print ''; // Creation date print ''; print dol_print_date($db->jdate($objp->datec), 'dayhour'); @@ -324,7 +331,7 @@ // Ref print ''; - print '' . $objp->ref . ''; + print $tickesupstatic->getNomUrl(1); print "\n"; // Subject @@ -346,6 +353,11 @@ print ''; print $objp->severity_label; print ""; + + print ''; + print $tickesupstatic->getLibStatut(3); + print ""; + print "\n"; $i++; }