Kernel::System::ProcessManagement::Transition - Transition lib
All Process Management Transition functions.
Don't use the constructor directly, use the ObjectManager instead:
my $TransitionObject = $Kernel::OM->Get('Kernel::System::ProcessManagement::Transition');
Get Transition info my $Transition = $TransitionObject->TransitionGet( TransitionEntityID => 'T1', ); Returns: $Transition = { Name => 'Transition 1', CreateTime => '08-02-2012 13:37:00', ChangeBy => '2', ChangeTime => '09-02-2012 13:37:00', CreateBy => '3', Condition => { Type => 'and', Cond1 => { Type => 'and', Fields => { DynamicField_Make => [ '2' ], DynamicField_VWModel => { Type => 'String', Match => 'Golf', }, DynamicField_A => { Type => 'Hash', Match => { Value => 1, }, }, DynamicField_B => { Type => 'Regexp', Match => qr{ [\n\r\f] }xms }, DynamicField_C => { Type => 'Module', Match => 'Kernel::System::ProcessManagement::TransitionValidation::MyModule', }, Queue => { Type => 'Array', Match => [ 'Raw' ], }, # ... } } # ... }, };
Checks if one or more Transition Conditions are true my $TransitionCheck = $TransitionObject->TransitionCheck( TransitionEntityID => 'T1', or TransitionEntityID => ['T1', 'T2', 'T3'], Data => { Queue => 'Raw', DynamicField1 => 'Value', Subject => 'Testsubject', ... }, ); If called on a single TransitionEntityID Returns: $Checked = 1; # 0 If called on an array of TransitionEntityIDs Returns: $Checked = 'T1' # 0 if no Transition was true
This software is part of the OTRS project (https://otrs.org/).
This software comes with ABSOLUTELY NO WARRANTY. For details, see the enclosed file COPYING for license information (GPL). If you did not receive this file, see https://www.gnu.org/licenses/gpl-3.0.txt.