-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

I've set up the GenericAgent.pm exactly the way you showed me. Do I
have to set up cron jobs or something? I have set up cron jobs to
execute the GenericAgent.pl every 2 minutes, but still no luck. I've
waited since last night and the test ticket that I entered is still
owned by root instead.

Regards,

Lance McCulley
Computer Tech Specialist
[EMAIL PROTECTED]
La Sierra University
I.T. Department
(909) 785-2554



Tyler Hepworth wrote:

|>Okay, according to my mysql the queue name is 'Information
|>Technology::Technical Support', minus the ' ' of course; and the user
|>is 'techsupp'. Here is the code that i tried.
|>[Kernel/Config/GenericAgent.pm]
|>
|>package Kernel::Config::GenericAgent;
|>
|>use strict;
|>use vars qw($VERSION @ISA @EXPORT %Jobs);
|>require Exporter;
|>@ISA = qw(Exporter);
|>@EXPORT = qw(%Jobs);
|>
|>$VERSION = '$Revision: 1.7 $';
|>$VERSION =~ s/^\$.*:\W(.*)\W.+?$/$1/;
|>
|>#
- -----------------------------------------------------------------------
|># config options
|>#
- -----------------------------------------------------------------------
|>%Jobs = (
|>~ # --
|>~ # [name of job] -> send escalation notifications
|>~ # --
|>~ 'assign owner' => { # defines criteria of what to look for
|>~ Queue => 'Information Technology',
|>~ States => ['new'],
|>~ # new ticket properties
|>~ New => { # tells what to do with tickets that match above
|>criteria
|>~ Owner => 'it',
|># 'send escalation notifications' => {
|># Escalation => 1,
|># # new ticket properties
|># New => {
|># Module =>
|>'Kernel::System::GenericAgent::NotifyAgentGroupOfCustomQueue',
|>~ },
|>~ },
|>~ # insert your jobs (see Kernel/Config/GenericAgent.pm.examples)
|>
|>);
|>#
- -----------------------------------------------------------------------
|># end of config options
|>#
- -----------------------------------------------------------------------
|>1;
|>
|>Still doesn't assign the default owner as 'techsupp'. Am I doing
|>something wrong here? Should this configuration information be in the
|>Config.pm instead?
|
|
|No. The information needs to go in genericAgent.pm. The problem is
|that you are not specifying all of your items properly. Here is how it
|should look:
|
|package Kernel::Config::GenericAgent;
|
|use strict;
|use vars qw($VERSION @ISA @EXPORT %Jobs);
|require Exporter;
|@ISA = qw(Exporter);
|@EXPORT = qw(%Jobs); |
|$VERSION = '$Revision: 1.7 $';
|$VERSION =~ s/^\$.*:\W(.*)\W.+?$/$1/;
|
|# -----------------------------------------------------------------------
|# config options
|# -----------------------------------------------------------------------
|%Jobs = (
|
| # This is a job by itself. Do not mix it with others.
|
| # --
| # [name of job] -> send escalation notifications
| # --
|# 'send escalation notifications' => {
|# Escalation => 1, |# # new ticket properties
|# New => {
|# Module =>
|'Kernel::System::GenericAgent::NotifyAgentGroupOfCustomQueue',
|# },
|# },
|
|
| # insert your jobs (see Kernel/Config/GenericAgent.pm.examples)
|
| # --
| # [name of job] -> Assign Owner
| # --
| 'assign owner' => {
| Queue => 'Information Technology::Technical Support',
| States => ['new'],
| New => {
| Owner => 'techsupp'
| },
| },
|
| # New job starts here
|
|);
|# -----------------------------------------------------------------------
|# end of config options
|# -----------------------------------------------------------------------
|1;
|
|That should be it. Your problem was that you did not specify the
|complete name of the queue, you were trying to set the owner to 'it',
|and you didn' t have all of your ending braces in the right place.
|You job was mixed up with the escalation notifications job. This is
|pure perl code in the generic agent so the perl compiler is very picky
|about syntax. You have to make sure all of your commas, braces, etc
|are all just right or else it won't work. This can be kind of
|daunting if you are not all that familiar with perl. That is why it
|is recommend to upgrade to version 1.3.1 and use the web interface to
|build your generic agent routines. Doing it that way avoids having to
|worry about things like commas and braces.
|
|Hth,
|
|Tyler Hepworth
|_______________________________________________
|OTRS mailing list: otrs - Webpage: http://otrs.org/
|Archive: http://lists.otrs.org/pipermail/otrs
|To unsubscribe: http://lists.otrs.org/cgi-bin/listinfo/otrs
|Support oder Consulting für Ihr OTRS System?
|=> http://www.otrs.de/
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.2.4 (GNU/Linux)
Comment: Using GnuPG with Thunderbird - http://enigmail.mozdev.org


iD8DBQFBZV1idIFoM/NAi58RApn3AKCfrD9s7PEe43T9uH/dfzghLd7xpACbBVHJ
U6NzPUesiLg6lySIDdPUU5k=
=DNnM
-----END PGP SIGNATURE-----

_______________________________________________
OTRS mailing list: otrs - Webpage: http://otrs.org/
Archive: http://lists.otrs.org/pipermail/otrs
To unsubscribe: http://lists.otrs.org/cgi-bin/listinfo/otrs
Support oder Consulting für Ihr OTRS System?
=> http://www.otrs.de/

Reply via email to