Otrs Custom button in ticket Zoom screen

English! place to talk about development, programming and coding
Post Reply
sherni21
Znuny newbie
Posts: 13
Joined: 02 Aug 2019, 09:24
Znuny Version: 5.0.15
Real Name: Ekta singh
Company: Birch Street system

Otrs Custom button in ticket Zoom screen

Post by sherni21 »

Hi

I tried to create a new button in ticket zoom screen like pending & close button.
All the scenarios are working correct except "new state" field is not populating status.

1. CustomButton.xml in /Kernel/Config/Files/XML

Code: Select all

    <Setting Name="Ticket::Frontend::MenuModule###510-Awaiting Customer Response" Required="0" Valid="1">
        <Description Translatable="1">Shows a link in the menu to set ticket in Awaiting Customer Response in the ticket zoom view of the agent interface. Additional access control to show or not show this link can be done by using Key "Group" and Content like "rw:group1;move_into:group2". To cluster menu items use for Key "ClusterName" and for the Content any name you want to see in the UI. Use "ClusterPriority" to configure the order of a certain cluster within the toolbar.</Description>
        <Navigation>Frontend::Agent::View::TicketZoom::MenuModule</Navigation>
        <Value>
            <Hash>
                <Item Key="Module">Kernel::Output::HTML::TicketMenu::Generic</Item>
                <Item Key="Name" Translatable="1">Close</Item>
                <Item Key="Description" Translatable="1">Set this ticket to Awaiting Internal Response</Item>
                <Item Key="Action">AgentTicketAwaiting</Item>
                <Item Key="Link">Action=AgentTicketAwaiting;TicketID=[% Data.TicketID | html %]</Item>
                <Item Key="Target"></Item>
                <Item Key="PopupType">TicketAction</Item>
                <Item Key="ClusterName" Translatable="1"></Item>
                <Item Key="ClusterPriority"></Item>
            </Hash>
        </Value>
    </Setting>
2. AgentTicketAwaiting.t in \scripts\test\Selenium\Agent\AgentTicketActionCommon

Code: Select all

# --
# Copyright (C) 2001-2019 xxx, https://otrs.com/
# --
# 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.
# --

use strict;
use warnings;
use utf8;

use vars (qw($Self));

my $Selenium = $Kernel::OM->Get('Kernel::System::UnitTest::Selenium');




