Hey guys,
I need to write an extension to the AgentTicketPhone Module. I managed to do it in version 4 but here I'm failing somehow. My plan is to read out the customer ID that was selected by the agent and together with the customer information, show another widget with some additional information which I get using the customer ID in version 4 I just easily access it by $Ticket{CustomerID}. How can I get the CustomerID in version 6?
Regards,
Tilo
OTRS 6 - How to get the customer id in the AgentTicketPhone Module?
-
- Znuny superhero
- Posts: 889
- Joined: 15 Dec 2016, 15:13
- Znuny Version: All
- Real Name: Emin
- Company: Efflux GmbH
- Contact:
Re: OTRS 6 - How to get the customer id in the AgentTicketPhone Module?
Hello Tilo,
If you need it on the Perl side, you get it from here.
The $CustomerUser variable holds the CustomerUserID and from there on you can get the CustomerID.
On the front end side, you get the CustomerID from the AJAX call with the headers "Action: AgentCustomerSearch, Subaction: CustomerInfo".
Best regards
Emin
If you need it on the Perl side, you get it from here.
The $CustomerUser variable holds the CustomerUserID and from there on you can get the CustomerID.
On the front end side, you get the CustomerID from the AJAX call with the headers "Action: AgentCustomerSearch, Subaction: CustomerInfo".
Best regards
Emin
Professional OTRS, Znuny & OTOBO services: efflux.de | efflux.de/en/
Free and premium add-ons: German | English
Free and premium add-ons: German | English
Re: OTRS 6 - How to get the customer id in the AgentTicketPhone Module?
Thanks Emi,
this didn't solve my problem directly because I had to read it out again and even then it only contained the email. But it pointed me in the right direction and I could programm a workaround and could finish my task.
It isn't an elegant solution but it works. Instead of delivering the info fields in datablocks like I used to do in v4 I basically hijacked an AJAX call, added my information and then did the rest of the work directly in javascript.
Regards,
Tilo
this didn't solve my problem directly because I had to read it out again and even then it only contained the email. But it pointed me in the right direction and I could programm a workaround and could finish my task.
It isn't an elegant solution but it works. Instead of delivering the info fields in datablocks like I used to do in v4 I basically hijacked an AJAX call, added my information and then did the rest of the work directly in javascript.
Regards,
Tilo