1d2c37c1 by Udo Bretz

Improved integration of OTRSServiceInidentState AddOn.

1 parent fac594a5
...@@ -67,6 +67,7 @@ ...@@ -67,6 +67,7 @@
67 <File Permission="644" Location="scripts/test/Service.t"/> 67 <File Permission="644" Location="scripts/test/Service.t"/>
68 <File Permission="644" Location="scripts/test/SLA.t"/> 68 <File Permission="644" Location="scripts/test/SLA.t"/>
69 <File Permission="644" Location="var/httpd/htdocs/js/ITSM.Agent.CustomerSearch.js"/> 69 <File Permission="644" Location="var/httpd/htdocs/js/ITSM.Agent.CustomerSearch.js"/>
70 <File Permission="644" Location="var/httpd/htdocs/js/ITSM.Agent.IncidentState.js"/>
70 <File Permission="644" Location="var/httpd/htdocs/js/ITSM.Agent.Zoom.js"/> 71 <File Permission="644" Location="var/httpd/htdocs/js/ITSM.Agent.Zoom.js"/>
71 <File Permission="644" Location="var/httpd/htdocs/skins/Agent/default/css/ITSM.Agent.Default.css"/> 72 <File Permission="644" Location="var/httpd/htdocs/skins/Agent/default/css/ITSM.Agent.Default.css"/>
72 <File Permission="644" Location="var/httpd/htdocs/skins/Agent/default/css/ITSM.Agent.Detail.css"/> 73 <File Permission="644" Location="var/httpd/htdocs/skins/Agent/default/css/ITSM.Agent.Detail.css"/>
......
...@@ -411,6 +411,7 @@ ...@@ -411,6 +411,7 @@
411 <Setting> 411 <Setting>
412 <Array> 412 <Array>
413 <Item>ITSM.Agent.CustomerSearch.js</Item> 413 <Item>ITSM.Agent.CustomerSearch.js</Item>
414 <Item>ITSM.Agent.IncidentState.js</Item>
414 </Array> 415 </Array>
415 </Setting> 416 </Setting>
416 </ConfigItem> 417 </ConfigItem>
......
1 // --
2 // ITSM.Agent.IncidentState.js - provides the special module functions to show the service incident state
3 // Copyright (C) 2001-2011 OTRS AG, http://otrs.org/\n";
4 // --
5 // This software comes with ABSOLUTELY NO WARRANTY. For details, see
6 // the enclosed file COPYING for license information (AGPL). If you
7 // did not receive this file, see http://www.gnu.org/licenses/agpl.txt.
8 // --
9
10 "use strict";
11
12 var ITSM = ITSM || {};
13 ITSM.Agent = ITSM.Agent || {};
14
15 /**
16 * @namespace
17 * @exports TargetNS as ITSM.Agent.IncidentState
18 * @description
19 * This namespace contains the special module functions for IncidentState.
20 */
21 ITSM.Agent.IncidentState = (function (TargetNS) {
22
23 TargetNS.ShowIncidentState = function (Data) {
24
25 Data.Subaction = 'GetServiceIncidentState';
26
27 Core.AJAX.FunctionCall( Core.Config.Get('Baselink'), Data, function (Response) {
28
29 // if a service was selected and an incident state was found
30 if (Response.CurInciSignal) {
31
32 // set incident signal
33 $('#ServiceIncidentStateSignal').attr('class', Response.CurInciSignal);
34 $('#ServiceIncidentStateSignal').attr('title', Response.CurInciState);
35
36 // set incident state
37 $('#ServiceIncidentState').html(Response.CurInciState);
38
39 // show service incident signal and state
40 $('#ServiceIncidentStateContainer')
41 .show()
42 .prev()
43 .show();
44 }
45 else {
46 // hide service incident signal and state
47 $('#ServiceIncidentStateContainer')
48 .hide()
49 .prev()
50 .hide();
51 }
52 });
53 };
54
55 return TargetNS;
56 }(ITSM.Agent.IncidentState || {}));