1 | <%-- $Id: edit_rawbioassay.jsp 5949 2012-02-08 14:35:29Z nicklas $ |
---|
2 | ------------------------------------------------------------------ |
---|
3 | Copyright (C) 2005 Nicklas Nordborg |
---|
4 | Copyright (C) 2006 Jari Häkkinen, Nicklas Nordborg, Martin Svensson |
---|
5 | Copyright (C) 2007 Nicklas Nordborg |
---|
6 | |
---|
7 | This file is part of BASE - BioArray Software Environment. |
---|
8 | Available at http://base.thep.lu.se/ |
---|
9 | |
---|
10 | BASE is free software; you can redistribute it and/or |
---|
11 | modify it under the terms of the GNU General Public License |
---|
12 | as published by the Free Software Foundation; either version 3 |
---|
13 | of the License, or (at your option) any later version. |
---|
14 | |
---|
15 | BASE is distributed in the hope that it will be useful, |
---|
16 | but WITHOUT ANY WARRANTY; without even the implied warranty of |
---|
17 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
---|
18 | GNU General Public License for more details. |
---|
19 | |
---|
20 | You should have received a copy of the GNU General Public License |
---|
21 | along with BASE. If not, see <http://www.gnu.org/licenses/>. |
---|
22 | ------------------------------------------------------------------ |
---|
23 | |
---|
24 | |
---|
25 | @author Nicklas |
---|
26 | @version 2.0 |
---|
27 | --%> |
---|
28 | <%@ page pageEncoding="UTF-8" session="false" |
---|
29 | import="net.sf.basedb.core.SessionControl" |
---|
30 | import="net.sf.basedb.core.DbControl" |
---|
31 | import="net.sf.basedb.core.Item" |
---|
32 | import="net.sf.basedb.core.ItemContext" |
---|
33 | import="net.sf.basedb.core.SystemItems" |
---|
34 | import="net.sf.basedb.core.Permission" |
---|
35 | import="net.sf.basedb.core.RawBioAssay" |
---|
36 | import="net.sf.basedb.core.Platform" |
---|
37 | import="net.sf.basedb.core.PlatformVariant" |
---|
38 | import="net.sf.basedb.core.Protocol" |
---|
39 | import="net.sf.basedb.core.Project" |
---|
40 | import="net.sf.basedb.core.Software" |
---|
41 | import="net.sf.basedb.core.ArrayDesign" |
---|
42 | import="net.sf.basedb.core.Extract" |
---|
43 | import="net.sf.basedb.core.DerivedBioAssay" |
---|
44 | import="net.sf.basedb.core.ItemSubtype" |
---|
45 | import="net.sf.basedb.core.File" |
---|
46 | import="net.sf.basedb.core.RawDataType" |
---|
47 | import="net.sf.basedb.core.RawDataTypes" |
---|
48 | import="net.sf.basedb.core.ItemQuery" |
---|
49 | import="net.sf.basedb.core.ItemResultList" |
---|
50 | import="net.sf.basedb.core.PermissionDeniedException" |
---|
51 | import="net.sf.basedb.core.BaseException" |
---|
52 | import="net.sf.basedb.core.query.Orders" |
---|
53 | import="net.sf.basedb.core.query.Hql" |
---|
54 | import="net.sf.basedb.clients.web.Base" |
---|
55 | import="net.sf.basedb.clients.web.util.HTML" |
---|
56 | import="net.sf.basedb.util.Values" |
---|
57 | import="net.sf.basedb.core.Include" |
---|
58 | import="net.sf.basedb.core.plugin.GuiContext" |
---|
59 | import="net.sf.basedb.clients.web.extensions.ExtensionsControl" |
---|
60 | import="net.sf.basedb.clients.web.extensions.JspContext" |
---|
61 | import="net.sf.basedb.clients.web.extensions.edit.EditUtil" |
---|
62 | import="net.sf.basedb.util.extensions.ExtensionsInvoker" |
---|
63 | import="java.util.List" |
---|
64 | import="java.util.Set" |
---|
65 | import="java.util.HashSet" |
---|
66 | %> |
---|
67 | <%@ taglib prefix="base" uri="/WEB-INF/base.tld" %> |
---|
68 | <%@ taglib prefix="t" uri="/WEB-INF/tab.tld" %> |
---|
69 | <% |
---|
70 | final Item itemType = Item.RAWBIOASSAY; |
---|
71 | final SessionControl sc = Base.getExistingSessionControl(pageContext, true); |
---|
72 | final ItemContext cc = Base.getAndSetCurrentContext(sc, itemType, null, null); |
---|
73 | final String tabId = Values.getString(request.getParameter("tab"), null); |
---|
74 | final int itemId = cc.getId(); |
---|
75 | final String ID = sc.getId(); |
---|
76 | final float scale = Base.getScale(sc); |
---|
77 | final DbControl dc = sc.newDbControl(); |
---|
78 | try |
---|
79 | { |
---|
80 | String title = null; |
---|
81 | RawBioAssay rawBioAssay = null; |
---|
82 | String name = null; |
---|
83 | boolean hasDbSpots = false; |
---|
84 | |
---|
85 | boolean deniedPlatform = false; |
---|
86 | Platform currentPlatform = null; |
---|
87 | List<Platform> defaultPlatforms = null; |
---|
88 | PlatformVariant currentVariant = null; |
---|
89 | List<PlatformVariant> defaultVariants = null; |
---|
90 | |
---|
91 | boolean readCurrentBioAssay = true; |
---|
92 | DerivedBioAssay currentBioAssay = null; |
---|
93 | boolean readCurrentExtract = true; |
---|
94 | Extract currentExtract = null; |
---|
95 | boolean readCurrentProtocol = true; |
---|
96 | Protocol currentProtocol = null; |
---|
97 | List<Protocol> defaultProtocols = null; |
---|
98 | boolean readCurrentSoftware = true; |
---|
99 | Software currentSoftware = null; |
---|
100 | List<Software> defaultSoftware = null; |
---|
101 | boolean readCurrentArrayDesign = true; |
---|
102 | ArrayDesign currentArrayDesign = null; |
---|
103 | List<ArrayDesign> defaultArrayDesigns = null; |
---|
104 | RawDataType currentRawDataType = null; |
---|
105 | RawDataType defaultRawDataType = null; |
---|
106 | |
---|
107 | // Load recently used items |
---|
108 | List<Protocol> recentProtocols = (List<Protocol>)cc.getRecent(dc, Item.PROTOCOL); |
---|
109 | List<Software> recentSoftware = (List<Software>)cc.getRecent(dc, Item.SOFTWARE); |
---|
110 | List<ArrayDesign> recentArrayDesigns = (List<ArrayDesign>)cc.getRecent(dc, Item.ARRAYDESIGN); |
---|
111 | List<File> recentFiles = (List<File>)cc.getRecent(dc, Item.FILE); |
---|
112 | List<DerivedBioAssay> recentBioAssays = (List<DerivedBioAssay>)cc.getRecent(dc, Item.DERIVEDBIOASSAY); |
---|
113 | List<Extract> recentExtracts = (List<Extract>)cc.getRecent(dc, Item.EXTRACT); |
---|
114 | |
---|
115 | int activeProjectId = sc.getActiveProjectId(); |
---|
116 | if (activeProjectId > 0) |
---|
117 | { |
---|
118 | Project activeProject = Project.getById(dc, activeProjectId); |
---|
119 | try |
---|
120 | { |
---|
121 | defaultProtocols = (List<Protocol>)activeProject.findDefaultItems(dc, |
---|
122 | ItemSubtype.getById(dc, SystemItems.getId(Protocol.FEATURE_EXTRACTION)), false); |
---|
123 | } |
---|
124 | catch (PermissionDeniedException pdex) |
---|
125 | {} |
---|
126 | try |
---|
127 | { |
---|
128 | defaultSoftware = (List<Software>)activeProject.findDefaultItems(dc, |
---|
129 | ItemSubtype.getById(dc, SystemItems.getId(Software.FEATURE_EXTRACTION)), false); |
---|
130 | } |
---|
131 | catch (PermissionDeniedException pdex) |
---|
132 | {} |
---|
133 | try |
---|
134 | { |
---|
135 | defaultArrayDesigns = (List<ArrayDesign>)activeProject.findDefaultItems(dc, Item.ARRAYDESIGN, true); |
---|
136 | } |
---|
137 | catch (PermissionDeniedException pdex) |
---|
138 | {} |
---|
139 | try |
---|
140 | { |
---|
141 | defaultPlatforms = (List<Platform>)activeProject.findDefaultItems(dc, Item.PLATFORM, true); |
---|
142 | } |
---|
143 | catch (PermissionDeniedException pdex) |
---|
144 | {} |
---|
145 | try |
---|
146 | { |
---|
147 | defaultVariants = (List<PlatformVariant>)activeProject.findDefaultItems(dc, Item.PLATFORMVARIANT, true); |
---|
148 | } |
---|
149 | catch (PermissionDeniedException pdex) |
---|
150 | {} |
---|
151 | defaultRawDataType = activeProject.getDefaultRawDataType(); |
---|
152 | } |
---|
153 | if (itemId == 0) |
---|
154 | { |
---|
155 | title = "Create raw bioassay"; |
---|
156 | cc.removeObject("item"); |
---|
157 | |
---|
158 | int currentPlatformId = Values.getInt(cc.getPropertyValue("platform"), 0); |
---|
159 | if (currentPlatformId == 0) |
---|
160 | { |
---|
161 | currentPlatformId = Values.getInt(cc.getRecent(Item.PLATFORM.name(), 0), 0); |
---|
162 | } |
---|
163 | int currentVariantId = Values.getInt(cc.getRecent(Item.PLATFORMVARIANT.name(), 0), 0); |
---|
164 | |
---|
165 | try |
---|
166 | { |
---|
167 | if (currentVariantId != 0) currentVariant = PlatformVariant.getById(dc, currentVariantId); |
---|
168 | if (currentPlatformId != 0) currentPlatform = Platform.getById(dc, currentPlatformId); |
---|
169 | } |
---|
170 | catch (Throwable t) |
---|
171 | {} |
---|
172 | if (currentPlatform == null && defaultPlatforms != null && defaultPlatforms.size() > 0) |
---|
173 | { |
---|
174 | currentPlatform = defaultPlatforms.get(0); |
---|
175 | } |
---|
176 | if (currentVariant == null && defaultVariants != null && defaultVariants.size() > 0) |
---|
177 | { |
---|
178 | currentVariant = defaultVariants.get(0); |
---|
179 | } |
---|
180 | |
---|
181 | currentRawDataType = RawDataTypes.getRawDataType(cc.getPropertyValue("rawDataType")); |
---|
182 | if (currentRawDataType == null) |
---|
183 | { |
---|
184 | currentRawDataType = RawDataTypes.getRawDataType(cc.getRecent("RawDataType", 0)); |
---|
185 | } |
---|
186 | if (currentRawDataType == null) currentRawDataType = defaultRawDataType; |
---|
187 | |
---|
188 | |
---|
189 | int bioAssayId = Values.getInt(request.getParameter("bioassay_id")); |
---|
190 | if (bioAssayId != 0) |
---|
191 | { |
---|
192 | currentBioAssay = DerivedBioAssay.getById(dc, bioAssayId); |
---|
193 | } |
---|
194 | else if (cc.getPropertyFilter("parentBioAssay.name") != null) |
---|
195 | { |
---|
196 | currentBioAssay = Base.getFirstMatching(dc, DerivedBioAssay.getQuery(), "name", cc.getPropertyFilter("parentBioAssay.name")); |
---|
197 | } |
---|
198 | |
---|
199 | int extractId = Values.getInt(request.getParameter("extract_id")); |
---|
200 | if (extractId != 0) |
---|
201 | { |
---|
202 | currentExtract = Extract.getById(dc, extractId); |
---|
203 | } |
---|
204 | else if (cc.getPropertyFilter("parentExtract.name") != null) |
---|
205 | { |
---|
206 | currentExtract = Base.getFirstMatching(dc, Extract.getQuery(), "name", cc.getPropertyFilter("parentExtract.name")); |
---|
207 | } |
---|
208 | |
---|
209 | if (currentBioAssay != null) |
---|
210 | { |
---|
211 | name = currentBioAssay.getName() + ".r" + (currentBioAssay.countRawBioAssays() + 1); |
---|
212 | } |
---|
213 | else |
---|
214 | { |
---|
215 | name = Values.getString(cc.getPropertyValue("name"), "New raw bioassay"); |
---|
216 | } |
---|
217 | |
---|
218 | if (cc.getPropertyFilter("protocol.name") != null) |
---|
219 | { |
---|
220 | currentProtocol = Base.getFirstMatching(dc, Protocol.getQuery(), "name", cc.getPropertyFilter("protocol.name")); |
---|
221 | } |
---|
222 | |
---|
223 | if (cc.getPropertyFilter("software.name") != null) |
---|
224 | { |
---|
225 | currentSoftware = Base.getFirstMatching(dc, Software.getQuery(), "name", cc.getPropertyFilter("software.name")); |
---|
226 | } |
---|
227 | |
---|
228 | if (currentBioAssay != null) |
---|
229 | { |
---|
230 | try |
---|
231 | { |
---|
232 | currentArrayDesign = currentBioAssay.getArrayDesign(); |
---|
233 | } |
---|
234 | catch (PermissionDeniedException ex) |
---|
235 | {} |
---|
236 | try |
---|
237 | { |
---|
238 | currentExtract = currentBioAssay.getExtract(); |
---|
239 | } |
---|
240 | catch (PermissionDeniedException ex) |
---|
241 | {} |
---|
242 | } |
---|
243 | if (currentArrayDesign == null && cc.getPropertyFilter("arrayDesign.name") != null) |
---|
244 | { |
---|
245 | currentArrayDesign = Base.getFirstMatching(dc, ArrayDesign.getQuery(), "name", cc.getPropertyFilter("arrayDesign.name")); |
---|
246 | } |
---|
247 | } |
---|
248 | else |
---|
249 | { |
---|
250 | rawBioAssay = RawBioAssay.getById(dc, itemId); |
---|
251 | rawBioAssay.checkPermission(Permission.WRITE); |
---|
252 | hasDbSpots = rawBioAssay.getNumDbSpots() > 0; |
---|
253 | cc.setObject("item", rawBioAssay); |
---|
254 | name = rawBioAssay.getName(); |
---|
255 | try |
---|
256 | { |
---|
257 | currentRawDataType = rawBioAssay.getRawDataType(); |
---|
258 | } |
---|
259 | catch (Throwable t) |
---|
260 | {} |
---|
261 | title = "Edit raw bioassay -- " + HTML.encodeTags(rawBioAssay.getName()); |
---|
262 | |
---|
263 | try |
---|
264 | { |
---|
265 | currentPlatform = rawBioAssay.getPlatform(); |
---|
266 | currentVariant = rawBioAssay.getVariant(); |
---|
267 | } |
---|
268 | catch (PermissionDeniedException ex) |
---|
269 | { |
---|
270 | deniedPlatform = true; |
---|
271 | } |
---|
272 | |
---|
273 | try |
---|
274 | { |
---|
275 | currentBioAssay = rawBioAssay.getParentBioAssay(); |
---|
276 | } |
---|
277 | catch (PermissionDeniedException ex) |
---|
278 | { |
---|
279 | readCurrentBioAssay = false; |
---|
280 | } |
---|
281 | try |
---|
282 | { |
---|
283 | currentExtract = rawBioAssay.getParentExtract(); |
---|
284 | } |
---|
285 | catch (PermissionDeniedException ex) |
---|
286 | { |
---|
287 | readCurrentExtract = false; |
---|
288 | } |
---|
289 | try |
---|
290 | { |
---|
291 | currentProtocol = rawBioAssay.getProtocol(); |
---|
292 | } |
---|
293 | catch (PermissionDeniedException ex) |
---|
294 | { |
---|
295 | readCurrentProtocol = false; |
---|
296 | } |
---|
297 | try |
---|
298 | { |
---|
299 | currentSoftware = rawBioAssay.getSoftware(); |
---|
300 | } |
---|
301 | catch (PermissionDeniedException ex) |
---|
302 | { |
---|
303 | readCurrentSoftware = false; |
---|
304 | } |
---|
305 | try |
---|
306 | { |
---|
307 | currentArrayDesign = rawBioAssay.getArrayDesign(); |
---|
308 | } |
---|
309 | catch (PermissionDeniedException ex) |
---|
310 | { |
---|
311 | readCurrentArrayDesign = false; |
---|
312 | } |
---|
313 | } |
---|
314 | |
---|
315 | ItemQuery<Platform> platformQuery = Platform.getQuery(); |
---|
316 | platformQuery.include(Include.REMOVED, Include.NOT_REMOVED); |
---|
317 | platformQuery.order(Orders.asc(Hql.property("name"))); |
---|
318 | platformQuery.setCacheResult(true); |
---|
319 | ItemResultList<Platform> platforms = platformQuery.list(dc); |
---|
320 | |
---|
321 | ItemQuery<PlatformVariant> variantQuery = PlatformVariant.getQuery(); |
---|
322 | variantQuery.include(Include.REMOVED, Include.NOT_REMOVED); |
---|
323 | variantQuery.order(Orders.asc(Hql.property("name"))); |
---|
324 | variantQuery.setCacheResult(true); |
---|
325 | ItemResultList<PlatformVariant> variants = variantQuery.list(dc); |
---|
326 | |
---|
327 | final String clazz = "class=\"text\""; |
---|
328 | final String requiredClazz = "class=\"text required\""; |
---|
329 | JspContext jspContext = ExtensionsControl.createContext(dc, pageContext, GuiContext.item(itemType), rawBioAssay); |
---|
330 | ExtensionsInvoker invoker = EditUtil.useEditExtensions(jspContext); |
---|
331 | %> |
---|
332 | <base:page type="popup" title="<%=title%>"> |
---|
333 | <base:head scripts="tabcontrol.js,annotations.js,platforms.js,ajax.js,json2.js" styles="tabcontrol.css"> |
---|
334 | <ext:scripts context="<%=jspContext%>" /> |
---|
335 | <ext:stylesheets context="<%=jspContext%>" /> |
---|
336 | <script language="JavaScript"> |
---|
337 | // Validate the "RawBioAssay" tab |
---|
338 | function validateRawBioAssay() |
---|
339 | { |
---|
340 | var frm = document.forms['rawbioassay']; |
---|
341 | if (Main.trimString(frm.name.value) == '') |
---|
342 | { |
---|
343 | alert("You must enter a name"); |
---|
344 | frm.name.focus(); |
---|
345 | return false; |
---|
346 | } |
---|
347 | return true; |
---|
348 | } |
---|
349 | |
---|
350 | // Submit the form |
---|
351 | function saveSettings() |
---|
352 | { |
---|
353 | var frm = document.forms['rawbioassay']; |
---|
354 | if (TabControl.validateActiveTab('settings')) |
---|
355 | { |
---|
356 | if (annotationsLoaded) |
---|
357 | { |
---|
358 | Annotations.addModifiedAnnotationsToForm(frames.annotations, frm); |
---|
359 | } |
---|
360 | if (inheritedAnnotationsLoaded) |
---|
361 | { |
---|
362 | Annotations.addInheritedAnnotationsToForm(frames.inheritedAnnotations, frm); |
---|
363 | } |
---|
364 | if (dataFilesLoaded) |
---|
365 | { |
---|
366 | frames.datafiles.writeFileActionsToForm(frm); |
---|
367 | } |
---|
368 | frm.submit(); |
---|
369 | } |
---|
370 | } |
---|
371 | |
---|
372 | var annotationsLoaded = false; |
---|
373 | var inheritedAnnotationsLoaded = false; |
---|
374 | var parentsChanged = false; |
---|
375 | var protocolChanged = false; |
---|
376 | var dataFilesLoaded = false; |
---|
377 | var platformChanged = false; |
---|
378 | function switchTab(tabControlId, tabId) |
---|
379 | { |
---|
380 | var frm = document.forms['rawbioassay']; |
---|
381 | if (TabControl.setActiveTab(tabControlId, tabId)) |
---|
382 | { |
---|
383 | if (tabId == 'annotations' && (protocolChanged || !annotationsLoaded)) |
---|
384 | { |
---|
385 | Annotations.loadAnnotateFrame(frames.annotations, '<%=ID%>', '<%=itemType.name()%>', <%=rawBioAssay == null ? 0 : rawBioAssay.getId()%>, getProtocolId()); |
---|
386 | annotationsLoaded = true; |
---|
387 | protocolChanged = false; |
---|
388 | } |
---|
389 | else if (tabId == 'inheritedAnnotations' && |
---|
390 | (parentsChanged || !inheritedAnnotationsLoaded)) |
---|
391 | { |
---|
392 | Annotations.loadInheritFrame(frames.inheritedAnnotations, '<%=ID%>', '<%=itemType.name()%>', <%=itemId%>, getParents()); |
---|
393 | inheritedAnnotationsLoaded = true; |
---|
394 | parentsChanged = false; |
---|
395 | } |
---|
396 | else if (tabId == 'datafiles' && (platformChanged || !dataFilesLoaded)) |
---|
397 | { |
---|
398 | var platform = Platforms.getSelectedPlatform(frm.platform); |
---|
399 | var variant = Platforms.getSelectedVariant(frm.platform); |
---|
400 | Platforms.loadDataFilesFrame(frames.datafiles, '<%=ID%>', '<%=itemType.name()%>', <%=rawBioAssay == null ? 0 : rawBioAssay.getId()%>, platform == null ? 0 : platform.id, variant == null ? 0 : variant.id); |
---|
401 | dataFilesLoaded = true; |
---|
402 | platformChanged = false; |
---|
403 | } |
---|
404 | } |
---|
405 | } |
---|
406 | |
---|
407 | function platformOnChange() |
---|
408 | { |
---|
409 | var frm = document.forms['rawbioassay']; |
---|
410 | platformChanged = true; |
---|
411 | var platform = Platforms.getSelectedPlatform(frm.platform); |
---|
412 | var variant = Platforms.getSelectedVariant(frm.platform); |
---|
413 | var fileOnly = (variant != null && variant.fileOnly) || |
---|
414 | (variant == null && platform.fileOnly); |
---|
415 | var rawDataType = variant == null ? platform.rawDataType : variant.rawDataType; |
---|
416 | if (frm.rawdatatype[frm.rawdatatype.length - 1].value == '') |
---|
417 | { |
---|
418 | frm.rawdatatype[frm.rawdatatype.length - 1] = null; |
---|
419 | } |
---|
420 | if (fileOnly) |
---|
421 | { |
---|
422 | frm.rawdatatype.disabled = true; |
---|
423 | Main.removeClass(frm.rawdatatype, 'required'); |
---|
424 | frm.rawdatatype[frm.rawdatatype.length] = new Option('- file only -', ''); |
---|
425 | frm.rawdatatype.selectedIndex = frm.rawdatatype.length - 1; |
---|
426 | } |
---|
427 | else if (rawDataType) |
---|
428 | { |
---|
429 | frm.rawdatatype.disabled = true; |
---|
430 | Main.removeClass(frm.rawdatatype, 'required'); |
---|
431 | Forms.selectListOption(frm.rawdatatype, rawDataType); |
---|
432 | } |
---|
433 | else |
---|
434 | { |
---|
435 | frm.rawdatatype.disabled = <%=hasDbSpots ? "true" : "false"%>; |
---|
436 | Main.addClass(frm.rawdatatype, 'required'); |
---|
437 | } |
---|
438 | } |
---|
439 | |
---|
440 | function getProtocolId() |
---|
441 | { |
---|
442 | var frm = document.forms['rawbioassay']; |
---|
443 | var protocolId = 0; |
---|
444 | if (frm.protocol_id.length > 0 && !frm.protocol_id.disabled) |
---|
445 | { |
---|
446 | protocolId = Math.abs(parseInt(frm.protocol_id[frm.protocol_id.selectedIndex].value)); |
---|
447 | } |
---|
448 | return protocolId; |
---|
449 | } |
---|
450 | |
---|
451 | function getParents() |
---|
452 | { |
---|
453 | var frm = document.forms['rawbioassay']; |
---|
454 | var parents = new Array(); |
---|
455 | |
---|
456 | var bioAssayId = Math.abs(parseInt(frm.bioassay_id[frm.bioassay_id.selectedIndex].value)); |
---|
457 | if (bioAssayId > 0) parents[parents.length] = 'DERIVEDBIOASSAY:'+bioAssayId; |
---|
458 | var extractId = Math.abs(parseInt(frm.extract_id[frm.extract_id.selectedIndex].value)); |
---|
459 | if (extractId > 0) parents[parents.length] = 'EXTRACT:'+extractId; |
---|
460 | if (frm.arraydesign_id) |
---|
461 | { |
---|
462 | var arrayDesignId = Math.abs(parseInt(frm.arraydesign_id[frm.arraydesign_id.selectedIndex].value)); |
---|
463 | if (arrayDesignId > 0) parents[parents.length] = 'ARRAYDESIGN:'+arrayDesignId; |
---|
464 | } |
---|
465 | return parents; |
---|
466 | } |
---|
467 | |
---|
468 | function selectProtocolOnClick() |
---|
469 | { |
---|
470 | var frm = document.forms['rawbioassay']; |
---|
471 | var url = '../../admin/protocols/index.jsp?ID=<%=ID%>&cmd=UpdateContext&mode=selectone&callback=setProtocolCallback'; |
---|
472 | if (frm.protocol_id.length > 1) |
---|
473 | { |
---|
474 | var id = Math.abs(parseInt(frm.protocol_id[1].value)); |
---|
475 | url += '&item_id='+id; |
---|
476 | } |
---|
477 | url += '&resetTemporary=1&tmpfilter:INT:itemSubtype=<%=SystemItems.getId(Protocol.FEATURE_EXTRACTION)%>'; |
---|
478 | Main.openPopup(url, 'SelectProtocol', 1050, 700); |
---|
479 | } |
---|
480 | function setProtocolCallback(id, name) |
---|
481 | { |
---|
482 | var frm = document.forms['rawbioassay']; |
---|
483 | var list = frm.protocol_id; |
---|
484 | if (list.length < 2 || list[1].value == '0') // > |
---|
485 | { |
---|
486 | Forms.addListOption(list, 1, new Option()); |
---|
487 | } |
---|
488 | list[1].value = id; |
---|
489 | list[1].text = name; |
---|
490 | list.selectedIndex = 1; |
---|
491 | protocolChanged = true; |
---|
492 | } |
---|
493 | function protocolOnChange() |
---|
494 | { |
---|
495 | protocolChanged = true; |
---|
496 | } |
---|
497 | |
---|
498 | function bioAssayOnChange() |
---|
499 | { |
---|
500 | var frm = document.forms['rawbioassay']; |
---|
501 | var selectedIndex = frm.bioassay_id.selectedIndex |
---|
502 | var bioAssayId = Math.abs(frm.bioassay_id[selectedIndex].value); |
---|
503 | if (bioAssayId > 0) updateArrayDesign(bioAssayId); |
---|
504 | |
---|
505 | initExtracts(); |
---|
506 | parentsChanged = true; |
---|
507 | } |
---|
508 | function selectBioAssayOnClick() |
---|
509 | { |
---|
510 | var frm = document.forms['rawbioassay']; |
---|
511 | var url = '../derivedbioassays/index.jsp?ID=<%=ID%>&cmd=UpdateContext&mode=selectone&callback=setBioAssayCallback'; |
---|
512 | if (frm.bioassay_id.length > 1) |
---|
513 | { |
---|
514 | var id = Math.abs(parseInt(frm.bioassay_id[1].value)); |
---|
515 | url += '&item_id='+id; |
---|
516 | } |
---|
517 | Main.openPopup(url, 'SelectDerivedBioAssay', 1050, 700); |
---|
518 | } |
---|
519 | function setBioAssayCallback(id, name) |
---|
520 | { |
---|
521 | var frm = document.forms['rawbioassay']; |
---|
522 | var list = frm.bioassay_id; |
---|
523 | if (list.length < 2 || list[1].value == '0') // > |
---|
524 | { |
---|
525 | Forms.addListOption(list, 1, new Option()); |
---|
526 | } |
---|
527 | list[1].value = id; |
---|
528 | list[1].text = name; |
---|
529 | list.selectedIndex = 1; |
---|
530 | bioAssayOnChange(); |
---|
531 | } |
---|
532 | |
---|
533 | function extractOnChange() |
---|
534 | { |
---|
535 | parentsChanged = true; |
---|
536 | } |
---|
537 | function selectExtractOnClick() |
---|
538 | { |
---|
539 | var frm = document.forms['rawbioassay']; |
---|
540 | var url = '../../biomaterials/extracts/index.jsp?ID=<%=ID%>&cmd=UpdateContext&mode=selectone&callback=setExtractCallback'; |
---|
541 | if (frm.extract_id.length > 1) |
---|
542 | { |
---|
543 | var id = Math.abs(parseInt(frm.extract_id[1].value)); |
---|
544 | url += '&item_id='+id; |
---|
545 | } |
---|
546 | Main.openPopup(url, 'SelectExtract', 1050, 700); |
---|
547 | } |
---|
548 | function setExtractCallback(id, name) |
---|
549 | { |
---|
550 | var frm = document.forms['rawbioassay']; |
---|
551 | var list = frm.extract_id; |
---|
552 | if (list.length < 2 || list[1].value == '0') // > |
---|
553 | { |
---|
554 | Forms.addListOption(list, 1, new Option()); |
---|
555 | } |
---|
556 | list[1].value = id; |
---|
557 | list[1].text = name; |
---|
558 | list.selectedIndex = 1; |
---|
559 | extractOnChange(); |
---|
560 | } |
---|
561 | |
---|
562 | function selectSoftwareOnClick() |
---|
563 | { |
---|
564 | var frm = document.forms['rawbioassay']; |
---|
565 | var url = '../../admin/software/index.jsp?ID=<%=ID%>&cmd=UpdateContext&mode=selectone&callback=setSoftwareCallback'; |
---|
566 | if (frm.software_id.length > 1) |
---|
567 | { |
---|
568 | var id = Math.abs(parseInt(frm.software_id[1].value)); |
---|
569 | url += '&item_id='+id; |
---|
570 | } |
---|
571 | url += '&resetTemporary=1&tmpfilter:INT:itemSubtype=<%=SystemItems.getId(Software.FEATURE_EXTRACTION)%>'; |
---|
572 | Main.openPopup(url, 'SelectSoftware', 1050, 700); |
---|
573 | } |
---|
574 | function setSoftwareCallback(id, name) |
---|
575 | { |
---|
576 | var frm = document.forms['rawbioassay']; |
---|
577 | var list = frm.software_id; |
---|
578 | if (list.length < 2 || list[1].value == '0') // > |
---|
579 | { |
---|
580 | Forms.addListOption(list, 1, new Option()); |
---|
581 | } |
---|
582 | list[1].value = id; |
---|
583 | list[1].text = name; |
---|
584 | list.selectedIndex = 1; |
---|
585 | } |
---|
586 | |
---|
587 | function arrayDesignOnChange() |
---|
588 | { |
---|
589 | parentsChanged = true; |
---|
590 | <% |
---|
591 | if (rawBioAssay != null && rawBioAssay.getNumDbSpots() > 0) |
---|
592 | { |
---|
593 | %> |
---|
594 | var frm = document.forms['rawbioassay']; |
---|
595 | var selectedId = frm.arraydesign_id[frm.arraydesign_id.selectedIndex].value; |
---|
596 | var showFiMethod = (selectedId > 0 && selectedId != <%=currentArrayDesign == null ? 0 : currentArrayDesign.getId()%>); |
---|
597 | if (showFiMethod) |
---|
598 | { |
---|
599 | Main.show('fiMethod'); |
---|
600 | } |
---|
601 | else |
---|
602 | { |
---|
603 | Main.hide('fiMethod'); |
---|
604 | } |
---|
605 | <% |
---|
606 | } |
---|
607 | %> |
---|
608 | } |
---|
609 | function selectArrayDesignOnClick() |
---|
610 | { |
---|
611 | var frm = document.forms['rawbioassay']; |
---|
612 | var url = '../../lims/arraydesigns/index.jsp?ID=<%=ID%>&cmd=UpdateContext&mode=selectone&callback=setArrayDesignCallback'; |
---|
613 | if (frm.arraydesign_id.length > 1) |
---|
614 | { |
---|
615 | var id = Math.abs(parseInt(frm.arraydesign_id[1].value)); |
---|
616 | url += '&item_id='+id; |
---|
617 | } |
---|
618 | var platform = Platforms.getSelectedPlatform(frm.platform); |
---|
619 | url += '&resetTemporary=1&tmpfilter:INT:platform='+platform.id; |
---|
620 | Main.openPopup(url, 'SelectArrayDesign', 1050, 700); |
---|
621 | } |
---|
622 | function setArrayDesignCallback(id, name) |
---|
623 | { |
---|
624 | var frm = document.forms['rawbioassay']; |
---|
625 | var list = frm.arraydesign_id; |
---|
626 | if (list.length < 2 || list[1].value == '0') // > |
---|
627 | { |
---|
628 | Forms.addListOption(list, 1, new Option()); |
---|
629 | } |
---|
630 | list[1].value = id; |
---|
631 | list[1].text = name; |
---|
632 | list.selectedIndex = 1; |
---|
633 | parentsChanged = true; |
---|
634 | arrayDesignOnChange(); |
---|
635 | } |
---|
636 | |
---|
637 | function updateArrayDesign(bioAssayId) |
---|
638 | { |
---|
639 | if (!bioAssayId) return; |
---|
640 | var request = Ajax.getXmlHttpRequest(); |
---|
641 | var url = '../derivedbioassays/ajax.jsp?ID=<%=ID%>&cmd=GetArrayDesign&item_id=' + bioAssayId; |
---|
642 | request.open("GET", url, false); |
---|
643 | request.send(null); |
---|
644 | |
---|
645 | var response = JSON.parse(request.responseText); |
---|
646 | if (response.status != 'ok') |
---|
647 | { |
---|
648 | alert(response.message); |
---|
649 | return null; |
---|
650 | } |
---|
651 | |
---|
652 | var frm = document.forms['rawbioassay']; |
---|
653 | if (response.id) |
---|
654 | { |
---|
655 | var designList = frm.arraydesign_id; |
---|
656 | if (designList.length < 2 || designList[1].value == '0') // > |
---|
657 | { |
---|
658 | Forms.addListOption(designList, 1, new Option()); |
---|
659 | } |
---|
660 | designList[1].value = response.id; |
---|
661 | designList[1].text = response.name; |
---|
662 | designList.selectedIndex = 1; |
---|
663 | } |
---|
664 | } |
---|
665 | |
---|
666 | function initExtracts() |
---|
667 | { |
---|
668 | var frm = document.forms['rawbioassay']; |
---|
669 | var bioAssayId = Math.abs(frm.bioassay_id[frm.bioassay_id.selectedIndex].value); |
---|
670 | |
---|
671 | var extracts = null; |
---|
672 | if (bioAssayId > 0) |
---|
673 | { |
---|
674 | extracts = getExtractsFromParentBioassay(bioAssayId); |
---|
675 | } |
---|
676 | |
---|
677 | var currentExtractId = Math.abs(frm.extract_id[frm.extract_id.selectedIndex].value); |
---|
678 | frm.extract_id.length = 0; |
---|
679 | frm.extract_id[frm.extract_id.length] = new Option('- none -', 0); |
---|
680 | var currentWasFound = 0; |
---|
681 | if (extracts != null) |
---|
682 | { |
---|
683 | for (var i = 0; i < extracts.length; i++) |
---|
684 | { |
---|
685 | var position = extracts[i].position; |
---|
686 | var prefix = position ? position + ': ' : ''; |
---|
687 | frm.extract_id[frm.extract_id.length] = new Option(prefix + extracts[i].name, extracts[i].id); |
---|
688 | if (currentExtractId == extracts[i].id) |
---|
689 | { |
---|
690 | frm.extract_id.selectedIndex = frm.extract_id.length - 1; |
---|
691 | currentWasFound = 1; |
---|
692 | } |
---|
693 | } |
---|
694 | } |
---|
695 | <% |
---|
696 | if (currentExtract != null) |
---|
697 | { |
---|
698 | %> |
---|
699 | if (currentExtractId && !currentWasFound) |
---|
700 | { |
---|
701 | frm.extract_id[frm.extract_id.length] = new Option('<%=HTML.javaScriptEncode(currentExtract.getName())%>', currentExtractId); |
---|
702 | frm.extract_id.selectedIndex = frm.extract_id.length - 1; |
---|
703 | } |
---|
704 | <% |
---|
705 | } |
---|
706 | %> |
---|
707 | } |
---|
708 | |
---|
709 | function getExtractsFromParentBioassay(bioAssayId) |
---|
710 | { |
---|
711 | if (!bioAssayId) return null; |
---|
712 | var request = Ajax.getXmlHttpRequest(); |
---|
713 | var url = '../derivedbioassays/ajax.jsp?ID=<%=ID%>&cmd=GetExtracts'; |
---|
714 | url += '&item_id=' + bioAssayId; |
---|
715 | request.open("GET", url, false); |
---|
716 | request.send(null); |
---|
717 | |
---|
718 | var response = JSON.parse(request.responseText); |
---|
719 | if (response.status != 'ok') |
---|
720 | { |
---|
721 | alert(response.message); |
---|
722 | return null; |
---|
723 | } |
---|
724 | return response.sources; |
---|
725 | } |
---|
726 | |
---|
727 | function init() |
---|
728 | { |
---|
729 | <% |
---|
730 | if (rawBioAssay == null) |
---|
731 | { |
---|
732 | %> |
---|
733 | var frm = document.forms['rawbioassay']; |
---|
734 | frm.name.focus(); |
---|
735 | frm.name.select(); |
---|
736 | <% |
---|
737 | } |
---|
738 | %> |
---|
739 | initPlatforms(<%=currentPlatform == null ? 0 : currentPlatform.getId()%>, <%=currentVariant == null ? 0 : currentVariant.getId()%>); |
---|
740 | platformOnChange(); |
---|
741 | <% |
---|
742 | if (currentBioAssay != null) |
---|
743 | { |
---|
744 | %> |
---|
745 | initExtracts(); |
---|
746 | <% |
---|
747 | } |
---|
748 | %> |
---|
749 | } |
---|
750 | |
---|
751 | function initPlatforms(platformId, variantId) |
---|
752 | { |
---|
753 | <% |
---|
754 | for (Platform p : platforms) |
---|
755 | { |
---|
756 | if (!p.isRemoved() || p.equals(currentPlatform)) |
---|
757 | { |
---|
758 | RawDataType rdt = p.isFileOnly() ? null : p.getRawDataType(); |
---|
759 | %> |
---|
760 | var p<%=p.getId()%> = new Platform(<%=p.getId()%>, '<%=HTML.javaScriptEncode(p.getExternalId())%>', '<%=HTML.javaScriptEncode(p.getName())%>', <%=p.isFileOnly()%>, '<%=rdt == null ? "" : rdt.getId()%>'); |
---|
761 | <% |
---|
762 | } |
---|
763 | } |
---|
764 | for (PlatformVariant v : variants) |
---|
765 | { |
---|
766 | Platform p = v.getPlatform(); |
---|
767 | if ((!v.isRemoved() || v.equals(currentVariant)) && (!p.isRemoved() || p.equals(currentPlatform))) |
---|
768 | { |
---|
769 | RawDataType rdt = v.isFileOnly() ? null : v.getRawDataType(); |
---|
770 | %> |
---|
771 | var v<%=v.getId()%> = new Variant(p<%=p.getId()%>, <%=v.getId()%>, '<%=HTML.javaScriptEncode(v.getExternalId())%>', '<%=HTML.javaScriptEncode(v.getName())%>', <%=v.isFileOnly()%>, '<%=rdt == null ? "" : rdt.getId()%>'); |
---|
772 | <% |
---|
773 | } |
---|
774 | } |
---|
775 | %> |
---|
776 | var frm = document.forms['rawbioassay']; |
---|
777 | Platforms.populateList(frm.platform, platformId, variantId); |
---|
778 | } |
---|
779 | </script> |
---|
780 | </base:head> |
---|
781 | <base:body onload="init()"> |
---|
782 | <h1><%=title%> <base:help tabcontrol="settings" /></h1> |
---|
783 | <form action="index.jsp?ID=<%=ID%>" method="post" name="rawbioassay" onsubmit="return false;"> |
---|
784 | <input type="hidden" name="cmd" value="UpdateItem"> |
---|
785 | |
---|
786 | <t:tabcontrol id="settings" |
---|
787 | subclass="content dialogtabcontrol" |
---|
788 | position="bottom" active="<%=tabId%>" |
---|
789 | remember="<%=tabId == null && rawBioAssay != null%>" |
---|
790 | switch="switchTab" |
---|
791 | extensions="<%=invoker%>"> |
---|
792 | <t:tab id="info" title="Raw bioassay" validate="validateRawBioAssay()" helpid="rawbioassay.edit"> |
---|
793 | <table class="fullform input100"> |
---|
794 | <tr> |
---|
795 | <th>Name</th> |
---|
796 | <td><input <%=requiredClazz%> type="text" name="name" |
---|
797 | value="<%=HTML.encodeTags(name)%>" |
---|
798 | maxlength="<%=RawBioAssay.MAX_NAME_LENGTH%>"></td> |
---|
799 | <td></td> |
---|
800 | </tr> |
---|
801 | <tr> |
---|
802 | <th>Platform</th> |
---|
803 | <td> |
---|
804 | <select name="platform" onchange="platformOnChange()" class="required" |
---|
805 | <%=deniedPlatform || hasDbSpots ? "disabled" : "" %>> |
---|
806 | <% |
---|
807 | if (deniedPlatform) |
---|
808 | { |
---|
809 | %> |
---|
810 | <option value="-1">- denied - |
---|
811 | <% |
---|
812 | } |
---|
813 | %> |
---|
814 | </select> |
---|
815 | </td> |
---|
816 | <td></td> |
---|
817 | </tr> |
---|
818 | <tr> |
---|
819 | <th>Raw data type</th> |
---|
820 | <td> |
---|
821 | <select name="rawdatatype" class="required" |
---|
822 | <%=hasDbSpots ? "disabled" : "" %>> |
---|
823 | <% |
---|
824 | for (RawDataType rdt : RawDataTypes.getSortedRawDataTypes(new RawDataTypes.NameComparator())) |
---|
825 | { |
---|
826 | if (rdt.isStoredInDb()) |
---|
827 | { |
---|
828 | String selected = rdt.equals(currentRawDataType) ? "selected" : ""; |
---|
829 | %> |
---|
830 | <option value="<%=rdt.getId()%>" <%=selected%>><%=HTML.encodeTags(rdt.getName())%> |
---|
831 | <% |
---|
832 | } |
---|
833 | } |
---|
834 | %> |
---|
835 | </select> |
---|
836 | </td> |
---|
837 | <td></td> |
---|
838 | </tr> |
---|
839 | <tr> |
---|
840 | <th>Parent bioassay</th> |
---|
841 | <td> |
---|
842 | <base:select |
---|
843 | id="bioassay_id" |
---|
844 | clazz="selectionlist" |
---|
845 | required="false" |
---|
846 | current="<%=currentBioAssay%>" |
---|
847 | denied="<%=!readCurrentBioAssay%>" |
---|
848 | recent="<%=recentBioAssays%>" |
---|
849 | newitem="<%=rawBioAssay == null%>" |
---|
850 | selectrecent="<%=currentExtract == null %>" |
---|
851 | onselect="selectBioAssayOnClick()" |
---|
852 | onchange="bioAssayOnChange()" |
---|
853 | /> |
---|
854 | </td> |
---|
855 | <td></td> |
---|
856 | </tr> |
---|
857 | <tr> |
---|
858 | <th>Parent extract</th> |
---|
859 | <td> |
---|
860 | <base:select |
---|
861 | id="extract_id" |
---|
862 | clazz="selectionlist" |
---|
863 | required="false" |
---|
864 | current="<%=currentExtract%>" |
---|
865 | denied="<%=!readCurrentExtract%>" |
---|
866 | recent="<%=recentExtracts%>" |
---|
867 | newitem="<%=rawBioAssay == null%>" |
---|
868 | selectrecent="false" |
---|
869 | onselect="selectExtractOnClick()" |
---|
870 | onchange="extractOnChange()" |
---|
871 | /> |
---|
872 | </td> |
---|
873 | <td></td> |
---|
874 | </tr> |
---|
875 | <tr> |
---|
876 | <th>Array design</th> |
---|
877 | <td> |
---|
878 | <base:select |
---|
879 | id="arraydesign_id" |
---|
880 | clazz="selectionlist" |
---|
881 | required="false" |
---|
882 | current="<%=currentArrayDesign%>" |
---|
883 | denied="<%=!readCurrentArrayDesign%>" |
---|
884 | recent="<%=recentArrayDesigns%>" |
---|
885 | defaultitems="<%=defaultArrayDesigns%>" |
---|
886 | newitem="<%=rawBioAssay == null%>" |
---|
887 | onselect="selectArrayDesignOnClick()" |
---|
888 | onchange="arrayDesignOnChange()" |
---|
889 | /> |
---|
890 | </td> |
---|
891 | <td></td> |
---|
892 | </tr> |
---|
893 | <tr id="fiMethod" style="display: none;"> |
---|
894 | <th></th> |
---|
895 | <td> |
---|
896 | <select name="fiMethod"> |
---|
897 | <option value="">-auto- (array design decides) |
---|
898 | <option value="COORDINATES">Coordinates |
---|
899 | <option value="POSITION">Position |
---|
900 | <option value="FEATURE_ID">Feature ID (*) |
---|
901 | </select> |
---|
902 | <br> |
---|
903 | Select a method for feature identification. <br> |
---|
904 | (*) The Feature ID method only works if the raw data is currently |
---|
905 | connected to an array design which has Feature ID values. |
---|
906 | </td> |
---|
907 | <td></td> |
---|
908 | </tr> |
---|
909 | <tr> |
---|
910 | <th>Protocol</th> |
---|
911 | <td> |
---|
912 | <base:select |
---|
913 | id="protocol_id" |
---|
914 | clazz="selectionlist" |
---|
915 | required="false" |
---|
916 | current="<%=currentProtocol%>" |
---|
917 | denied="<%=!readCurrentProtocol%>" |
---|
918 | recent="<%=recentProtocols%>" |
---|
919 | defaultitems="<%=defaultProtocols%>" |
---|
920 | newitem="<%=rawBioAssay == null%>" |
---|
921 | onselect="selectProtocolOnClick()" |
---|
922 | onchange="protocolOnChange()" |
---|
923 | /> |
---|
924 | </td> |
---|
925 | <td></td> |
---|
926 | </tr> |
---|
927 | <tr> |
---|
928 | <th>Software</th> |
---|
929 | <td> |
---|
930 | <base:select |
---|
931 | id="software_id" |
---|
932 | clazz="selectionlist" |
---|
933 | required="false" |
---|
934 | current="<%=currentSoftware%>" |
---|
935 | denied="<%=!readCurrentSoftware%>" |
---|
936 | recent="<%=recentSoftware%>" |
---|
937 | defaultitems="<%=defaultSoftware%>" |
---|
938 | newitem="<%=rawBioAssay == null%>" |
---|
939 | onselect="selectSoftwareOnClick()" |
---|
940 | /> |
---|
941 | </td> |
---|
942 | <td></td> |
---|
943 | </tr> |
---|
944 | <tr class="dynamic"> |
---|
945 | <th>Description</th> |
---|
946 | <td> |
---|
947 | <textarea <%=clazz%> rows="6" name="description" |
---|
948 | ><%=HTML.encodeTags(rawBioAssay == null ? cc.getPropertyValue("description") : rawBioAssay.getDescription())%></textarea> |
---|
949 | </td> |
---|
950 | <td style="width: 20px;"> |
---|
951 | <base:icon image="zoom.png" |
---|
952 | onclick="Main.zoom('Description', 'rawbioassay', 'description')" |
---|
953 | tooltip="Edit in larger window" |
---|
954 | /> |
---|
955 | </td> |
---|
956 | </tr> |
---|
957 | </table> |
---|
958 | </t:tab> |
---|
959 | |
---|
960 | <t:tab id="datafiles" title="Data files" helpid="datafiles.edit"><iframe |
---|
961 | name="datafiles" id="idDatafiles" src="../../common/datafiles/wait.jsp" |
---|
962 | style="width: 100%; height: 100%;"></iframe></t:tab> |
---|
963 | |
---|
964 | <t:tab id="annotations" title="Annotations & parameters" helpid="annotations.edit"><iframe |
---|
965 | name="annotations" id="idAnnotations" src="../../common/annotations/wait.jsp" |
---|
966 | style="width: 100%; height: 100%;"></iframe></t:tab> |
---|
967 | |
---|
968 | <t:tab id="inheritedAnnotations" title="Inherited annotations" |
---|
969 | helpid="annotations.edit.inherited"><iframe |
---|
970 | name="inheritedAnnotations" id="idInheritedAnnotations" src="../../common/annotations/wait.jsp" |
---|
971 | style="width: 100%; height: 100%;"></iframe></t:tab> |
---|
972 | </t:tabcontrol> |
---|
973 | </form> |
---|
974 | |
---|
975 | <div class="legend"> |
---|
976 | <base:icon image="required.png" />= required information |
---|
977 | </div> |
---|
978 | |
---|
979 | <base:buttongroup subclass="dialogbuttons"> |
---|
980 | <base:button onclick="saveSettings()" title="Save" /> |
---|
981 | <base:button onclick="window.close()" title="Cancel" /> |
---|
982 | </base:buttongroup> |
---|
983 | </base:body> |
---|
984 | </base:page> |
---|
985 | <% |
---|
986 | } |
---|
987 | finally |
---|
988 | { |
---|
989 | if (dc != null) dc.close(); |
---|
990 | } |
---|
991 | %> |
---|