In the agent dashboard I can choose which columns to show (for example in the open ticket panel). I have the possibility to add CustomerID, which has the meaning of Company ID and it can be related to a company in the customer_company. That company has a name which can be easier to read. Is there a way to show that name instead of CustomerID ?
Thanks
Filippo
Hot to show the name instead of CustomerID in the dashboard?
Moderator: crythias
-
- Znuny newbie
- Posts: 28
- Joined: 23 Jun 2014, 11:02
- Znuny Version: 3.3.7
Hot to show the name instead of CustomerID in the dashboard?
OTRS 4.0.1 on Ubuntu Linux and Mysql DB
-
- Znuny newbie
- Posts: 28
- Joined: 23 Jun 2014, 11:02
- Znuny Version: 3.3.7
Re: Hot to show the name instead of CustomerID in the dashbo
Spent two days trying to learn a bit of Perl and watching Otrs .pm files.
I also read Show customer data in the Dashboard
At the end I have this dirty solution to share:
1) open DashBoardTicketGeneric.pm of OTRS 3.3.8
2) locate
and add
3) locate
After that add
I think this solution is lost after an upgrade. I would be glad if somebody can suggest a way to make it persistent.
Bye
Filippo
I also read Show customer data in the Dashboard
At the end I have this dirty solution to share:
1) open DashBoardTicketGeneric.pm of OTRS 3.3.8
2) locate
Code: Select all
$Self->{CustomerUserObject} = Kernel::System::CustomerUser->new(%Param);
and add
Code: Select all
#filippo
$Self->{CustomerCompanyObject} = Kernel::System::CustomerCompany->new(%Param);
Code: Select all
# get customer name
my $CustomerName;
if ( $Ticket{CustomerUserID} ) {
$CustomerName = $Self->{CustomerUserObject}->CustomerName(
UserLogin => $Ticket{CustomerUserID},
);
}
$DataValue = $CustomerName;
}
Code: Select all
#filippo
elsif ( $Column eq 'CustomerID' ) {
# get customer company name
my $CustomerCompanyName;
if ( $Ticket{CustomerID} ) {
my %CustomerCompany = $Self->{CustomerCompanyObject}->CustomerCompanyGet(
CustomerID => $Ticket{CustomerID},);
$CustomerCompanyName = $CustomerCompany{CustomerCompanyName};
}
$DataValue = $CustomerCompanyName;
}
Bye
Filippo
OTRS 4.0.1 on Ubuntu Linux and Mysql DB
-
- Znuny newbie
- Posts: 28
- Joined: 23 Jun 2014, 11:02
- Znuny Version: 3.3.7
Re: Hot to show the name instead of CustomerID in the dashboard?
DashBoardTicketGeneric.pm was deeply changed in OTRS 4 and now the solution I proposed is broken. I'm looking to fix it myself but any help is welcome.
OTRS 4.0.1 on Ubuntu Linux and Mysql DB
-
- Znuny guru
- Posts: 5018
- Joined: 13 Mar 2011, 09:54
- Znuny Version: 6.0.x
- Real Name: Renée Bäcker
- Company: Perl-Services.de
- Contact:
Re: Hot to show the name instead of CustomerID in the dashboard?
There is/was a pull request for this on Github (http://github.com/OTRS/otrs).... Have a look at those...
Perl / Znuny development: http://perl-services.de
Free Znuny add ons from the community: http://opar.perl-services.de
Commercial add ons: http://feature-addons.de
Free Znuny add ons from the community: http://opar.perl-services.de
Commercial add ons: http://feature-addons.de