source: trunk/grails-app/views/assay/selectAssay.gsp @ 1430

Last change on this file since 1430 was 1430, checked in by work@…, 12 years ago
  • set keyword expansion
  • Property svn:keywords set to Rev Author Date
File size: 1.1 KB
Line 
1<%--
2  Created by IntelliJ IDEA.
3  User: siemensikkema
4  Date: Nov 30, 2010
5  Time: 4:07:28 PM
6--%>
7
8<%@ page import="dbnp.studycapturing.Study" contentType="text/html;charset=UTF-8" %>
9<html>
10  <head>
11    <meta name="layout" content="main" />
12    <title>Select an assay</title>
13    <script type="text/javascript">
14      function updateAssay(jsonData, selectID) {
15        var a = eval(jsonData);
16        var sel = $('#'+selectID).empty()
17       
18        $(a).each(function(i, el){
19          sel.append($("<option></option>").attr("value",el.id).text(el.name));
20        });
21      }
22    </script>
23  </head>
24  <body>
25  <div style="color:red;">
26    ${flash.errorMessage}
27  </div>
28  <g:form name="assaySelect" action="exportAssayAsExcel">
29    <g:select optionKey="id" optionValue="title" name="studyId" from="${userStudies}"
30            onChange="${remoteFunction(controller:'study',action:'ajaxGetAssays',params:'\'id=\'+escape(this.value)',onComplete: 'updateAssay(XMLHttpRequest.responseText, \'assay\')')}"/>
31    <g:select optionKey="id" name="assayId" id="assay" from="${assays}"/>
32    <g:submitButton name="submit" value="Submit"/>
33  </g:form>
34  </body>
35</html>
Note: See TracBrowser for help on using the repository browser.