Ticket #5351: AnswerCase.aspx

File AnswerCase.aspx, 6.7 KB (added by David McManus, 15 years ago)
Line 
1<%@ Page Language="C#" validateRequest=false AutoEventWireup="true" CodeFile="AnswerCase.aspx.cs" Inherits="AnswerCase" %>
2<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
3<html xmlns="http://www.w3.org/1999/xhtml">
4<head runat="server">
5    <title>Tax Research Center - Answer Case</title>
6<%--    <link href="sample.css" rel="stylesheet" type="text/css"/>
7--%>
8    <style type="text/css">
9        .style1
10        {
11            width: 100%;
12        }
13
14        .style2
15        {
16            font-family: Arial;
17            font-weight: bold;
18            font-size: x-large;
19        }
20
21        .errorMessage
22        {
23                font-size:large;
24                font-weight:bold;
25                color: Red;
26        }
27
28        .title
29        {
30                font-size:large;
31                font-weight:bold;
32        }
33
34        .nonedit
35                {
36                        border: solid 1px Gray;
37                        padding: 5px;
38                }
39
40                .editable
41                {
42                        border: solid 1px Gray;
43                        padding: 5px;
44                }
45
46                .visable
47                {
48                        display:inline;
49                }
50
51                .invisable
52                {
53                        display:none;
54                }
55
56        h3
57            {
58                margin-right:0in;
59                margin-left:0in;
60                font-size:17.0pt;
61                font-family:"Times New Roman";
62                font-weight:bold;
63        }
64
65        h4
66            {
67                margin-right:0in;
68                margin-left:0in;
69                font-size:15.0pt;
70                font-family:"Times New Roman";
71                font-weight:bold;
72        }
73
74    </style>
75
76        <script type="text/javascript" src="ckeditor/ckeditor.js"></script>
77        <script src="sample.js" type="ckeditor/text/javascript"></script>
78
79</head>
80<body>
81    <form id="form1" runat="server">
82        <asp:scriptmanager ID="Scriptmanager1" runat="server"></asp:scriptmanager>
83        <asp:HiddenField ID="hdnCase" runat="server" />
84        <asp:HiddenField ID="hdnAgent" runat="server" />
85        <asp:HiddenField ID="hdnCaseAnswerID" runat="server" />
86        <asp:HiddenField ID="hdnClarifyCaseId" runat="server" />
87        <asp:HiddenField ID="hdnMemberID" runat="server" />
88        <asp:HiddenField ID="hdnSummary" runat="server" />
89        <asp:HiddenField ID="hdnResponse" runat="server" />
90        <asp:HiddenField ID="hdnReferences" runat="server" />
91        <asp:HiddenField ID="hdnAddlInfo" runat="server" />
92        <table class="style1">
93            <tr>
94                <td rowspan="2" width="234">
95                    <img alt="Tax Research Center" src="PDFLogos/10.png" style="width: 232px; height: 109px" />
96                </td>
97                <td rowspan="2" align="center" width="50%">
98                    <span class="style2">Tax Research Center</span><br class="style2" />
99                    <span class="style2">Answer Case</span>
100                </td>
101                <td align="right" valign="bottom" nowrap="nowrap" width="84">Case ID:</td>
102                <td align="right" valign="bottom" width="150">
103                    <asp:Label ID="lblCaseID" runat="server" Text="No Case Found"></asp:Label>
104                </td>
105            </tr>
106            <tr>
107                <td align="right" valign="top" nowrap="nowrap" width="84">Agent Name:</td>
108                <td align="right" valign="top" width="150">
109                    <asp:Label ID="lblCurrentUser" runat="server" Text="No Agent Found"></asp:Label>
110                </td>
111            </tr>
112        </table>
113        <center><asp:Label ID="ErrorMessage" runat="server" Text="ERROR:" CssClass="errorMessage"></asp:Label></center>
114        <div id="AnswerEntry" runat="server" visible="false">
115            <p align="center">
116                <asp:Button ID="btnSave" runat="server" Text="Save" Width="100px" OnClick="btnSave_OnClick" />
117                &nbsp;&nbsp;&nbsp;&nbsp;
118                <asp:Button ID="btnClose" runat="server" Text="Close" Width="100px" OnClientClick="CloseWindow()" />
119                &nbsp;&nbsp;&nbsp;&nbsp;
120                <asp:Button ID="btnReset" runat="server" Text="Reset" Width="100px" OnClick="btnReset_OnClick" />
121            </p>
122            <p>
123                <div style="text-align:right;">
124                    <a href="javascript:EditText();" id="aOpenResponse" runat="server" class="invisable">edit</a><a id="aCloseResponse" runat="server" class="visable" href="javascript:CloseEditor();">view</a>
125                </div>
126                        <div id="divResponse" runat="server" class="editable">
127
128                        </div>
129        </div>
130            </p>
131        </div>
132
133        <div id="divRunScripts" runat="server">
134                <script id="headscript" type="text/javascript">
135                    //<![CDATA[
136
137                    // Uncomment the following code to test the "Timeout Loading Method".
138                    // CKEDITOR.loadFullCoreTimeout = 5;
139                    var editor;
140                    editor = CKEDITOR.replace(document.getElementById('divResponse'), { height: 340, toolbar: 'AnswerCaseToolbar' });
141                    var aClose;
142                    var aOpen;
143                    var btnEdit;
144                    var btnView;
145                    //]]>
146                </script>
147        </div>
148            <script id="Script1" type="text/javascript">
149                //<![CDATA[
150                function EditText() {
151                    if (editor) {
152                        alert("You must close the existing editor before opening a new one.");
153                    }
154                    else {
155                        editor = CKEDITOR.replace(document.getElementById('divResponse'), { height: 340, toolbar: 'AnswerCaseToolbar' });
156                        document.getElementById('aOpenResponse').className = 'invisable';
157                        document.getElementById('aCloseResponse').className = 'visable';
158                    }
159                }
160
161                function CloseEditor() {
162                    document.getElementById('hdnResponse').value = editor.getData();
163                    if (editor) {
164                        editor.destroy();
165                        editor = null;
166                    }
167                    document.getElementById('aOpenResponse').className = 'visable';
168                    document.getElementById('aCloseResponse').className = 'invisable';
169                }
170
171                function CloseWindow() {
172                    if (editor) {
173                        if (confirm("It appears as if you may have updated some of the content.  Closing now will not save the data.\n\nDo you still want to close this window.")) {
174                            window.close();
175                        }
176                    }
177                    else {
178                        window.close();
179                    }
180                }
181
182                function OnSave() {
183                    if (document.getElementById('aOpenResponse').className != 'visable') {
184                        CloseEditor();
185                    }
186                }
187
188                function OnPublish() {
189                    if (editor) {
190                        CloseEditor();
191                    }
192                }
193                //]]>
194            </script>
195    </form>
196</body>
197</html>
198
© 2003 – 2022, CKSource sp. z o.o. sp.k. All rights reserved. | Terms of use | Privacy policy