Adding company name to OTRS dashboard

Moderator: crythias

Post Reply
cherdt
Znuny newbie
Posts: 5
Joined: 06 May 2010, 09:12
Znuny Version: 2.4.7

Adding company name to OTRS dashboard

Post by cherdt »

Helllo,

Anybody has an idea about howto add the company info into the OTRS dashboard?

Kr,

Chris
cherdt
Znuny newbie
Posts: 5
Joined: 06 May 2010, 09:12
Znuny Version: 2.4.7

Re: Adding company name to OTRS dashboard

Post by cherdt »

With Company info I mean the company name ;-)
cherdt
Znuny newbie
Posts: 5
Joined: 06 May 2010, 09:12
Znuny Version: 2.4.7

Re: Adding company name to OTRS dashboard

Post by cherdt »

Actually to be even more specific I am just looking for the values that I can fill in in "$QData{}" in the AgentDashboardTicketGeneric.dtl.
crythias
Moderator
Posts: 10169
Joined: 04 May 2010, 18:38
Znuny Version: 5.0.x
Location: SouthWest Florida, USA
Contact:

Re: Adding company name to OTRS dashboard

Post by crythias »

Check out SysConfig, Framework->Core
OTRS 6.0.x (private/testing/public) on Linux with MySQL database.
Please edit your signature to include your OTRS version, Operating System, and database type.
Click Subscribe Topic below to get notifications. Consider amending your topic title to include [SOLVED] if it is so.
Need help? Before you ask
andry79
Znuny newbie
Posts: 13
Joined: 20 Apr 2010, 18:08
Znuny Version: 2.4.7

Re: Adding company name to OTRS dashboard

Post by andry79 »

crythias wrote:Check out SysConfig, Framework->Core
I don't find another option for this
crythias
Moderator
Posts: 10169
Joined: 04 May 2010, 18:38
Znuny Version: 5.0.x
Location: SouthWest Florida, USA
Contact:

Re: Adding company name to OTRS dashboard

Post by crythias »

What you're asking for is that you want to display the company name as a column in the ticket list of the dashboard, not that you want your personal company to be displayed in the admin interface.

I think it might be called CustomerID
OTRS 6.0.x (private/testing/public) on Linux with MySQL database.
Please edit your signature to include your OTRS version, Operating System, and database type.
Click Subscribe Topic below to get notifications. Consider amending your topic title to include [SOLVED] if it is so.
Need help? Before you ask
andry79
Znuny newbie
Posts: 13
Joined: 20 Apr 2010, 18:08
Znuny Version: 2.4.7

Re: Adding company name to OTRS dashboard

Post by andry79 »

crythias wrote:What you're asking for is that you want to display the company name as a column in the ticket list of the dashboard, not that you want your personal company to be displayed in the admin interface.

I think it might be called CustomerID

Yes, I want to display the company name as a column in the ticket list of the dashboard. It's possible?
ckjkennedy
Znuny newbie
Posts: 7
Joined: 20 Apr 2010, 18:21
Znuny Version: 2.4.7

Re: Adding company name to OTRS dashboard

Post by ckjkennedy »

I setup my dashboard to display owner. Customer ID can be done as well. I found this code that worked for me.
Here's how I added a column to do this.

Amended Kernel/Output/HTML/Standard/AgentDashboardTicketGeneric.dtl as
follows:

In dtl:block:ContentLargeTicketGenericRow section, add the following before
the "Time" TD element:

<td width="10%">
<a
href="$Env{"Baselink"}Action=AgentTicketCustomer&TicketID=$QData{"TicketID"}
"
onmouseover="window.status='$JSText{"Customer history"}'; return true;"
onmouseout="window.status='';">
<div title="$QData{"CustomerUserID"}">$QData{"CustomerID","15"}</div>
</a>
</td>

A few lines later in the dtl:block:ContentLargeTicketGenericNone block
increase the colspan from 3 to 4.
I can absolutely not take credit for it, I got it from this URL http://www.mail-archive.com/otrs@otrs.org/msg26704.html
PKn
Znuny newbie
Posts: 1
Joined: 13 Dec 2010, 13:53
Znuny Version: 3

Re: Adding company name to OTRS dashboard

Post by PKn »

The solution in the previous message worked for me in OTRS 2.X.... not in 3.X

For 3.X I came up with the following code

Code: Select all

<td> <a href="$Env{"Baselink"}Action=AgentTicketCustomer;TicketID=$QData{"TicketID"}" 
          target="_blank" 
         class="AsPopup PopupType_TicketAction" 
         >$QData{"CustomerID","15"} </a></td>
But there is a problem I was not able to solve:
The link should open a popup. The class="AsPopup PopupType_TicketAction" was added for this purpose. I copied this from another place where this kind of link was used. But this does not work. As a workaround I added target="_blank", now it at least opens on a different tab.

Any solutions for this?
binerf
Znuny newbie
Posts: 20
Joined: 25 Oct 2012, 06:43
Znuny Version: 3.1.10

Re: Adding company name to OTRS dashboard

Post by binerf »

Hi all,

I know that was an old post but I don't figure out how to make this request possible.

As described previously, I'd like to display the company name (or CustomerID at least) as a column in the ticket list of the dashboard.

Is it possible ? If yes, how to do that ?

Thank you in advance.
Huxley
Znuny newbie
Posts: 11
Joined: 28 Nov 2012, 10:41
Znuny Version: 3.1.10
Real Name: Mario

Re: Adding company name to OTRS dashboard

Post by Huxley »

It IS possible.
I managed to show the company name in the lists of the dashboard and even the status view.
For the dashboard you need to add the following code to Kernel\Output\HTML\DashboardTicketGeneric.pm (code includes the line numbers) :

Code: Select all

(16)       use Kernel::System::CustomerCompany;

(36)       $Self->{CustomerCompanyObject} = Kernel::System::CustomerCompany->new(%Param);

(365)      my %Company = $Self->{CustomerCompanyObject}->CustomerCompanyGet(CustomerID => $Ticket{CustomerID});
           $Ticket{CustomerName}  = $Company{CustomerCompanyName};
Now you have to add the following to Kernel\Output\HTML\Standard\AgentDashboardTicketGeneric.dtl:

Code: Select all

(112)     <td class="W15pc">
                 <div title="$QData{"CustomerName"}">$QData{"CustomerName","25"}</div>
          </td>
At least worked for me on OTRS 3.1.10
OTRS 3.1.10, MySQL, Windows Server 2008
MoedIjaz
Znuny newbie
Posts: 16
Joined: 21 Feb 2013, 09:16
Znuny Version: 3.2.1
Real Name: Moed Ijaz
Company: ExpertFlow

Re: Adding company name to OTRS dashboard

Post by MoedIjaz »

Thank You Very Much .... U help me alot :D
mojosakker
Znuny newbie
Posts: 1
Joined: 11 Dec 2013, 15:09
Znuny Version: 3.2.10

Re: Adding company name to OTRS dashboard

Post by mojosakker »

I dont know perl, but i added this code, otherwise i'm getting error in syslog "error OTRS-CGI-10 Need CustomerID!"

Code: Select all

		if ( $Ticket{CustomerID} ) {
        my %Company = $Self->{CustomerCompanyObject}->CustomerCompanyGet(CustomerID => $Ticket{CustomerID});
           $Ticket{CustomerName}  = $Company{CustomerCompanyName};
		}
Post Reply