Feature request: response template -> next ticket state

Hi, I have a suggestion for OTRS, probably someone wants to implement this: When creating a response template (Admin Area -> Responses; AdminResponse.pm), it would be nice to have the possibility to define the next ticket state. For example: I have a 'CloseWithStateExplanation' template, and often people forget to change the next ticket state. The result is a nice explanation about the state ('closed'), but the state is of course still 'open'. Best regards, Sascha Rommelfangen

Hello Sascha, We achieved this by updating Kernel/Modules/AgentCompose.pm: sub _Mask { my $Self = shift; my %Param = @_; # build next states string + # + # Set default next state dependent on ResponseID + # + if ($Param{ResponseID} eq "35") { + $Param{'NextStatesStrg'} = $Self->{LayoutObject}->OptionStrgHashRef( + Data => $Param{NextStates}, + Name => 'ComposeStateID', + Selected => 'In Progress' + ); + } elsif ($Param{ResponseID} eq "40") { + $Param{'NextStatesStrg'} = $Self->{LayoutObject}->OptionStrgHashRef( + Data => $Param{NextStates}, + Name => 'ComposeStateID', + Selected => 'Closed' + ); + } else { + # + # end + # $Param{'NextStatesStrg'} = $Self->{LayoutObject}->OptionStrgHashRef( Data => $Param{NextStates}, Name => 'ComposeStateID', Selected => $Param{NextState} ); + # + } + # # build select string if ($Param{StdAttachments} && %{$Param{StdAttachments}}) { my %Data = %{$Param{StdAttachments}}; $Param{'StdAttachmentsStrg'} = "
Hi,
I have a suggestion for OTRS, probably someone wants to implement this:
When creating a response template (Admin Area -> Responses; AdminResponse.pm), it would be nice to have the possibility to define the next ticket state.
For example: I have a 'CloseWithStateExplanation' template, and often people forget to change the next ticket state. The result is a nice explanation about the state ('closed'), but the state is of course still 'open'.
Best regards, Sascha Rommelfangen
------------------------------------------------------------------------
_______________________________________________ OTRS mailing list: dev - Webpage: http://otrs.org/ Archive: http://lists.otrs.org/pipermail/dev To unsubscribe: http://lists.otrs.org/cgi-bin/listinfo/dev
-- ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ NOTICE: This email message is for the sole use of the intended recipient(s) and may contain confidential and privileged information. Any unauthorized review, use, disclosure or distribution is prohibited. If you are not the intended recipient, please contact the sender by reply email and destroy all copies of the original message. ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Hi Graeme, thank you for your nice idea. The patch works fine, even if it's not the preferred way to solve the problem. Nevertheless, until someone implements a clean solution, I use your suggestion. Thanks again and best regards, Sascha dev-bounces@otrs.org wrote on 07/28/2005 09:52:10 AM:
Hello Sascha,
We achieved this by updating Kernel/Modules/AgentCompose.pm:
sub _Mask { my $Self = shift; my %Param = @_; # build next states string + # + # Set default next state dependent on ResponseID + # + if ($Param{ResponseID} eq "35") { + $Param{'NextStatesStrg'} = $Self->{LayoutObject}->OptionStrgHashRef( + Data => $Param{NextStates}, + Name => 'ComposeStateID', + Selected => 'In Progress' + ); + } elsif ($Param{ResponseID} eq "40") { + $Param{'NextStatesStrg'} = $Self->{LayoutObject}->OptionStrgHashRef( + Data => $Param{NextStates}, + Name => 'ComposeStateID', + Selected => 'Closed' + ); + } else { + # + # end + # $Param{'NextStatesStrg'} = $Self->{LayoutObject}->OptionStrgHashRef( Data => $Param{NextStates}, Name => 'ComposeStateID', Selected => $Param{NextState} ); + # + } + # # build select string if ($Param{StdAttachments} && %{$Param{StdAttachments}}) { my %Data = %{$Param{StdAttachments}}; $Param{'StdAttachmentsStrg'} = "
$Param{ResponseID} is the Response Identifier as held in the list in Admin Area -> Responses and the 'Selected' value is the textual value of the required (existing) status. As this only selects the default from the list, if is still possible to select another status if required.
HTH,
Graeme
Sascha.Rommelfangen@ses-astra.com wrote:
Hi,
I have a suggestion for OTRS, probably someone wants to implement
this:
When creating a response template (Admin Area -> Responses; AdminResponse.pm), it would be nice to have the possibility to define the next ticket state.
For example: I have a 'CloseWithStateExplanation' template, and often people forget to change the next ticket state. The result is a nice explanation about the state ('closed'), but the state is of course still 'open'.
Best regards, Sascha Rommelfangen

Graeme Brough
We achieved this by updating Kernel/Modules/AgentCompose.pm:
Thanks… this is a pretty evil hack, but we also have a “close with success” template. @OTRS Developers: did you have any success implementing this feature request? +1 from us. bye, //mirabilos -- tarent Gesellschaft für Softwareentwicklung und IT-Beratung mbH ‣ mit Sitz in Bonn – HRB AG Bonn 5168 – USt-ID (VAT): DE122264941 Geschäftsführer: Boris Esser, Elmar Geese • http://www.tarent.de/ tarent AG ‣ mit Sitz in Bonn – HRB AG Bonn 18196 Vorstand: Boris Esser, Elmar Geese • http://www.tarent.ag/ Vorsitzender des Aufsichtsrates: Dr. Ralf Allrutz
participants (3)
-
Graeme Brough
-
Sascha.Rommelfangen@ses-astra.com
-
Thorsten Glaser