$Selenium->RunTest(
    sub {

        my $Helper       = $Kernel::OM->Get('Kernel::System::UnitTest::Helper');
        my $TicketObject = $Kernel::OM->Get('Kernel::System::Ticket');

        # Do not check RichText.
        $Helper->ConfigSettingChange(
            Valid => 1,
            Key   => 'Frontend::RichText',
            Value => 0
        );

        # Set the time input dropdown to another value.
        $Helper->ConfigSettingChange(
            Valid => 1,
            Key   => 'TimeInputMinutesStep',
            Value => 30
        );

        # Create test user.
        my $TestUserLogin = $Helper->TestUserCreate(
            Groups => [ 'admin', 'users' ],
        ) || die "Did not get test user";

        $Selenium->Login(
            Type     => 'Agent',
            User     => $TestUserLogin,
            Password => $TestUserLogin,
        );

        # Get test user ID.
        my $TestUserID = $Kernel::OM->Get('Kernel::System::User')->UserLookup(
            UserLogin => $TestUserLogin,
        );

        # Create test ticket.
        my $TicketID = $TicketObject->TicketCreate(
            Title        => 'Selenium Test Ticket',
            Queue        => 'Raw',
            Lock         => 'unlock',
            Priority     => '3 normal',
            State        => 'new',
            CustomerID   => 'SeleniumCustomer',
            CustomerUser => 'SeleniumCustomer@localhost.com',
            OwnerID      => $TestUserID,
            UserID       => $TestUserID,
        );
        $Self->True(
            $TicketID,
            "Ticket is created - ID $TicketID",
        );

        # Login as test user.
        $Selenium->Login(
            Type     => 'Agent',
            User     => $TestUserLogin,
            Password => $TestUserLogin,
        );

        my $ScriptAlias = $Kernel::OM->Get('Kernel::Config')->Get('ScriptAlias');

        # Navigate to zoom view of created test ticket.
        $Selenium->VerifiedGet("${ScriptAlias}index.pl?Action=AgentTicketZoom;TicketID=$TicketID");

        # Click on 'Awaiting' and switch window.
        $Selenium->find_element("//a[contains(\@href, \'Action=AgentTicketAwaiting;TicketID=$TicketID' )]")->click();

        $Selenium->WaitFor( WindowCount => 2 );
        my $Handles = $Selenium->get_window_handles();
        $Selenium->switch_to_window( $Handles->[1] );

        # Wait until page has loaded, if necessary.
        $Selenium->WaitFor(
            JavaScript =>
                'return typeof($) === "function" && $(".WidgetSimple").length;'
        );

        # Check page.
        for my $ID (
            qw(NewStateID Subject RichText FileUpload IsVisibleForCustomer submitRichText)
            )
        {
            my $Element = $Selenium->find_element( "#$ID", 'css' );
            $Element->is_enabled();
            $Element->is_displayed();
        }

        # Check whether the time input dropdown only shows two values.
        $Self->Is(
            $Selenium->execute_script("return \$('#Minute option').length;"),
            2,
            "Time input dropdown has only two values",
        );
        $Self->Is(
            $Selenium->execute_script("return \$('#Minute option').first().text();"),
            '00',
            "Time input dropdown first available value is 00",
        );
        $Self->Is(
            $Selenium->execute_script("return \$('#Minute option').last().text();"),
            '30',
            "Time input dropdown last available value is 30",
        );

        # Change ticket to Awaiting Customer Response.
        $Selenium->InputFieldValueSet(
            Element => '#NewStateID',
            Value   => 11,
        );
        $Selenium->find_element( "#Subject",        'css' )->send_keys('Test');
        $Selenium->find_element( "#RichText",       'css' )->send_keys('Test');
        $Selenium->find_element( "#submitRichText", 'css' )->click();

        $Selenium->WaitFor( WindowCount => 1 );
        $Selenium->switch_to_window( $Handles->[0] );

        # Navigate to AgentTicketHistory of created test ticket.
        $Selenium->VerifiedGet("${ScriptAlias}index.pl?Action=AgentTicketHistory;TicketID=$TicketID");

        # Confirm awaiting change action.
        my $Awaiting = "Changed state from \"new\" to \"Awaiting Customer Response\".";
        $Self->True(
            index( $Selenium->get_page_source(), $Awaiting ) > -1,
            'Ticket awaiting action completed'
        );

        # Delete created test tickets.
        my $Success = $TicketObject->TicketDelete(
            TicketID => $TicketID,
            UserID   => $TestUserID,
        );

        # Ticket deletion could fail if apache still writes to ticket history. Try again in this case.
        if ( !$Success ) {
            sleep 3;
            $Success = $TicketObject->TicketDelete(
                TicketID => $TicketID,
                UserID   => $TestUserID,
            );
        }
        $Self->True(
            $Success,
            "Ticket is deleted - ID $TicketID"
        );

        # Make sure the cache is correct.
        $Kernel::OM->Get('Kernel::System::Cache')->CleanUp(
            Type => 'Ticket',
        );
    }
);

1;

3. AgentTicketInternal.tt in \Kernel\Output\HTML\Templates\Standard

Code: Select all

# --
# Copyright (C) 2001-2019 xxx, https://otrs.com/
# --
# 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.
# --

[% InsertTemplate("AgentTicketActionCommon.tt") %]

4. AgentTicketAwaiting.pm in Kernel\Modules

Code: Select all

# --
# Copyright (C) 2001-2019 xxx, https://otrs.com/
# --
# 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.
# --

package Kernel::Modules::AgentTicketAwaiting;

use strict;
use warnings;

use parent qw( Kernel::Modules::AgentTicketActionCommon );

1;

But still i am facing issues in NewState field. Below is the screenshot
errors.png

Kindly suggest but i am missing here.

Thanks in advance :)
You do not have the required permissions to view the files attached to this post.
skullz
Znuny superhero
Posts: 617
Joined: 24 Feb 2012, 03:58
Znuny Version: LTS and Features
Real Name: Mo Azfar
Location: Kuala Lumpur, MY
Contact:

Re: Otrs Custom button in ticket Zoom screen

Post by skullz »

Your xml need more that that..

Search for AgentTicketFreeText and use this as reference..of course you need to change the name as well..

https://github.com/OTRS/otrs/blob/rel-6 ... Ticket.xml
sherni21
Znuny newbie
Posts: 13
Joined: 02 Aug 2019, 09:24
Znuny Version: 5.0.15
Real Name: Ekta singh
Company: Birch Street system

Re: Otrs Custom button in ticket Zoom screen

Post by sherni21 »

Thank you for suggestion. I have updated my xml file. But still i am facing issue.

