We want to be able to link an asset to a ticket while displaying an associated CF (“Order ID”) instead of the standard id, similar to the way some of the link features perform child ticket links are displayed using the id, subject, status).
I was able to do something similar with CustomFieldValues for Groups, displaying the Vendor ID associated with the selected group, but am unsure how to also enable the link.
I’m by no means proficient in Perl and have mostly been working through copy/paste + trial/error. Any assistance or direction towards other resources would be appreciated.
Where do you want to display the Order ID? You can show an asset portlet on the linked ticket if you set AssetQueues. Then you can control the fields shown there with $AssetSummaryFormat. You can see the default format in the core RT_Config.pm. So if you want to show it on the linked ticket, you can do it all with configuration.
We want to be able to link an Asset and a Ticket by a common field Order ID as opposed to the standard Ticket ID. So when viewing an asset, we’d like to see the value of Order ID and ensure it’s tied to an existing ticket. The active link isn’t as important, we just want to be able to have one field instead of two (ie: manually populated Order ID with an additional link reference to a ticket).
I’m aware of the AssetQueues, but that’s specifically for showing details on the ticket summary. If we could do something similar on the Asset summary page for related tickets, that would be something.
Ah, got it, so you would need a new portlet. The approach I would take is to use “FromSQL” to do a ticket search, then you can use TicketSQL syntax from the Query Builder. Build a query that finds tickets based on Order ID and any other criteria. Then in your results you have ticket objects, so it’s easy to get the ticket id and create your link. You might try experimenting with ChatGPT or other AI to help sketch out your perl code. It knows RT and can do a decent job based on our testing.