I figured this out.
In case anyone is interested:
In Ticket.pm in the subroutine Create, I added:
KeywordSelect-9 => undef,
in my %args.
Put $KeywordSelectObj in your initialization line:
my ($ErrStr, $QueueObj, $KeywordSelectObj, $Owner, $resolved);
Then to force a Keyword to be selected, I also added in the sub Create:
if (defined($args{'KeywordSelect-9'})) {
$KeywordSelectObj=RT::KeywordSelect->new($RT::SystemUser);
$KeywordSelectObj->Load($args{'KeywordSelect-9'});
}
unless (defined ($KeywordSelectObj)) {
$RT::Logger->debug( "$self No Action City given for ticket
creation.");
return (0, 0,“Could not create ticket. Action City not set”.);
}
This works for multi- and single value KeywordSelects.
(My KeywordSelect-9 is for Action Cities)
–colleen
-----Original Message-----
From: Colleen
Sent: Tuesday, July 02, 2002 2:35 PM
To: rt-devel@lists.fsck.com
Subject: [rt-devel] KeywordSelectI’m making some modifications in Ticket.pm so that a KeywordSelect-9
needs to be defined before a ticket can be created.In the list of Create (ARGS) KeywordSelect- is there, but does
anyone know how I can use it?From the comments in Ticket.pm:
“KeywordSelect- – an array of keyword ids for that keyword
select”