(SOLVED) Default state for a response?

Moderator: crythias

Locked
morecw
Znuny expert
Posts: 215
Joined: 18 Jun 2012, 09:24
Znuny Version: 3.1.6
Real Name: Craig Wellman
Company: STÜBER SYSTEMS

(SOLVED) Default state for a response?

Post by morecw »

Hi all,

I've written a specific response and each time this particular response is selected it is necessary for us to select Pending-Autoclose+ and set it for a week ahead.

Would anyone please explain how to make "Pending 1 Week Autoclose" the default state for this response?

Thanks in advance
Last edited by morecw on 07 Nov 2012, 22:25, edited 1 time in total.
OTRS 3.1.6, Windows 2008 with MySQL database
Firefox 14, Chrome 22
morecw
Znuny expert
Posts: 215
Joined: 18 Jun 2012, 09:24
Znuny Version: 3.1.6
Real Name: Craig Wellman
Company: STÜBER SYSTEMS

Re: Default state for a response?

Post by morecw »

more specifically.. How could I make this the default of a ticket response: Pending-Autoclose+ with 1 week ahead now from

Grateful for any suggestions
OTRS 3.1.6, Windows 2008 with MySQL database
Firefox 14, Chrome 22
datablitz7
Znuny newbie
Posts: 13
Joined: 17 Aug 2012, 11:15
Znuny Version: 3.1.11

Re: Default state for a response?

Post by datablitz7 »

Check this thread: viewtopic.php?f=62&t=9144

I can confirm this works perfectly on 3.1.11
OTRS 3.1.11 on MySQL running on Ubuntu 12.04 x64
morecw
Znuny expert
Posts: 215
Joined: 18 Jun 2012, 09:24
Znuny Version: 3.1.6
Real Name: Craig Wellman
Company: STÜBER SYSTEMS

Re: (SOLVED) Default state for a response?

Post by morecw »

Thanks for that! Here's the bit I used

Postby ThomasB » 28 Jan 2012, 18:36
Hello,

a really dirty hack but:

change in AgentTicketCompose.dtl(last lines):

Code: Select all
#Layers
<!--dtl:js_on_document_complete-->
<script type="text/javascript">//<![CDATA[
Core.Agent.TicketAction.Init();
//]]></script>
<!--dtl:js_on_document_complete-->
<!-- dtl:block:Content -->


to:

Code: Select all
#Layers
<!--dtl:js_on_document_complete-->
<script type="text/javascript">//<![CDATA[
Core.Agent.TicketAction.Init();
switch ($QData{"ResponseID"}) {
case 4: document.getElementById("StateID").value = 2;break;
case 5: document.getElementById("StateID").value = 3;break;
default: break;
}
//]]></script>
<!--dtl:js_on_document_complete-->
<!-- dtl:block:Content -->


Details:
case 4: document.getElementById("StateID").value = 2;break;
case 4 -> 4 is the response ID. You can get the response ID by hovering over the responses in the AdminPanel(id=4 in the browser statusbar...)
value = 2 -> is the statetype. In my case 2 is closed succesfully. You can get the state ID by hovering over the states in the AdminPanel(id=2 in the browser statusbar...)

It only works if Javascript is enabled...

Regards,
Thomas
Last edited by ThomasB on 05 Feb 2012, 19:25, edited 1 time in total.
OTRS 3.0.11 - Ubuntu 10.04.3 - MySQL 5.1.41-3ubuntu12.10
OTRS 3.1.6, Windows 2008 with MySQL database
Firefox 14, Chrome 22
morecw
Znuny expert
Posts: 215
Joined: 18 Jun 2012, 09:24
Znuny Version: 3.1.6
Real Name: Craig Wellman
Company: STÜBER SYSTEMS

Re: (SOLVED) Default state for a response?

Post by morecw »

Here's how to change the default Pending time (posted by moderator crythias):

"It's global. search for PendingDiffTime in SysConfig.
Edit Config Settings in Ticket -> Frontend::Agent"
OTRS 3.1.6, Windows 2008 with MySQL database
Firefox 14, Chrome 22
Locked