Adding timespent in tickets
1 : modify database, in ost_ticket table add the field 'time_spent' after the field 'closed' , the type is 'float' value =4,2 default define as 0.00
in /scp/tickets.php
modify near line 49
if($ticket && $ticket->getId()) {
//More coffee please.
$errors=array();
$lock=$ticket->getLock(); //Ticket lock if any
$statusKeys=array('open'=>'Open','Reopen'=>'Open','Close'=>'Closed');
switch(strtolower($_POST['a'])):
by
if($ticket && $ticket->getId()) {
//More coffee please.
$errors=array();
$lock=$ticket->getLock(); //Ticket lock if any
$ticket->timeSpent($_POST['time_spent']); // modification temps passé
$statusKeys=array('open'=>'Open','Reopen'=>'Open','Close'=>'Closed');
switch(strtolower($_POST['a'])):
in /include/staff/ticket-view.inc.php
modify near line 562
after
canAppendSignature()) { ?>
add
isOpen()) { ?>
getTimeSpent().'
'; // show the current time spent (if any) ?>
(0.25 = 15 minutes, 0.50 =30 minutes, 0.75 = 45 minutes, 1 = one hour)
in include/staff/tickets.inc.php
near line 204 add ticket.time_spent after ticket.created
near line 429 after