[dev] CreateTicket2-n.pl perl ticket interface OTRS 2.2.3
Martin Edenhofer
me at otrs.com
Fri Nov 23 20:18:03 GMT 2007
Hi Eric,
ok. This file is using OTRS API 1.3. For OTRS 2.2 it's a little bit
different.
Anyway. Here is the diff and attached is a working version.
Many greetings from Straubing,
-Martin
-------------- next part --------------
A non-text attachment was scrubbed...
Name: CreateTicket2-n.pl
Type: text/x-perl-script
Size: 2647 bytes
Desc: not available
Url : http://lists.otrs.org/pipermail/dev/attachments/20071123/d2ffbbf7/CreateTicket2-n-0001.bin
-------------- next part --------------
me at Macintosh:~/src/otrs-cvs$ diff ~/Downloads/CreateTicket2-n.pl bin/
CreateTicket
20a21
> use Kernel::System::Main;
23a25,28
> my $LogObject = Kernel::System::Log->new(
> ConfigObject => $ConfigObject,
> LogPrefix => "CreateTicket.pl",
> );
28c33,34
< my $LogObject = Kernel::System::Log->new(
---
> my $MainObject = Kernel::System::Main->new(
> LogObject => $LogObject,
30d35
< LogPrefix => "CreateTicket.pl",
34a40
> MainObject => $MainObject,
39a46
> MainObject => $MainObject,
52,53c59,60
< UserID => 1, # current owner
< CreateUserID => 1,
---
> OwnerID => 1, # current owner
> UserID => 1,
me at Macintosh:~/src/otrs-cvs$
On Nov 23, 2007, at 4:50 PM, Partington, Eric wrote:
>
> Here is the file as it stands now. My system is running RHEL4 OTRS
> 2.2.3
>
> This is where I found the original file from 2004.
> http://lists.otrs.org/pipermail/dev/2004-November/000802.html
>
> Thanks for the help everyone.
>
> Eric
> -----Original Message-----
> From: dev-bounces at otrs.org [mailto:dev-bounces at otrs.org] On Behalf
> Of Martin Edenhofer
> Sent: 2007, November, 23 9:23 AM
> To: Development community of OTRS.org
> Subject: Re: [dev] CreateTicket2-n.pl perl ticket interface OTRS 2.2.3
>
> Hi Eric,
>
> can you upload the file somewhere (so it's easier)? :)
>
> -Martin
>
> On Nov 23, 2007, at 3:04 PM, Partington, Eric wrote:
>
>> Thanks for the prompt response Martin,
>>
>> I tried your suggestion and still have the same error that I did
>> before. Any more suggestions?
>>
>> I also noticed that many of the modules are written with the
>> $CommonObject{} format as opposed to the $method format. Is
>> something
>> I should be looking into?
>>
>> Eric
>>
>> [853232650 at localhost bin]$ ./CreateTicket2-n.pl Got no LogObject! at
>> /opt/otrs/Kernel/System/Time.pm line 70, <PRODUCT> line 4.
>>
>> The TimeObject needs also the LogObject as param like:
>>
>> my $ConfigObject = Kernel::Config->new();
>> my $LogObject = Kernel::System::Log->new(
>> ConfigObject => $ConfigObject,
>> );
>> my $TimeObject = Kernel::System::Time->new(
>> LogObject => $LogObject,
>> ConfigObject => $ConfigObject,
>> );
More information about the dev
mailing list