Page 2 of 2

Re: change the ticket overview columns @ home of the admin p

Posted: Thu May 17, 2012 6:15 pm
by Klemen
How about if you add this

Code: Select all

$cat_name = $hesk_settings['categories'][$ticket['category']];
just above the echo <<<EOC line and then use $cat_name to display the name?

Re: change the ticket overview columns @ home of the admin p

Posted: Thu May 17, 2012 6:28 pm
by dr_patso
BOOM KLEMEN!

Code: Select all

		$ticket['message'] = $first_line . substr(strip_tags($ticket['message']),0,200).'...';
		$cat_name = $hesk_settings['categories'][$ticket['category']];
		echo <<<EOC
		<tr title="$ticket[message]">
		<td class="$color" style="text-align:left; white-space:nowrap;"><input type="checkbox" name="id[]" value="$ticket[id]" />&nbsp;</td>
		<td class="$color" style="text-align:left; white-space:nowrap;"><a href="admin_ticket.php?track=$ticket[trackid]&Refresh=$random">$ticket[id]</a></td>
		<td class="$color">$ticket[lastchange]</td>
		<td class="$color">$ticket[name]</td>
		<td class="$color">$tagged$owner<a href="admin_ticket.php?track=$ticket[trackid]&Refresh=$random">$ticket[subject]</a></td>
		<td class="$color">$ticket[status]&nbsp;</td>
		<td class="$color">$cat_name</td>
		<td class="$color" style="text-align:center; white-space:nowrap;">$ticket[priority]&nbsp;</td>
		</tr>
that works!!!


Simple Solution for displaying category column in the tick list @ home of admin panel.

in the /inc/ticket_list.inc.php file

add

Code: Select all

$cat_name = $hesk_settings['categories'][$ticket['category']];
right above

Code: Select all

 echo <<<EOC 
which is around line 334

change one of your TD class lines which is right below echo <<<EOC(depending on column you want to replace etc) to this

Code: Select all

<td class="$color">$cat_name</td>

Re: change the ticket overview columns @ home of the admin p

Posted: Thu May 17, 2012 6:34 pm
by steve
There you go, Im glad you were able to get this resolved.

Re: change the ticket overview columns @ home of the admin p

Posted: Thu May 17, 2012 7:14 pm
by dr_patso
thanks Steve.. I have one more thing I am hung up on with custom fields.. Everything else I've been able to resolve with try/fail method. I will search the forum a bit then create a new thread if I can't find it.

I owe you and Klemen a beer, Friday or Monday when I get paid.

Re: change the ticket overview columns @ home of the admin p

Posted: Thu May 17, 2012 7:20 pm
by steve
Klemen maybe, all i did is re post smarter peoples posts :D