source: trunk/grails-app/views/simpleWizard/_javascripts.gsp @ 1810

Last change on this file since 1810 was 1810, checked in by work@…, 9 years ago
  • added minified css / js support
  • gdt up to 0.0.41 (minified)
  • Property svn:keywords set to Rev Author Date
File size: 4.5 KB
Line 
1<g:if env="development">
2        <% /* Nice buttons */ %>
3        <link rel="stylesheet" href="<g:resource dir="css" file="buttons.css" />" type="text/css"/>
4
5        <% /* Generic wizard stylesheets and javascripts */ %>
6        <link rel="stylesheet" href="${resource(dir: 'css', file: 'studywizard.css')}" />
7        <link rel="stylesheet" href="${resource(dir: 'css', file: 'templates.css')}" />
8
9        <script type="text/javascript" src="${resource(dir: 'js', file: 'studywizard.js' )}"></script>
10        <script type="text/javascript" src="${resource(dir: 'js', file: 'tooltips.js', plugin: 'gdt')}"></script>
11
12        <% /* Table editor */ %>
13        <link rel="stylesheet" href="${resource(dir: 'css', file: 'table-editor.css', plugin: 'gdt')}" />
14        <script type="text/javascript" src="${resource(dir: 'js', file: 'table-editor.js', plugin: 'gdt')}"></script>
15
16        <script type="text/javascript" src="${resource(dir: 'js', file: 'jquery.qtip-1.0.0-rc3.js', plugin: 'gdt')}"></script>
17        <script type="text/javascript" src="${resource(dir: 'js', file: 'ontology-chooser.js', plugin: 'gdt')}"></script>
18        <script type="text/javascript" src="${resource(dir: 'js', file: 'publication-chooser.js')}"></script>
19        <script type="text/javascript" src="${resource(dir: 'js', file: 'publication-chooser.pubmed.js')}"></script>
20        <script type="text/javascript" src="${resource(dir: 'js', file: 'SelectAddMore.js', plugin: 'gdt')}"></script>
21        <script type="text/javascript" src="${resource(dir: 'js', file: 'timepicker-0.2.1.js')}"></script>
22        <script type="text/javascript" src="${resource(dir: 'js', file: 'ajaxupload.3.6.js')}"></script>
23        <script type="text/javascript" src="${resource(dir: 'js', file: 'jquery.ui.autocomplete.html.js', plugin: 'gdt')}"></script>
24
25        <% /* fuzzy matching */ %>
26        <script type="text/javascript" src="${resource(dir: 'js', file: 'fuzzyStringMatch.js', plugin: 'gdt')}"></script>
27
28        <% /* Specific simplewizard stuff */ %>
29        <script type="text/javascript" src="${resource(dir: 'js', file: 'simpleWizard.js' )}"></script>
30        <link rel="stylesheet" href="${resource(dir: 'css', file: 'simplewizard.css')}" />
31</g:if>
32<g:else>
33        <link rel="stylesheet" href="<g:resource dir="css" file="buttons.min.css" />" type="text/css"/>
34        <link rel="stylesheet" href="${resource(dir: 'css', file: 'studywizard.min.css')}" />
35        <link rel="stylesheet" href="${resource(dir: 'css', file: 'templates.min.css')}" />
36        <script type="text/javascript" src="${resource(dir: 'js', file: 'studywizard.min.js' )}"></script>
37        <script type="text/javascript" src="${resource(dir: 'js', file: 'tooltips.min.js', plugin: 'gdt')}"></script>
38        <link rel="stylesheet" href="${resource(dir: 'css', file: 'table-editor.min.css', plugin: 'gdt')}" />
39        <script type="text/javascript" src="${resource(dir: 'js', file: 'table-editor.min.js', plugin: 'gdt')}"></script>
40        <script type="text/javascript" src="${resource(dir: 'js', file: 'jquery.qtip-1.0.0-rc3.min.js', plugin: 'gdt')}"></script>
41        <script type="text/javascript" src="${resource(dir: 'js', file: 'ontology-chooser.min.js', plugin: 'gdt')}"></script>
42        <script type="text/javascript" src="${resource(dir: 'js', file: 'publication-chooser.min.js')}"></script>
43        <script type="text/javascript" src="${resource(dir: 'js', file: 'publication-chooser.pubmed.min.js')}"></script>
44        <script type="text/javascript" src="${resource(dir: 'js', file: 'SelectAddMore.min.js', plugin: 'gdt')}"></script>
45        <script type="text/javascript" src="${resource(dir: 'js', file: 'timepicker-0.2.1.min.js')}"></script>
46        <script type="text/javascript" src="${resource(dir: 'js', file: 'ajaxupload.3.6.min.js')}"></script>
47        <script type="text/javascript" src="${resource(dir: 'js', file: 'jquery.ui.autocomplete.html.min.js', plugin: 'gdt')}"></script>
48        <script type="text/javascript" src="${resource(dir: 'js', file: 'fuzzyStringMatch.min.js', plugin: 'gdt')}"></script>
49        <script type="text/javascript" src="${resource(dir: 'js', file: 'simpleWizard.min.js' )}"></script>
50        <link rel="stylesheet" href="${resource(dir: 'css', file: 'simplewizard.min.css')}" />
51</g:else>
52
53<g:if test="${flash.validationErrors}">
54        <script type="text/javascript">
55                $(function() {
56                        // mark error fields
57                        <g:each in="${flash.validationErrors}" var="error">
58                                var element = $("input:[name='${error.key}'], input:[name='${error.key.toLowerCase().replaceAll("([^a-z0-9])","_")}'], select:[name='${error.key}'], select:[name='${error.key.toLowerCase().replaceAll("([^a-z0-9])","_")}'], textarea:[name='${error.key}'], textarea:[name='${error.key.toLowerCase().replaceAll("([^a-z0-9])","_")}']");
59                                element.parent().parent().removeClass('required');
60                                element.parent().parent().addClass('error');
61                        </g:each>
62                });
63        </script>
64</g:if>
Note: See TracBrowser for help on using the repository browser.