Example of Ticket::CustomModule###001-CustomModule Usage

I'm planning to customize our ticket escalation criteria a bit. This sysconfig setting looks like exactly what I want. Ticket::CustomModule###001-CustomModule I'm not very fluent in Perl's style of inheritance but I have noticed that OTRS code uses the @ISA array. Therefore, I assume I only need to implement the functions I need in my module and add the base Ticket.pm to my @ISA array (so that all others will be found in the base Ticket.pm). Is this the most manageable way? I searched online for an example but didn't see one via Google or the lists. Hugh

Hi Hugh, in fact, Ticket.pm will load all custom modules and add them to its own @ISA array. So you just have to define any additional functions or override existing functions, and then they will be available from the regular TicketObject in OTRS. Article.pm is an example for another ticket backend. Regards, mg Am 30.05.12 14:01, schrieb Hugh Kelley:
I'm planning to customize our ticket escalation criteria a bit. This sysconfig setting looks like exactly what I want.
Ticket::CustomModule###001-CustomModule
I'm not very fluent in Perl's style of inheritance but I have noticed that OTRS code uses the @ISA array. Therefore, I assume I only need to implement the functions I need in my module and add the base Ticket.pm to my @ISA array (so that all others will be found in the base Ticket.pm). Is this the most manageable way?
I searched online for an example but didn't see one via Google or the lists.
Hugh
--------------------------------------------------------------------- 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
-- Martin Gruner Senior Developer R&D OTRS AG Europaring 4 94315 Straubing T: +49 (0)6172 681988 0 F: +49 (0)9421 56818 18 I: www.otrs.com/ Geschäftssitz: Bad Homburg, Amtsgericht: Bad Homburg, HRB 10751, USt-Nr.: DE256610065 Aufsichtsratsvorsitzender: Burchard Steinbild, Vorstand: André Mindermann (Vorsitzender), Christopher Kuhn Verbinden wir uns! OTRS 3.1 schafft einfachere Integration mit Drittapplikationen -- Für Frühbucher zum Vorzugspreis: http://www.otrs.com/index.php?id=2361&L=1

Thanks, Martin. After making my original post, I found TicketCustom.pm on disk and realized that I was over-complicating the inheritance part. Very easy to use. Now I have written my redefinition of Kernel::System::Ticket::TicketEscalationIndexBuild and it is firing along. Hugh
participants (2)
-
Hugh Kelley
-
Martin Gruner