Code: Select all

  <Setting Name="Ticket::Frontend::MenuModule###510-Awaiting Customer Response" Required="0" Valid="1">
        <Description Translatable="1">Shows a link in the menu to set ticket in Awaiting Customer Response in the ticket zoom view of the agent interface. Additional access control to show or not show this link can be done by using Key "Group" and Content like "rw:group1;move_into:group2". To cluster menu items use for Key "ClusterName" and for the Content any name you want to see in the UI. Use "ClusterPriority" to configure the order of a certain cluster within the toolbar.</Description>
        <Navigation>Frontend::Agent::View::TicketZoom::MenuModule</Navigation>
        <Value>
            <Hash>
                <Item Key="Module">Kernel::Output::HTML::TicketMenu::Generic</Item>
                <Item Key="Name" Translatable="1">Close</Item>
                <Item Key="Description" Translatable="1">Set this ticket to Awaiting Internal Response</Item>
                <Item Key="Action">AgentTicketAwaiting</Item>
                <Item Key="Link">Action=AgentTicketAwaiting;TicketID=[% Data.TicketID | html %]</Item>
                <Item Key="Target"></Item>
                <Item Key="PopupType">TicketAction</Item>
                <Item Key="ClusterName" Translatable="1"></Item>
                <Item Key="ClusterPriority"></Item>
            </Hash>
        </Value>
    </Setting>
	
	    <Setting Name="Ticket::Frontend::AgentTicketAwaiting###Permission" Required="1" Valid="1">
        <Description Translatable="1">Required permissions to use the ticket awaiting screen of a zoomed ticket in the agent interface.</Description>
        <Navigation>Frontend::Agent::View::TicketAwaiting</Navigation>
        <Value>
            <Item ValueType="String" ValueRegex="" Translatable="1">pending</Item>
        </Value>
    </Setting>
    <Setting Name="Ticket::Frontend::AgentTicketAwaiting###RequiredLock" Required="0" Valid="1">
        <Description Translatable="1">Defines if a ticket lock is required in the ticket awaiting screen of a zoomed ticket in the agent interface (if the ticket isn't locked yet, the ticket gets locked and the current agent will be set automatically as its owner).</Description>
        <Navigation>Frontend::Agent::View::TicketAwaiting</Navigation>
        <Value>
            <Item ValueType="Checkbox">1</Item>
        </Value>
    </Setting>
    <Setting Name="Ticket::Frontend::AgentTicketAwaiting###TicketType" Required="0" Valid="1">
        <Description Translatable="1">Sets the ticket type in the ticket awaiting screen of a zoomed ticket in the agent interface (Ticket::Type needs to be enabled).</Description>
        <Navigation>Frontend::Agent::View::TicketAwaiting</Navigation>
        <Value>
            <Item ValueType="Checkbox">0</Item>
        </Value>
    </Setting>
    <Setting Name="Ticket::Frontend::AgentTicketAwaiting###Service" Required="0" Valid="1">
        <Description Translatable="1">Sets the service in the ticket awaiting screen of a zoomed ticket in the agent interface (Ticket::Service needs to be enabled).</Description>
        <Navigation>Frontend::Agent::View::TicketAwaiting</Navigation>
        <Value>
            <Item ValueType="Checkbox">0</Item>
        </Value>
    </Setting>
    <Setting Name="Ticket::Frontend::AgentTicketAwaiting###ServiceMandatory" Required="0" Valid="1">
        <Description Translatable="1">Sets if service must be selected by the agent.</Description>
        <Navigation>Frontend::Agent::View::TicketAwaiting</Navigation>
        <Value>
            <Item ValueType="Checkbox">0</Item>
        </Value>
    </Setting>
    <Setting Name="Ticket::Frontend::AgentTicketAwaiting###SLAMandatory" Required="0" Valid="1">
        <Description Translatable="1">Sets if SLA must be selected by the agent.</Description>
        <Navigation>Frontend::Agent::View::TicketAwaiting</Navigation>
        <Value>
            <Item ValueType="Checkbox">0</Item>
        </Value>
    </Setting>
    <Setting Name="Ticket::Frontend::AgentTicketAwaiting###Queue" Required="0" Valid="1">
        <Description Translatable="1">Sets the queue in the ticket awaiting screen of a zoomed ticket in the agent interface.</Description>
        <Navigation>Frontend::Agent::View::TicketAwaiting</Navigation>
        <Value>
            <Item ValueType="Checkbox">0</Item>
        </Value>
    </Setting>
    <Setting Name="Ticket::Frontend::AgentTicketAwaiting###QueueMandatory" Required="0" Valid="1">
        <Description Translatable="1">Sets if queue must be selected by the agent.</Description>
        <Navigation>Frontend::Agent::View::TicketAwaiting</Navigation>
        <Value>
            <Item ValueType="Checkbox">0</Item>
        </Value>
    </Setting>
    <Setting Name="Ticket::Frontend::AgentTicketAwaiting###Owner" Required="0" Valid="1">
        <Description Translatable="1">Sets the ticket owner in the ticket awaiting screen of a zoomed ticket in the agent interface.</Description>
        <Navigation>Frontend::Agent::View::TicketAwaiting</Navigation>
        <Value>
            <Item ValueType="Checkbox">0</Item>
        </Value>
    </Setting>
    <Setting Name="Ticket::Frontend::AgentTicketAwaiting###OwnerMandatory" Required="0" Valid="1">
        <Description Translatable="1">Sets if ticket owner must be selected by the agent.</Description>
        <Navigation>Frontend::Agent::View::TicketAwaiting</Navigation>
        <Value>
            <Item ValueType="Checkbox">0</Item>
        </Value>
    </Setting>
    <Setting Name="Ticket::Frontend::AgentTicketAwaiting###Responsible" Required="0" Valid="1">
        <Description Translatable="1">Sets the responsible agent of the ticket in the ticket awaiting screen of a zoomed ticket in the agent interface.</Description>
        <Navigation>Frontend::Agent::View::TicketAwaiting</Navigation>
        <Value>
            <Item ValueType="Checkbox">0</Item>
        </Value>
    </Setting>
    <Setting Name="Ticket::Frontend::AgentTicketAwaiting###ResponsibleMandatory" Required="0" Valid="1">
        <Description Translatable="1">Sets if ticket responsible must be selected by the agent.</Description>
        <Navigation>Frontend::Agent::View::TicketAwaiting</Navigation>
        <Value>
            <Item ValueType="Checkbox">0</Item>
        </Value>
    </Setting>
    <Setting Name="Ticket::Frontend::AgentTicketAwaiting###State" Required="0" Valid="1">
        <Description Translatable="1">Sets the state of the ticket in the ticket awaiting screen of a zoomed ticket in the agent interface.</Description>
        <Navigation>Frontend::Agent::View::TicketAwaiting</Navigation>
        <Value>
            <Item ValueType="Checkbox">1</Item>
        </Value>
    </Setting>
    <Setting Name="Ticket::Frontend::AgentTicketAwaiting###StateMandatory" Required="0" Valid="1">
        <Description Translatable="1">Sets if state must be selected by the agent.</Description>
        <Navigation>Frontend::Agent::View::TicketAwaiting</Navigation>
        <Value>
            <Item ValueType="Checkbox">0</Item>
        </Value>
    </Setting>
    <Setting Name="Ticket::Frontend::AgentTicketAwaiting###StateType" Required="1" Valid="1">
        <Description Translatable="1">Defines the next state of a ticket after adding a note, in the ticket awaiting screen of a zoomed ticket in the agent interface.</Description>
        <Navigation>Frontend::Agent::View::TicketAwaiting</Navigation>
        <Value>
            <Array>
                <Item Translatable="1">Awaiting Customer Response</Item>
            </Array>
        </Value>
    </Setting>
    <Setting Name="Ticket::Frontend::AgentTicketAwaiting###StateDefault" Required="0" Valid="1">
        <Description Translatable="1">Defines the default next state of a ticket after adding a note, in the ticket awaiting screen of a zoomed ticket in the agent interface.</Description>
        <Navigation>Frontend::Agent::View::TicketAwaiting</Navigation>
        <Value>
            <Item ValueType="Entity" ValueEntityType="State" ValueRegex="">Awaiting Customer Response</Item>
        </Value>
    </Setting>
    <Setting Name="Ticket::Frontend::AgentTicketAwaiting###Note" Required="0" Valid="1">
        <Description Translatable="1">Allows adding notes in the ticket awaiting screen of a zoomed ticket in the agent interface. Can be overwritten by Ticket::Frontend::NeedAccountedTime.</Description>
        <Navigation>Frontend::Agent::View::TicketAwaiting</Navigation>
        <Value>
            <Item ValueType="Checkbox">1</Item>
        </Value>
    </Setting>
    <Setting Name="Ticket::Frontend::AgentTicketAwaiting###NoteMandatory" Required="0" Valid="1">
        <Description Translatable="1">Sets if note must be filled in by the agent. Can be overwritten by Ticket::Frontend::NeedAccountedTime.</Description>
        <Navigation>Frontend::Agent::View::TicketAwaiting</Navigation>
        <Value>
            <Item ValueType="Checkbox">1</Item>
        </Value>
    </Setting>
    <Setting Name="Ticket::Frontend::AgentTicketAwaiting###Subject" Required="0" Valid="1">
        <Description Translatable="1">Sets the default subject for notes added in the ticket awaiting screen of a zoomed ticket in the agent interface.</Description>
        <Navigation>Frontend::Agent::View::TicketAwaiting</Navigation>
        <Value>
            <Item ValueType="String" ValueRegex=""></Item>
        </Value>
    </Setting>
    <Setting Name="Ticket::Frontend::AgentTicketAwaiting###Body" Required="0" Valid="1">
        <Description Translatable="1">Sets the default body text for notes added in the ticket awaiting screen of a zoomed ticket in the agent interface.</Description>
        <Navigation>Frontend::Agent::View::TicketAwaiting</Navigation>
        <Value>
            <Item ValueType="Textarea"></Item>
        </Value>
    </Setting>
    <Setting Name="Ticket::Frontend::AgentTicketAwaiting###InvolvedAgent" Required="1" Valid="1">
        <Description Translatable="1">Shows a list of all the involved agents on this ticket, in the ticket awaiting screen of a zoomed ticket in the agent interface.</Description>
        <Navigation>Frontend::Agent::View::TicketAwaiting</Navigation>
        <Value>
            <Item ValueType="Checkbox">0</Item>
        </Value>
    </Setting>
    <Setting Name="Ticket::Frontend::AgentTicketAwaiting###InformAgent" Required="1" Valid="1">
        <Description Translatable="1">Shows a list of all the possible agents (all agents with note permissions on the queue/ticket) to determine who should be informed about this note, in the ticket awaiting screen of a zoomed ticket in the agent interface.</Description>
        <Navigation>Frontend::Agent::View::TicketAwaiting</Navigation>
        <Value>
            <Item ValueType="Checkbox">0</Item>
        </Value>
    </Setting>
    <Setting Name="Ticket::Frontend::AgentTicketAwaiting###IsVisibleForCustomerDefault" Required="0" Valid="1">
        <Description Translatable="1">Defines if the note in the ticket awaiting screen of the agent interface is visible for the customer by default.</Description>
        <Navigation>Frontend::Agent::View::TicketAwaiting</Navigation>
        <Value>
            <Item ValueType="Checkbox">0</Item>
        </Value>
    </Setting>
    <Setting Name="Ticket::Frontend::AgentTicketAwaiting###Priority" Required="1" Valid="1">
        <Description Translatable="1">Shows the ticket priority options in the ticket awaiting screen of a zoomed ticket in the agent interface.</Description>
        <Navigation>Frontend::Agent::View::TicketAwaiting</Navigation>
        <Value>
            <Item ValueType="Checkbox">0</Item>
        </Value>
    </Setting>
    <Setting Name="Ticket::Frontend::AgentTicketAwaiting###PriorityDefault" Required="0" Valid="0">
        <Description Translatable="1">Defines the default ticket priority in the ticket awaiting screen of a zoomed ticket in the agent interface.</Description>
        <Navigation>Frontend::Agent::View::TicketAwaiting</Navigation>
        <Value>
            <Item ValueType="Entity" ValueEntityType="Priority" ValueRegex="">3 normal</Item>
        </Value>
    </Setting>
    <Setting Name="Ticket::Frontend::AgentTicketAwaiting###Title" Required="0" Valid="1">
        <Description Translatable="1">Shows the title field in the ticket pending screen of a zoomed ticket in the agent interface.</Description>
        <Navigation>Frontend::Agent::View::TicketAwaiting</Navigation>
        <Value>
            <Item ValueType="Checkbox">0</Item>
        </Value>
    </Setting>
    <Setting Name="Ticket::Frontend::AgentTicketAwaiting###FormDraft" Required="0" Valid="1">
        <Description Translatable="1">Allows to save current work as draft in the ticket awaiting screen of the agent interface.</Description>
        <Navigation>Frontend::Agent::View::TicketAwaiting</Navigation>
        <Value>
            <Item ValueType="Checkbox">1</Item>
        </Value>
    </Setting>
    <Setting Name="Ticket::Frontend::AgentTicketAwaiting###HistoryType" Required="0" Valid="1">
        <Description Translatable="1">Defines the history type for the ticket awaiting screen action, which gets used for ticket history in the agent interface.</Description>
        <Navigation>Frontend::Agent::View::TicketAwaiting</Navigation>
        <Value>
            <Item ValueType="String" ValueRegex="">AddNote</Item>
        </Value>
    </Setting>
    <Setting Name="Ticket::Frontend::AgentTicketAwaiting###HistoryComment" Required="0" Valid="1">
        <Description Translatable="1">Defines the history comment for the ticket awaiting screen action, which gets used for ticket history in the agent interface.</Description>
        <Navigation>Frontend::Agent::View::TicketAwaiting</Navigation>
        <Value>
            <Item ValueType="String" ValueRegex="">%%Awaiting</Item>
        </Value>
    </Setting>
	    <Setting Name="Ticket::Frontend::AgentTicketAwaiting###RichTextWidth" Required="0" Valid="1">
        <Description Translatable="1">Defines the width for the rich text editor component for this screen. Enter number (pixels) or percent value (relative).</Description>
        <Navigation>Frontend::Agent::View::TicketAwaiting</Navigation>
        <Value>
            <Item ValueType="String" ValueRegex="^\d+%?$">620</Item>
        </Value>
    </Setting>
    <Setting Name="Ticket::Frontend::AgentTicketAwaiting###RichTextHeight" Required="0" Valid="1">
        <Description Translatable="1">Defines the height for the rich text editor component for this screen. Enter number (pixels) or percent value (relative).</Description>
        <Navigation>Frontend::Agent::View::TicketAwaiting</Navigation>
        <Value>
            <Item ValueType="String" ValueRegex="^\d+%?$">100</Item>
        </Value>
    </Setting>
	
	  <Setting Name="Ticket::Frontend::AgentTicketAwaiting###DynamicField" Required="0" Valid="1">
        <Description Translatable="1">Dynamic fields shown in the ticket Awaiting screen of the agent interface.</Description>
        <Navigation>Frontend::Agent::View::TicketAwaiting</Navigation>
        <Value>
            <Hash>
                <DefaultItem ValueType="Select">
                    <Item ValueType="Option" Value="0" Translatable="1">0 - Disabled</Item>
                    <Item ValueType="Option" Value="1" Translatable="1">1 - Enabled</Item>
                    <Item ValueType="Option" Value="2" Translatable="1">2 - Enabled and required</Item>
                </DefaultItem>
            </Hash>
        </Value>
    </Setting>
	    <Setting Name="Loader::Module::AgentTicketAwaiting###002-Ticket" Required="0" Valid="1">
        <Description Translatable="1">Loader module registration for the agent interface.</Description>
        <Navigation>Frontend::Agent::ModuleRegistration::Loader</Navigation>
        <Value>
            <Hash>
                <Item Key="JavaScript">
                    <Array>
                        <Item>Core.Agent.TicketAction.js</Item>
                        <Item>Core.Agent.TicketActionCommon.js</Item>
                        <Item>Core.Agent.TicketFormDraft.js</Item>
                    </Array>
                </Item>
            </Hash>
        </Value>
    </Setting>
	    <Setting Name="Frontend::Module###AgentTicketAwaiting" Required="0" Valid="1">
        <Description Translatable="1">Frontend module registration for the agent interface.</Description>
        <Navigation>Frontend::Agent::ModuleRegistration</Navigation>
        <Value>
            <Item ValueType="FrontendRegistration">
                <Hash>
                    <Item Key="Group">
                        <Array>
                        </Array>
                    </Item>
                    <Item Key="GroupRo">
                        <Array>
                        </Array>
                    </Item>
                    <Item Key="Description" Translatable="1">Ticket Awaiting Customer Response.</Item>
                    <Item Key="Title" Translatable="1">Awaiting Customer Response</Item>
                    <Item Key="NavBarName">Ticket</Item>
                </Hash>
            </Item>
        </Value>
    </Setting>
sherni21
Znuny newbie
Posts: 13
Joined: 02 Aug 2019, 09:24
Znuny Version: 5.0.15
Real Name: Ekta singh
Company: Birch Street system

Re: Otrs Custom button in ticket Zoom screen

Post by sherni21 »

Hi,

I have fixed the issue. Turned out in Ticket::Frontend::AgentTicketAwaiting###State i was using state from ticket_state instead i should use it from ticket_state_type table(DB).

Thank You for your kind help.
Post Reply