One of the biggest complaints from my privileged users during our testing of RT is that the requestor’s phone number is not presented to them conveniently. We currently handle the bulk of our support by phone, so some of them are standing at my office door with torches and pitchforks.
To rectify this I am trying to implement the custom scrip found on page 81 of the RT Essentials book, and customize it to pull up phone numbers instead of departments.
The customized scrip is:
1 my $email = ($self->TicketObj->RequestorAddresses);
3 my $ldap = Net::LDAP->new( ‘someserver.umanitoba.ca’ );
6 my $msg = $ldap->search( base => ‘o="University of Manitoba,c=“ca”’,
7 filter => “(mail=$email)”,
10 my $entry = $msg->entry(0);
12 my $phone= $entry->get_value(‘telephoneNumber’);
14 my $cf = RT::CustomField->new( $RT::SystemUser );
15 $cf->LoadByName( Name => ‘RequestorPhone’ );
17 $self->TicketObj->AddCustomFieldValue( Field => $cf, Value => $phone);
19 return 1;
Changes from the original are
7 email -> mail (what our non-standard ldap calls it)
12 $dept -> $phone
15 my custom field
17 $dept -> $phone
The custom field RequestorPhone is not being set, though. RT’s debug log shows the entry:
[error]: Scrip 16 Prepare failed: Can’t call method “get_value” on an undefined value at (eval 8643) line 12.
Could someone help me get this working, or share what they have done?
Secondly, I am having an issue that when my privileged users click on a requestor in the people tab of a ticket, they are presented with:
"Time to display: 0.009515
»|« RT 3.8.4 Copyright 1996-2009 Best Practical Solutions, LLC."
Root/Superuser is taken to the requestor’s details.
So right now, my people have no way to obtain the requestor’s phone number from within RT. So what are they doing is falling back to our old helpdesk system and in frustration entering the calls there. This is jeopardizing the acceptance and adoption of RT as a replacement for our old system.
I’m sure that I’ve made one or two (or more) simple errors and wish I could spend more time looking into this before going to the forum, but the townspeople are at the castle gates.