Stats ticket owned by differents agents
Moderator: crythias
Stats ticket owned by differents agents
Hello,
First of all as it's my first post, thank you for the help provided on this forum!
I found most answers of my questions here but not for the following one.
We can have both internal and contractors working on the same tickets. Internal as level 1 support and then contractors for level 2 or level 3.
My concern is that I want to be able to follow stats on number of tickets owned. This mean for a ticket owned by Agent A (internal) and then by agent B (contractor), in my stats the ticket must count for both and not only the agent that owned the ticket at the time of the stat?
Is this achievable?
First of all as it's my first post, thank you for the help provided on this forum!
I found most answers of my questions here but not for the following one.
We can have both internal and contractors working on the same tickets. Internal as level 1 support and then contractors for level 2 or level 3.
My concern is that I want to be able to follow stats on number of tickets owned. This mean for a ticket owned by Agent A (internal) and then by agent B (contractor), in my stats the ticket must count for both and not only the agent that owned the ticket at the time of the stat?
Is this achievable?
Re: Stats ticket owned by differents agents
Hey,
my idea, work with responsible and owner.
your firstlevel agents are always owner of the ticket and when it gets to 2nd level set the agents to responsible.
my idea, work with responsible and owner.
your firstlevel agents are always owner of the ticket and when it gets to 2nd level set the agents to responsible.
Live-System: OTRS 5.0.10, CentOS 7
Testsystem: OTRS 5.0.9, CentOS 6.6
Testsystem: OTRS 5.0.9, CentOS 6.6
Re: Stats ticket owned by differents agents
Hello this can answer part of my question. Thanks you.
Actually we have two distinct internal team one for functional support and the other one for technical support.
So one ticket can be first analyzed by funtionnal team then sent to contractors for deeper analyzis and finaly to the technical team for action.
How can I have this ticket count for each team that did work on it? I guess this is a usual case?
For the record we defined one queue for each internal team and contractors.
Actually we have two distinct internal team one for functional support and the other one for technical support.
So one ticket can be first analyzed by funtionnal team then sent to contractors for deeper analyzis and finaly to the technical team for action.
How can I have this ticket count for each team that did work on it? I guess this is a usual case?
For the record we defined one queue for each internal team and contractors.
Re: Stats ticket owned by differents agents
Hi,
you can "mark" a ticket with a generic agent and a dynamic field if it is moved to another queue.
in other words: "Generic Agent sets a value in a dynamic field, if the ticket is moved"
This can be done once. If you want to count the movements you have to use a Webservice.
Flo
you can "mark" a ticket with a generic agent and a dynamic field if it is moved to another queue.
in other words: "Generic Agent sets a value in a dynamic field, if the ticket is moved"
This can be done once. If you want to count the movements you have to use a Webservice.
Flo
OTRS 8 SILVER (Prod)
OTRS 8 auf Debian 11 (Test)
Znuny 7.x latest version testing auf Debian 11
-- Ich beantworte keine Forums-Fragen PN - No PN please
I won't answer to unfriendly users any more. A greeting and regards are just polite.
OTRS 8 auf Debian 11 (Test)
Znuny 7.x latest version testing auf Debian 11
-- Ich beantworte keine Forums-Fragen PN - No PN please
I won't answer to unfriendly users any more. A greeting and regards are just polite.
-
- 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: Stats ticket owned by differents agents
No, a simple event module can do the job... (a dynamic field "MoveCounter" is needed)wurzel wrote:Hi,
This can be done once. If you want to count the movements you have to use a Webservice.
Flo
Code: Select all
# --
# Copyright (C) 2016 Perl-Services.de, http://perl-services.de
# --
# This software comes with ABSOLUTELY NO WARRANTY. For details, see
# the enclosed file COPYING for license information (AGPL). If you
# did not receive this file, see http://www.gnu.org/licenses/agpl.txt.
# --
package Kernel::System::Ticket::Event::CountMoves;
use strict;
use warnings;
use Kernel::System::VariableCheck qw(:all);
our @ObjectDependencies = qw(
Kernel::Config
Kernel::System::DynamicField
Kernel::System::DynamicField::Backend
Kernel::System::Log
Kernel::System::Ticket
);
sub new {
my ( $Type, %Param ) = @_;
# allocate new hash for object
my $Self = {};
bless( $Self, $Type );
return $Self;
}
sub Run {
my ( $Self, %Param ) = @_;
my $LogObject = $Kernel::OM->Get('Kernel::System::Log');
my $DynamicFieldObject = $Kernel::OM->Get('Kernel::System::DynamicField');
my $DynamicFieldBackendObject = $Kernel::OM->Get('Kernel::System::DynamicField::Backend');
# check needed stuff
for my $Needed (qw(Data Event Config UserID)) {
if ( !$Param{$Needed} ) {
$LogObject->Log(
Priority => 'error',
Message => "Need $Needed!"
);
return;
}
}
for my $NeededData (qw(TicketID)) {
if ( !$Param{Data}->{$NeededData} ) {
$LogObject->Log(
Priority => 'error',
Message => "Need $NeededData in Data!"
);
return;
}
}
return 1 if $Param{Event} ne 'TicketStateUpdate';
my $DynamicFieldName = 'MoveCounter';
my %Ticket = $Kernel::OM->Get('Kernel::System::Ticket')->TicketGet(
TicketID => $Param{Data}->{TicketID},
DynamicFields => 1,
);
# get dynamic field
my $DynamicField = $DynamicFieldObject->DynamicFieldGet( Name => $DynamicFieldName );
my $CurrentValue = $Ticket{"DynamicField_$DynamicFieldName"};
# set the value
my $Success = $DynamicFieldBackendObject->ValueSet(
DynamicFieldConfig => $DynamicField,
ObjectID => $Param{Data}->{TicketID},
Value => $CurrentValue + 1,
UserID => $Param{UserID},
);
if ( !$Success ) {
$LogObject->Log(
Priority => 'error',
Message => "Can not update $DynamicFieldName"
);
}
return 1;
}
1;
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
Re: Stats ticket owned by differents agents
Thank you for you return. It seems that with your solution I'm able to count the number of time a tickets moved from one queue to another but not the number of tickets owned by a specific user. Let me explain with example:
Ticket 1 : has been owned by agent A then Agent B then Agent C
Ticket 2 : has been owned only by agent B
Ticket 3 : has been owned only by agent B and then agent C
If I do stats I want to see:
Agent A --> 1 ticket (Ticket 1)
Agent B --> 3 tickets (Tickets 1 +2 + 3)
Agent C --> 2 tickets (Tickets 1 + 3)
Any idea?
Ticket 1 : has been owned by agent A then Agent B then Agent C
Ticket 2 : has been owned only by agent B
Ticket 3 : has been owned only by agent B and then agent C
If I do stats I want to see:
Agent A --> 1 ticket (Ticket 1)
Agent B --> 3 tickets (Tickets 1 +2 + 3)
Agent C --> 2 tickets (Tickets 1 + 3)
Any idea?
-
- 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: Stats ticket owned by differents agents
For that you have to write your own stats module (or use the SQL box directly). The information is stored in the ticket history.
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
Re: Stats ticket owned by differents agents
OK I'll go for the SQL
Is there a simplified data model with main tables?
Is there a simplified data model with main tables?
-
- 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: Stats ticket owned by differents agents
There's only https://raw.githubusercontent.com/OTRS/ ... iagram.pngmorel wrote:OK I'll go for the SQL
Is there a simplified data model with main tables?
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