3488 |
16 Sep 15 |
nicklas |
1 |
<%@ page |
3488 |
16 Sep 15 |
nicklas |
2 |
pageEncoding="UTF-8" |
3488 |
16 Sep 15 |
nicklas |
3 |
session="false" |
3488 |
16 Sep 15 |
nicklas |
4 |
import="net.sf.basedb.core.Application" |
3488 |
16 Sep 15 |
nicklas |
5 |
import="net.sf.basedb.core.User" |
3488 |
16 Sep 15 |
nicklas |
6 |
import="net.sf.basedb.core.DbControl" |
3488 |
16 Sep 15 |
nicklas |
7 |
import="net.sf.basedb.core.SessionControl" |
3488 |
16 Sep 15 |
nicklas |
8 |
import="net.sf.basedb.clients.web.Base" |
3488 |
16 Sep 15 |
nicklas |
9 |
import="net.sf.basedb.clients.web.util.HTML" |
3488 |
16 Sep 15 |
nicklas |
10 |
import="net.sf.basedb.clients.web.extensions.ExtensionsControl" |
3488 |
16 Sep 15 |
nicklas |
11 |
import="net.sf.basedb.util.Values" |
3488 |
16 Sep 15 |
nicklas |
12 |
import="net.sf.basedb.util.formatter.DateFormatter" |
3488 |
16 Sep 15 |
nicklas |
13 |
%> |
3488 |
16 Sep 15 |
nicklas |
14 |
<%@ taglib prefix="base" uri="/WEB-INF/base.tld" %> |
3488 |
16 Sep 15 |
nicklas |
15 |
<%@ taglib prefix="p" uri="/WEB-INF/path.tld" %> |
3488 |
16 Sep 15 |
nicklas |
16 |
<% |
3976 |
26 May 16 |
nicklas |
17 |
final SessionControl sc = Base.getExistingSessionControl(request, "net.sf.basedb.reggie", true); |
3488 |
16 Sep 15 |
nicklas |
18 |
final String ID = sc.getId(); |
3488 |
16 Sep 15 |
nicklas |
19 |
final float scale = Base.getScale(sc); |
3488 |
16 Sep 15 |
nicklas |
20 |
final String home = ExtensionsControl.getHomeUrl("net.sf.basedb.reggie"); |
3488 |
16 Sep 15 |
nicklas |
21 |
|
3488 |
16 Sep 15 |
nicklas |
22 |
DbControl dc = null; |
3488 |
16 Sep 15 |
nicklas |
23 |
try |
3488 |
16 Sep 15 |
nicklas |
24 |
{ |
3488 |
16 Sep 15 |
nicklas |
25 |
dc = sc.newDbControl(); |
3488 |
16 Sep 15 |
nicklas |
26 |
final User user = User.getById(dc, sc.getLoggedInUserId()); |
3488 |
16 Sep 15 |
nicklas |
27 |
DateFormatter dateFormat = new DateFormatter("yyyy-MM-dd"); |
3488 |
16 Sep 15 |
nicklas |
28 |
%> |
3488 |
16 Sep 15 |
nicklas |
29 |
<base:page type="default" > |
3488 |
16 Sep 15 |
nicklas |
30 |
<base:head |
4523 |
13 Jun 17 |
nicklas |
31 |
scripts="~../reggie-2.js,~frozen-tissue-date.js" |
3488 |
16 Sep 15 |
nicklas |
32 |
styles="path.css,~../css/reggie-2.css" |
3488 |
16 Sep 15 |
nicklas |
33 |
> |
3488 |
16 Sep 15 |
nicklas |
34 |
<style> |
4512 |
31 May 17 |
nicklas |
35 |
|
4512 |
31 May 17 |
nicklas |
36 |
#warnings-section |
3488 |
16 Sep 15 |
nicklas |
37 |
{ |
4512 |
31 May 17 |
nicklas |
38 |
margin: 0 1em 0 4em; |
4512 |
31 May 17 |
nicklas |
39 |
max-height: 40em; |
3488 |
16 Sep 15 |
nicklas |
40 |
overflow: auto; |
3488 |
16 Sep 15 |
nicklas |
41 |
} |
4512 |
31 May 17 |
nicklas |
42 |
|
4512 |
31 May 17 |
nicklas |
43 |
tr.highlight |
4512 |
31 May 17 |
nicklas |
44 |
{ |
4512 |
31 May 17 |
nicklas |
45 |
border-top-width: 1px; |
4512 |
31 May 17 |
nicklas |
46 |
border-top-style: dotted; |
4512 |
31 May 17 |
nicklas |
47 |
} |
4512 |
31 May 17 |
nicklas |
48 |
|
4512 |
31 May 17 |
nicklas |
49 |
#warningsTable |
4512 |
31 May 17 |
nicklas |
50 |
{ |
4512 |
31 May 17 |
nicklas |
51 |
width: 100%; |
4512 |
31 May 17 |
nicklas |
52 |
border-collapse: collapse; |
4512 |
31 May 17 |
nicklas |
53 |
} |
4512 |
31 May 17 |
nicklas |
54 |
|
4512 |
31 May 17 |
nicklas |
55 |
#warningsTable thead |
4512 |
31 May 17 |
nicklas |
56 |
{ |
4512 |
31 May 17 |
nicklas |
57 |
border-bottom-width: 1px; |
4512 |
31 May 17 |
nicklas |
58 |
} |
4512 |
31 May 17 |
nicklas |
59 |
|
4512 |
31 May 17 |
nicklas |
60 |
#warningsTable td, #warningsTable th |
4512 |
31 May 17 |
nicklas |
61 |
{ |
4512 |
31 May 17 |
nicklas |
62 |
text-align: left; |
4512 |
31 May 17 |
nicklas |
63 |
padding: 2px; |
4512 |
31 May 17 |
nicklas |
64 |
} |
4512 |
31 May 17 |
nicklas |
65 |
|
4512 |
31 May 17 |
nicklas |
66 |
#warningsTable .case-summary |
4512 |
31 May 17 |
nicklas |
67 |
{ |
4512 |
31 May 17 |
nicklas |
68 |
margin-left: 4px; |
4512 |
31 May 17 |
nicklas |
69 |
margin-right: 4px; |
4512 |
31 May 17 |
nicklas |
70 |
float: right; |
4512 |
31 May 17 |
nicklas |
71 |
} |
4512 |
31 May 17 |
nicklas |
72 |
|
4806 |
14 May 18 |
nicklas |
73 |
.hide-old-warnings .oldwarning |
4806 |
14 May 18 |
nicklas |
74 |
{ |
4806 |
14 May 18 |
nicklas |
75 |
display: none; |
4806 |
14 May 18 |
nicklas |
76 |
} |
4806 |
14 May 18 |
nicklas |
77 |
|
4806 |
14 May 18 |
nicklas |
78 |
.oldwarning |
4806 |
14 May 18 |
nicklas |
79 |
{ |
4806 |
14 May 18 |
nicklas |
80 |
color: #666; |
4806 |
14 May 18 |
nicklas |
81 |
font-style: italic; |
4806 |
14 May 18 |
nicklas |
82 |
background-color: #F0F0F0; |
4806 |
14 May 18 |
nicklas |
83 |
} |
4806 |
14 May 18 |
nicklas |
84 |
|
3488 |
16 Sep 15 |
nicklas |
85 |
</style> |
3488 |
16 Sep 15 |
nicklas |
86 |
</base:head> |
3488 |
16 Sep 15 |
nicklas |
87 |
<base:body> |
3488 |
16 Sep 15 |
nicklas |
88 |
|
3488 |
16 Sep 15 |
nicklas |
89 |
<p:path><p:pathelement |
3488 |
16 Sep 15 |
nicklas |
90 |
title="Reggie" href="<%="../index.jsp?ID="+ID%>" |
3488 |
16 Sep 15 |
nicklas |
91 |
/><p:pathelement title="Update FrozenTissueDate annotation" |
3488 |
16 Sep 15 |
nicklas |
92 |
/></p:path> |
3488 |
16 Sep 15 |
nicklas |
93 |
|
3488 |
16 Sep 15 |
nicklas |
94 |
<div class="content"> |
3488 |
16 Sep 15 |
nicklas |
95 |
<form name="reggie" id="wizard" class="wizard"> |
3488 |
16 Sep 15 |
nicklas |
96 |
|
3488 |
16 Sep 15 |
nicklas |
97 |
<div class="step" id="step-1"> |
3488 |
16 Sep 15 |
nicklas |
98 |
<div class="step-no">1</div> |
3488 |
16 Sep 15 |
nicklas |
99 |
<div class="step-title">Import from file</div> |
3488 |
16 Sep 15 |
nicklas |
100 |
<div class="step-content"> |
3488 |
16 Sep 15 |
nicklas |
101 |
|
3488 |
16 Sep 15 |
nicklas |
102 |
<table class="step-form"> |
3488 |
16 Sep 15 |
nicklas |
103 |
<tr class="align-top"> |
3488 |
16 Sep 15 |
nicklas |
104 |
<td class="prompt">FrozenTissueDate</td> |
3488 |
16 Sep 15 |
nicklas |
105 |
<td class="input"> |
3488 |
16 Sep 15 |
nicklas |
106 |
<%=dateFormat.format(new java.util.Date())%> |
3488 |
16 Sep 15 |
nicklas |
107 |
</td> |
3488 |
16 Sep 15 |
nicklas |
108 |
<td class="status"></td> |
3488 |
16 Sep 15 |
nicklas |
109 |
<td class="help"> |
3488 |
16 Sep 15 |
nicklas |
110 |
The FrozenTissueDate annotation for cases found in the selected file will |
3488 |
16 Sep 15 |
nicklas |
111 |
be updated to this value. |
3488 |
16 Sep 15 |
nicklas |
112 |
</td> |
3488 |
16 Sep 15 |
nicklas |
113 |
</tr> |
3488 |
16 Sep 15 |
nicklas |
114 |
<tr class="align-top"> |
3488 |
16 Sep 15 |
nicklas |
115 |
<td class="prompt">File</td> |
3488 |
16 Sep 15 |
nicklas |
116 |
<td class="input"> |
3488 |
16 Sep 15 |
nicklas |
117 |
<table style="width: 100%;"> |
3488 |
16 Sep 15 |
nicklas |
118 |
<tr> |
3488 |
16 Sep 15 |
nicklas |
119 |
<td> |
4512 |
31 May 17 |
nicklas |
120 |
<input class="text required" type="text" name="importfile" id="importfile" |
4512 |
31 May 17 |
nicklas |
121 |
data-name-filter="%.csv" |
4512 |
31 May 17 |
nicklas |
122 |
data-directory="/home/SCANB/FrozenTissueFiles"> |
3488 |
16 Sep 15 |
nicklas |
123 |
</td> |
3488 |
16 Sep 15 |
nicklas |
124 |
<td style="padding-left: 4px; width: 7em;"> |
3488 |
16 Sep 15 |
nicklas |
125 |
<base:button |
3488 |
16 Sep 15 |
nicklas |
126 |
title="Browse…" |
3488 |
16 Sep 15 |
nicklas |
127 |
id="importfile.btn" |
3488 |
16 Sep 15 |
nicklas |
128 |
/> |
3488 |
16 Sep 15 |
nicklas |
129 |
</td> |
3488 |
16 Sep 15 |
nicklas |
130 |
</tr> |
3488 |
16 Sep 15 |
nicklas |
131 |
</table> |
3488 |
16 Sep 15 |
nicklas |
132 |
</td> |
3488 |
16 Sep 15 |
nicklas |
133 |
<td class="status" id="importfile.status"></td> |
3488 |
16 Sep 15 |
nicklas |
134 |
<td class="help"><span id="importfile.message" class="message"></span> |
4512 |
31 May 17 |
nicklas |
135 |
The file should be a TAB-separated file with one header line. SCAN-B ID:s or PAD |
4512 |
31 May 17 |
nicklas |
136 |
numbers should be in the <b>ProvID</b> column. |
3488 |
16 Sep 15 |
nicklas |
137 |
</td> |
3488 |
16 Sep 15 |
nicklas |
138 |
</tr> |
3488 |
16 Sep 15 |
nicklas |
139 |
</table> |
3488 |
16 Sep 15 |
nicklas |
140 |
</div> |
3488 |
16 Sep 15 |
nicklas |
141 |
</div> |
3488 |
16 Sep 15 |
nicklas |
142 |
|
3488 |
16 Sep 15 |
nicklas |
143 |
|
3488 |
16 Sep 15 |
nicklas |
144 |
<div id="wizard-status"></div> |
3916 |
02 May 16 |
nicklas |
145 |
<div id="wizard-progress"></div> |
3488 |
16 Sep 15 |
nicklas |
146 |
|
4806 |
14 May 18 |
nicklas |
147 |
<div id="warnings-section" class="fullborder hide-old-warnings" style="display: none;"> |
4512 |
31 May 17 |
nicklas |
148 |
<table id="warningsTable"> |
4512 |
31 May 17 |
nicklas |
149 |
<thead class="bg-filled-100 bottom-border"> |
4512 |
31 May 17 |
nicklas |
150 |
<tr> |
4512 |
31 May 17 |
nicklas |
151 |
<th style="width: 4em;">Line</th> |
4512 |
31 May 17 |
nicklas |
152 |
<th>Reason</th> |
4512 |
31 May 17 |
nicklas |
153 |
<th style="width: 10em;">ProvID</th> |
4512 |
31 May 17 |
nicklas |
154 |
<th style="width: 75%;">Comment</th> |
4512 |
31 May 17 |
nicklas |
155 |
</tr> |
4512 |
31 May 17 |
nicklas |
156 |
</thead> |
4512 |
31 May 17 |
nicklas |
157 |
<tbody id="import-warnings"></tbody> |
4512 |
31 May 17 |
nicklas |
158 |
</table> |
4512 |
31 May 17 |
nicklas |
159 |
</div> |
3488 |
16 Sep 15 |
nicklas |
160 |
|
3488 |
16 Sep 15 |
nicklas |
161 |
<table class="navigation" id="navigation"> |
3488 |
16 Sep 15 |
nicklas |
162 |
<tr> |
3488 |
16 Sep 15 |
nicklas |
163 |
<td><base:button id="gocancel" title="Cancel" /></td> |
3488 |
16 Sep 15 |
nicklas |
164 |
<td><base:button id="gonext" title="Next" image="<%=home+"/images/gonext.png"%>" /></td> |
3488 |
16 Sep 15 |
nicklas |
165 |
<td><base:button id="goregister" title="Register" image="<%=home+"/images/gonext.png"%>" /></td> |
3488 |
16 Sep 15 |
nicklas |
166 |
<td><base:button id="goimport" title="Import" image="<%=home+"/images/gonext.png"%>" /></td> |
3488 |
16 Sep 15 |
nicklas |
167 |
<td><base:button id="gorestart" title="Restart" image="<%=home+"/images/goback.png"%>" /></td> |
4806 |
14 May 18 |
nicklas |
168 |
<td><base:button id="showAllWarnings" title="Show all warnings" image="<%=home+"/images/info.png"%>" /></td> |
3488 |
16 Sep 15 |
nicklas |
169 |
<td id="gonext-message" class="message"></td> |
3488 |
16 Sep 15 |
nicklas |
170 |
</tr> |
3488 |
16 Sep 15 |
nicklas |
171 |
</table> |
3488 |
16 Sep 15 |
nicklas |
172 |
|
3488 |
16 Sep 15 |
nicklas |
173 |
</form> |
3488 |
16 Sep 15 |
nicklas |
174 |
</div> |
3488 |
16 Sep 15 |
nicklas |
175 |
|
3488 |
16 Sep 15 |
nicklas |
176 |
</base:body> |
3488 |
16 Sep 15 |
nicklas |
177 |
</base:page> |
3488 |
16 Sep 15 |
nicklas |
178 |
<% |
3488 |
16 Sep 15 |
nicklas |
179 |
} |
3488 |
16 Sep 15 |
nicklas |
180 |
finally |
3488 |
16 Sep 15 |
nicklas |
181 |
{ |
3488 |
16 Sep 15 |
nicklas |
182 |
if (dc != null) dc.close(); |
3488 |
16 Sep 15 |
nicklas |
183 |
} |
3488 |
16 Sep 15 |
nicklas |
184 |
%> |