1806 |
22 Jan 13 |
nicklas |
1 |
<%@ page |
1806 |
22 Jan 13 |
nicklas |
2 |
pageEncoding="UTF-8" |
1806 |
22 Jan 13 |
nicklas |
3 |
session="false" |
1806 |
22 Jan 13 |
nicklas |
4 |
import="net.sf.basedb.core.User" |
1806 |
22 Jan 13 |
nicklas |
5 |
import="net.sf.basedb.core.DbControl" |
1806 |
22 Jan 13 |
nicklas |
6 |
import="net.sf.basedb.core.SessionControl" |
1806 |
22 Jan 13 |
nicklas |
7 |
import="net.sf.basedb.core.Application" |
1806 |
22 Jan 13 |
nicklas |
8 |
import="net.sf.basedb.util.formatter.WellCoordinateFormatter" |
1806 |
22 Jan 13 |
nicklas |
9 |
import="net.sf.basedb.clients.web.Base" |
1806 |
22 Jan 13 |
nicklas |
10 |
import="net.sf.basedb.clients.web.util.HTML" |
1806 |
22 Jan 13 |
nicklas |
11 |
import="net.sf.basedb.clients.web.extensions.ExtensionsControl" |
1806 |
22 Jan 13 |
nicklas |
12 |
%> |
1806 |
22 Jan 13 |
nicklas |
13 |
<%@ taglib prefix="base" uri="/WEB-INF/base.tld" %> |
1806 |
22 Jan 13 |
nicklas |
14 |
<%@ taglib prefix="p" uri="/WEB-INF/path.tld" %> |
1806 |
22 Jan 13 |
nicklas |
15 |
<% |
3976 |
26 May 16 |
nicklas |
16 |
final SessionControl sc = Base.getExistingSessionControl(request, "net.sf.basedb.reggie", true); |
1806 |
22 Jan 13 |
nicklas |
17 |
final String ID = sc.getId(); |
1806 |
22 Jan 13 |
nicklas |
18 |
final float scale = Base.getScale(sc); |
1806 |
22 Jan 13 |
nicklas |
19 |
final String home = ExtensionsControl.getHomeUrl("net.sf.basedb.reggie"); |
1806 |
22 Jan 13 |
nicklas |
20 |
DbControl dc = null; |
1806 |
22 Jan 13 |
nicklas |
21 |
try |
1806 |
22 Jan 13 |
nicklas |
22 |
{ |
1806 |
22 Jan 13 |
nicklas |
23 |
dc = sc.newDbControl(); |
1806 |
22 Jan 13 |
nicklas |
24 |
final User user = User.getById(dc, sc.getLoggedInUserId()); |
1806 |
22 Jan 13 |
nicklas |
25 |
%> |
1806 |
22 Jan 13 |
nicklas |
26 |
<base:page type="default" > |
2795 |
13 Oct 14 |
nicklas |
27 |
<base:head |
2795 |
13 Oct 14 |
nicklas |
28 |
scripts="~../reggie-2.js,~assign_barcode.js,~pools.js,~plate.js" |
2795 |
13 Oct 14 |
nicklas |
29 |
styles="path.css,~../css/reggie-2.css,~../css/plate.css"> |
1809 |
25 Jan 13 |
nicklas |
30 |
<style> |
1814 |
30 Jan 13 |
nicklas |
31 |
#select-barcode-all |
1809 |
25 Jan 13 |
nicklas |
32 |
{ |
1814 |
30 Jan 13 |
nicklas |
33 |
max-height: 20em; |
1814 |
30 Jan 13 |
nicklas |
34 |
overflow: auto; |
1809 |
25 Jan 13 |
nicklas |
35 |
} |
1809 |
25 Jan 13 |
nicklas |
36 |
|
1814 |
30 Jan 13 |
nicklas |
37 |
#select-barcode .menuitem |
1809 |
25 Jan 13 |
nicklas |
38 |
{ |
1814 |
30 Jan 13 |
nicklas |
39 |
padding-left: 16px; |
1809 |
25 Jan 13 |
nicklas |
40 |
} |
1809 |
25 Jan 13 |
nicklas |
41 |
|
1814 |
30 Jan 13 |
nicklas |
42 |
#select-barcode div.current |
1809 |
25 Jan 13 |
nicklas |
43 |
{ |
1814 |
30 Jan 13 |
nicklas |
44 |
font-weight: bold; |
1814 |
30 Jan 13 |
nicklas |
45 |
background-image: url('../images/selected.gif'); |
1814 |
30 Jan 13 |
nicklas |
46 |
background-position: 2px 50%; |
1814 |
30 Jan 13 |
nicklas |
47 |
background-repeat: no-repeat; |
1809 |
25 Jan 13 |
nicklas |
48 |
} |
1809 |
25 Jan 13 |
nicklas |
49 |
|
1814 |
30 Jan 13 |
nicklas |
50 |
#select-barcode .menuitem:hover |
1814 |
30 Jan 13 |
nicklas |
51 |
{ |
1814 |
30 Jan 13 |
nicklas |
52 |
padding-left: 14px; |
1814 |
30 Jan 13 |
nicklas |
53 |
background-position: 0px 50%; |
1814 |
30 Jan 13 |
nicklas |
54 |
} |
1814 |
30 Jan 13 |
nicklas |
55 |
|
1814 |
30 Jan 13 |
nicklas |
56 |
.menuseparator |
1814 |
30 Jan 13 |
nicklas |
57 |
{ |
1814 |
30 Jan 13 |
nicklas |
58 |
width: auto !important; |
1814 |
30 Jan 13 |
nicklas |
59 |
} |
2837 |
20 Oct 14 |
nicklas |
60 |
|
2837 |
20 Oct 14 |
nicklas |
61 |
.well.primary.empty |
2837 |
20 Oct 14 |
nicklas |
62 |
{ |
2837 |
20 Oct 14 |
nicklas |
63 |
background-color: #F0F0F0; |
2837 |
20 Oct 14 |
nicklas |
64 |
} |
3760 |
19 Feb 16 |
nicklas |
65 |
|
3760 |
19 Feb 16 |
nicklas |
66 |
.yellow-specimen .if-yellow |
3760 |
19 Feb 16 |
nicklas |
67 |
{ |
3760 |
19 Feb 16 |
nicklas |
68 |
background-image: url('../images/yellow-label-small.png'); |
3760 |
19 Feb 16 |
nicklas |
69 |
background-position: 1px 50%; |
3760 |
19 Feb 16 |
nicklas |
70 |
background-repeat: no-repeat; |
3760 |
19 Feb 16 |
nicklas |
71 |
/* Grow background without shifting text position veritcally, move to right to make room for icon*/ |
3760 |
19 Feb 16 |
nicklas |
72 |
padding: 2px 2px 2px 14px; |
3760 |
19 Feb 16 |
nicklas |
73 |
margin: -2px; |
3760 |
19 Feb 16 |
nicklas |
74 |
} |
3760 |
19 Feb 16 |
nicklas |
75 |
|
1809 |
25 Jan 13 |
nicklas |
76 |
</style> |
1806 |
22 Jan 13 |
nicklas |
77 |
</base:head> |
2795 |
13 Oct 14 |
nicklas |
78 |
<base:body> |
1806 |
22 Jan 13 |
nicklas |
79 |
|
1806 |
22 Jan 13 |
nicklas |
80 |
<p:path><p:pathelement |
1806 |
22 Jan 13 |
nicklas |
81 |
title="Reggie" href="<%="../index.jsp?ID="+ID%>" |
1806 |
22 Jan 13 |
nicklas |
82 |
/><p:pathelement title="Assign barcodes to cDNA plates" |
1806 |
22 Jan 13 |
nicklas |
83 |
/></p:path> |
1806 |
22 Jan 13 |
nicklas |
84 |
|
2795 |
13 Oct 14 |
nicklas |
85 |
<div class="content"> |
1806 |
22 Jan 13 |
nicklas |
86 |
|
2795 |
13 Oct 14 |
nicklas |
87 |
<form name="reggie" id="wizard" class="wizard"> |
2795 |
13 Oct 14 |
nicklas |
88 |
|
3226 |
07 Apr 15 |
nicklas |
89 |
<div id="select-barcode" class="menu vertical bg-filled-100" style="width: 15em; z-index: 2; display: none;"> |
3026 |
11 Dec 14 |
nicklas |
90 |
<div class="menuitem interactable enabled" id="select-barcode-default">Default</div> |
1814 |
30 Jan 13 |
nicklas |
91 |
<div class="menuseparator" id="select-barcode-default-separator"></div> |
1814 |
30 Jan 13 |
nicklas |
92 |
<div id="select-barcode-all"></div> |
1814 |
30 Jan 13 |
nicklas |
93 |
</div> |
2795 |
13 Oct 14 |
nicklas |
94 |
|
2795 |
13 Oct 14 |
nicklas |
95 |
<div class="step auto-hide" id="step-1"> |
2795 |
13 Oct 14 |
nicklas |
96 |
<div class="step-no">1</div> |
2795 |
13 Oct 14 |
nicklas |
97 |
<div class="step-title">Select cDNA bioplate</div> |
2795 |
13 Oct 14 |
nicklas |
98 |
<div class="step-content"> |
1814 |
30 Jan 13 |
nicklas |
99 |
|
2795 |
13 Oct 14 |
nicklas |
100 |
<table class="step-form"> |
2795 |
13 Oct 14 |
nicklas |
101 |
<tr> |
1806 |
22 Jan 13 |
nicklas |
102 |
<td class="prompt">cDNA bioplate</td> |
2795 |
13 Oct 14 |
nicklas |
103 |
<td class="input"> |
2795 |
13 Oct 14 |
nicklas |
104 |
<select class="required" name="bioplate" id="bioplate"></select> |
1806 |
22 Jan 13 |
nicklas |
105 |
</td> |
1806 |
22 Jan 13 |
nicklas |
106 |
<td class="status" id="bioplate.status"></td> |
2795 |
13 Oct 14 |
nicklas |
107 |
<td class="help"> |
2795 |
13 Oct 14 |
nicklas |
108 |
<span id="bioplate.message" class="message"></span> |
1806 |
22 Jan 13 |
nicklas |
109 |
Select an existing cDNA bioplate. The list contain all cDNA bioplates that |
1932 |
17 Apr 13 |
nicklas |
110 |
has not yet been assigned barcodes (determined by the absence of 'BarcodeVariant' |
1932 |
17 Apr 13 |
nicklas |
111 |
annotation). |
1806 |
22 Jan 13 |
nicklas |
112 |
</td> |
1806 |
22 Jan 13 |
nicklas |
113 |
</tr> |
2795 |
13 Oct 14 |
nicklas |
114 |
<tbody class="info-section"> |
2795 |
13 Oct 14 |
nicklas |
115 |
<tr> |
2795 |
13 Oct 14 |
nicklas |
116 |
<td class="prompt">Comments</td> |
2795 |
13 Oct 14 |
nicklas |
117 |
<td class="info" id="cdnaComments" colspan="2"></td> |
2795 |
13 Oct 14 |
nicklas |
118 |
<td class="help"></td> |
2795 |
13 Oct 14 |
nicklas |
119 |
</tr> |
2795 |
13 Oct 14 |
nicklas |
120 |
</tbody> |
1806 |
22 Jan 13 |
nicklas |
121 |
</table> |
2795 |
13 Oct 14 |
nicklas |
122 |
</div> |
1971 |
14 May 13 |
nicklas |
123 |
</div> |
1806 |
22 Jan 13 |
nicklas |
124 |
|
2795 |
13 Oct 14 |
nicklas |
125 |
<div class="step" id="step-2"> |
2795 |
13 Oct 14 |
nicklas |
126 |
<div class="step-no">2</div> |
2795 |
13 Oct 14 |
nicklas |
127 |
<div class="step-title">Select barcodes</div> |
2795 |
13 Oct 14 |
nicklas |
128 |
<div class="step-content"> |
2795 |
13 Oct 14 |
nicklas |
129 |
|
3026 |
11 Dec 14 |
nicklas |
130 |
<table class="step-form bottomborder"> |
2795 |
13 Oct 14 |
nicklas |
131 |
<tr> |
1809 |
25 Jan 13 |
nicklas |
132 |
<td class="prompt">Pool layout</td> |
1809 |
25 Jan 13 |
nicklas |
133 |
<td class="input"> |
2795 |
13 Oct 14 |
nicklas |
134 |
<select name="pool_schema" id="pool_schema" class="required"></select> |
1809 |
25 Jan 13 |
nicklas |
135 |
</td> |
1809 |
25 Jan 13 |
nicklas |
136 |
<td class="help"></td> |
1809 |
25 Jan 13 |
nicklas |
137 |
</tr> |
2795 |
13 Oct 14 |
nicklas |
138 |
<tr> |
1809 |
25 Jan 13 |
nicklas |
139 |
<td class="prompt">Barcode variants</td> |
1809 |
25 Jan 13 |
nicklas |
140 |
<td class="input"> |
2795 |
13 Oct 14 |
nicklas |
141 |
<select name="barcode_variant" id="barcode_variant" class="required"></select> |
1809 |
25 Jan 13 |
nicklas |
142 |
</td> |
1809 |
25 Jan 13 |
nicklas |
143 |
<td class="help"></td> |
1809 |
25 Jan 13 |
nicklas |
144 |
</tr> |
2795 |
13 Oct 14 |
nicklas |
145 |
<tr class="align-top"> |
1814 |
30 Jan 13 |
nicklas |
146 |
<td class="prompt">Comments</td> |
1814 |
30 Jan 13 |
nicklas |
147 |
<td class="input"> |
2795 |
13 Oct 14 |
nicklas |
148 |
<textarea rows="2" name="comments" id="comments"></textarea> |
1814 |
30 Jan 13 |
nicklas |
149 |
</td> |
1932 |
17 Apr 13 |
nicklas |
150 |
<td class="help">Comments for the library preparation.</td> |
1814 |
30 Jan 13 |
nicklas |
151 |
</tr> |
1809 |
25 Jan 13 |
nicklas |
152 |
</table> |
1809 |
25 Jan 13 |
nicklas |
153 |
|
2795 |
13 Oct 14 |
nicklas |
154 |
<table class="plate" style="margin: 1em auto 1em auto;" id="plate"> |
1806 |
22 Jan 13 |
nicklas |
155 |
<% |
1806 |
22 Jan 13 |
nicklas |
156 |
int columns = 12; |
1806 |
22 Jan 13 |
nicklas |
157 |
int rows = 8; |
1806 |
22 Jan 13 |
nicklas |
158 |
WellCoordinateFormatter rowF = new WellCoordinateFormatter(true); |
1806 |
22 Jan 13 |
nicklas |
159 |
WellCoordinateFormatter colF = new WellCoordinateFormatter(false); |
1806 |
22 Jan 13 |
nicklas |
160 |
%> |
1806 |
22 Jan 13 |
nicklas |
161 |
<tr class="header"> |
1806 |
22 Jan 13 |
nicklas |
162 |
<th></th> |
1806 |
22 Jan 13 |
nicklas |
163 |
<% |
1806 |
22 Jan 13 |
nicklas |
164 |
for (int c = 0; c < columns; ++c) |
1806 |
22 Jan 13 |
nicklas |
165 |
{ |
1806 |
22 Jan 13 |
nicklas |
166 |
%> |
1806 |
22 Jan 13 |
nicklas |
167 |
<th id="col.<%=c%>"><%=colF.format(c)%></th> |
1806 |
22 Jan 13 |
nicklas |
168 |
<% |
1806 |
22 Jan 13 |
nicklas |
169 |
} |
1806 |
22 Jan 13 |
nicklas |
170 |
%> |
1806 |
22 Jan 13 |
nicklas |
171 |
</tr> |
1806 |
22 Jan 13 |
nicklas |
172 |
<tbody> |
1806 |
22 Jan 13 |
nicklas |
173 |
<% |
1806 |
22 Jan 13 |
nicklas |
174 |
for (int r = 0; r < rows; ++r) |
1806 |
22 Jan 13 |
nicklas |
175 |
{ |
1806 |
22 Jan 13 |
nicklas |
176 |
String row = rowF.format(r); |
1806 |
22 Jan 13 |
nicklas |
177 |
%> |
1806 |
22 Jan 13 |
nicklas |
178 |
<tr class="row-<%=r%>"> |
1806 |
22 Jan 13 |
nicklas |
179 |
<th id="row.<%=r%>" class="rowheader"><%=row%></th> |
1806 |
22 Jan 13 |
nicklas |
180 |
<% |
1806 |
22 Jan 13 |
nicklas |
181 |
for (int c = 0; c < columns; ++c) |
1806 |
22 Jan 13 |
nicklas |
182 |
{ |
1806 |
22 Jan 13 |
nicklas |
183 |
%> |
1814 |
30 Jan 13 |
nicklas |
184 |
<td class="well col-<%=c%>" id="well.<%=r%>.<%=c%>" |
2795 |
13 Oct 14 |
nicklas |
185 |
data-row="<%=r%>" data-col="<%=c%>" |
1814 |
30 Jan 13 |
nicklas |
186 |
title="Click to select barcode for this well" |
1814 |
30 Jan 13 |
nicklas |
187 |
></td> |
1806 |
22 Jan 13 |
nicklas |
188 |
<% |
1806 |
22 Jan 13 |
nicklas |
189 |
} |
1806 |
22 Jan 13 |
nicklas |
190 |
%> |
1806 |
22 Jan 13 |
nicklas |
191 |
</tr> |
1806 |
22 Jan 13 |
nicklas |
192 |
<% |
1806 |
22 Jan 13 |
nicklas |
193 |
} |
1806 |
22 Jan 13 |
nicklas |
194 |
%> |
1806 |
22 Jan 13 |
nicklas |
195 |
</tbody> |
1809 |
25 Jan 13 |
nicklas |
196 |
<tr id="pool-row"> |
1809 |
25 Jan 13 |
nicklas |
197 |
<th colspan="13"> </th> |
1806 |
22 Jan 13 |
nicklas |
198 |
</tr> |
1806 |
22 Jan 13 |
nicklas |
199 |
</table> |
2795 |
13 Oct 14 |
nicklas |
200 |
</div> |
1971 |
14 May 13 |
nicklas |
201 |
</div> |
1806 |
22 Jan 13 |
nicklas |
202 |
|
2795 |
13 Oct 14 |
nicklas |
203 |
<div id="wizard-status"></div> |
1806 |
22 Jan 13 |
nicklas |
204 |
|
2795 |
13 Oct 14 |
nicklas |
205 |
<table class="navigation" id="navigation"> |
2795 |
13 Oct 14 |
nicklas |
206 |
<tr> |
2795 |
13 Oct 14 |
nicklas |
207 |
<td><base:button id="gocancel" title="Cancel" /></td> |
2795 |
13 Oct 14 |
nicklas |
208 |
<td><base:button id="gonext" title="Next" image="<%=home+"/images/gonext.png"%>" /></td> |
2795 |
13 Oct 14 |
nicklas |
209 |
<td><base:button id="goregister" title="Register" image="<%=home+"/images/import.png"%>" /></td> |
2795 |
13 Oct 14 |
nicklas |
210 |
<td><base:button id="gorestart" title="Restart" image="<%=home+"/images/goback.png"%>" /></td> |
2795 |
13 Oct 14 |
nicklas |
211 |
<td id="gonext-message" class="message"></td> |
2795 |
13 Oct 14 |
nicklas |
212 |
</tr> |
1806 |
22 Jan 13 |
nicklas |
213 |
</table> |
1806 |
22 Jan 13 |
nicklas |
214 |
|
1806 |
22 Jan 13 |
nicklas |
215 |
</form> |
1806 |
22 Jan 13 |
nicklas |
216 |
</div> |
1806 |
22 Jan 13 |
nicklas |
217 |
|
1806 |
22 Jan 13 |
nicklas |
218 |
</base:body> |
1806 |
22 Jan 13 |
nicklas |
219 |
</base:page> |
1806 |
22 Jan 13 |
nicklas |
220 |
<% |
1806 |
22 Jan 13 |
nicklas |
221 |
} |
1806 |
22 Jan 13 |
nicklas |
222 |
finally |
1806 |
22 Jan 13 |
nicklas |
223 |
{ |
1806 |
22 Jan 13 |
nicklas |
224 |
if (dc != null) dc.close(); |
1806 |
22 Jan 13 |
nicklas |
225 |
} |
1806 |
22 Jan 13 |
nicklas |
226 |
%> |