Revision 32038
Added by Nikon Gasparis over 9 years ago
modules/uoa-madgik-validator/tags/1.0.0/src/main/webapp/jsps/compatibilityTest.jsp | ||
---|---|---|
1 |
<%@ page contentType="text/html; charset=UTF-8" pageEncoding="UTF-8"%> |
|
2 |
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd"> |
|
3 |
<%@ taglib prefix="s" uri="/struts-tags"%> |
|
4 |
|
|
5 |
<html> |
|
6 |
<head> |
|
7 |
<script language="JavaScript"> |
|
8 |
function disableEnterKey(e) |
|
9 |
{ |
|
10 |
var key; |
|
11 |
if(window.event) |
|
12 |
key = window.event.keyCode; //IE |
|
13 |
else |
|
14 |
key = e.which; //firefox |
|
15 |
return (key != 13); |
|
16 |
} |
|
17 |
</script> |
|
18 |
<script language="javascript" src="jsps/js/mootools-1.2.5-core-nc.js" ></script> |
|
19 |
<script language="javascript" src="jsps/js/mootools-1.2.5.1-more.js" ></script> |
|
20 |
<script language="javascript" src="jsps/js/populateRules.js"></script> |
|
21 |
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"> |
|
22 |
<title>Test repository/journal</title> |
|
23 |
<link href="jsps/favicon.ico" rel="shortcut icon" type="image/x-icon" /> |
|
24 |
<link href="jsps/style.css" rel="stylesheet" type="text/css" media="screen" /> |
|
25 |
</head> |
|
26 |
|
|
27 |
<body class="left"> |
|
28 |
<div class="wrapper"> |
|
29 |
<jsp:include page="menu.jsp"/> |
|
30 |
<div id="page"> |
|
31 |
<div id="page-bgtop"> |
|
32 |
<s:actionmessage/> |
|
33 |
<div id="middle"> |
|
34 |
<div class="middle-b"> |
|
35 |
<div class="background"> |
|
36 |
<div id="left"> |
|
37 |
<div id="left_container" > |
|
38 |
<h2 class="helpHdr">Info</h2> |
|
39 |
<s:text name="help.newvalidation"/> |
|
40 |
</div> |
|
41 |
</div> |
|
42 |
<div id="main"> |
|
43 |
<div id="main_container" class="clearfix"> |
|
44 |
<div id="mainmiddle" class="floatbox"> |
|
45 |
<h1><s:text name="addOaiUsage.title"/></h1> |
|
46 |
<div class="entry"> |
|
47 |
<s:form id="populateRules" theme="simple" action="validateRules" method="get"> |
|
48 |
|
|
49 |
<div class="firstpar" id="firstpar"> |
|
50 |
<div class="section">Select repository/journal</div> |
|
51 |
<div class="field"> |
|
52 |
<div id="urlError" style="color:red;"></div> |
|
53 |
<s:radio name="selection" list="#{'select':getText('addOaiContent.baseUrl')}" id="selectButton" cssClass="radioselect"/> |
|
54 |
<br> |
|
55 |
<s:select id="baseUrl" name="baseUrl" list="repositories" title="%{getText(\'addOaiContent.tooltip.baseUrl\')}" cssClass="baseurl" |
|
56 |
headerKey="" headerValue="Please choose existing Base URL..."/> |
|
57 |
</div> |
|
58 |
|
|
59 |
<div class="field"> |
|
60 |
<s:radio name="selection" list="#{'text':getText('addOaiContent.baseUrl2')}" id="textButton" cssClass="radioselect"/> |
|
61 |
<br/> |
|
62 |
<s:textfield name="baseUrl2" onKeyPress="return disableEnterKey(event)" id="baseUrl2" size="70" title="%{getText(\'addOaiContent.tooltip.baseUrl\')+\"(*)\"}"/> |
|
63 |
</div> |
|
64 |
|
|
65 |
<div class="clearfix"> |
|
66 |
<div class="next"> <a href="#" onClick="javascript:validateUrl();">Next</a></div> |
|
67 |
</div> |
|
68 |
</div> |
|
69 |
|
|
70 |
<div class="firstpar" id="firstpar-select" style="display:none;"> |
|
71 |
<div class="selectedHdr"> |
|
72 |
Selected repository: <span id="repoUrl"></span> |
|
73 |
</div> |
|
74 |
</div> |
|
75 |
|
|
76 |
<div class="secondpar" style="display:none;" id="secondpar"> |
|
77 |
<div class="section">Select guidelines</div> |
|
78 |
<%-- <s:radio list="ruleSetMap" name="chosenSet" theme="simple" cssClass="ruleset"/> <br> --%> |
|
79 |
<s:iterator value="ruleSetMap"> |
|
80 |
<span class="fieldName"><s:radio theme="simple" name="chosenSet" list="#{key:value}" cssClass="ruleset"/> |
|
81 |
</span> |
|
82 |
<s:url action="fetchRuleDescriptions" id="link"> |
|
83 |
<s:param name="ruleSetId" value="%{key}"/> |
|
84 |
</s:url> |
|
85 |
<s:a href="%{#link}" target="blank">More info</s:a> |
|
86 |
<br> |
|
87 |
</s:iterator> |
|
88 |
<!-- <div class="info"> --> |
|
89 |
<!-- Get more information on the predefined rule sets: <br/> --> |
|
90 |
<%-- <s:iterator value="ruleSetMap" var="key"> --%> |
|
91 |
<%-- <s:url action="fetchRuleDescriptions" id="link"> --%> |
|
92 |
<%-- <s:param name="ruleSetId" value="%{key}"/> --%> |
|
93 |
<%-- </s:url> --%> |
|
94 |
<%-- <s:a href="%{#link}" target="blank"><s:property value="%{value}"/></s:a> --%> |
|
95 |
<!-- | --> |
|
96 |
<%-- </s:iterator> --%> |
|
97 |
<!-- </div> --> |
|
98 |
|
|
99 |
<div class="note"> |
|
100 |
|
|
101 |
|
|
102 |
<span class="fieldName">View/Select Rules</span> |
|
103 |
|
|
104 |
|
|
105 |
<div class="field"> |
|
106 |
<input type="checkbox" id="contentRules" class="validation"/> |
|
107 |
<span class="fieldName">for Content</span> <a href="#" class="showlink" id="contentlink">Show</a> |
|
108 |
</div> |
|
109 |
<div class="nest" id="nest-contentlink"> |
|
110 |
<div class="optiontable_container"> |
|
111 |
<b class="optiontable_top"> |
|
112 |
<b class="optiontable_t1"></b> |
|
113 |
<b class="optiontable_t2"></b> |
|
114 |
<b class="optiontable_t3"></b> |
|
115 |
<b class="optiontable_t4"></b> |
|
116 |
</b> |
|
117 |
<div id="contentR" style="overflow: visible;"> </div> |
|
118 |
<b class="optiontable_bottom"> |
|
119 |
<b class="optiontable_b4"></b> |
|
120 |
<b class="optiontable_b3"></b> |
|
121 |
<b class="optiontable_b2"></b> |
|
122 |
<b class="optiontable_b1"></b> |
|
123 |
</b> |
|
124 |
</div> |
|
125 |
</div> |
|
126 |
<div class="field"> |
|
127 |
<input type="checkbox" id="usageRules" class="validation"/> |
|
128 |
<span class="fieldName">for Usage</span> <a href="#" class="showlink" id="usagelink">Show</a> |
|
129 |
</div> |
|
130 |
<div class="nest" id="nest-usagelink"> |
|
131 |
<div class="optiontable_container"> |
|
132 |
<b class="optiontable_top"> |
|
133 |
<b class="optiontable_t1"></b> |
|
134 |
<b class="optiontable_t2"></b> |
|
135 |
<b class="optiontable_t3"></b> |
|
136 |
<b class="optiontable_t4"></b> |
|
137 |
</b> |
|
138 |
<div id="usage"></div> |
|
139 |
<b class="optiontable_bottom"> |
|
140 |
<b class="optiontable_b4"></b> |
|
141 |
<b class="optiontable_b3"></b> |
|
142 |
<b class="optiontable_b2"></b> |
|
143 |
<b class="optiontable_b1"></b> |
|
144 |
</b> |
|
145 |
</div> |
|
146 |
</div> |
|
147 |
</div> |
|
148 |
</div> |
|
149 |
<div class="thirdpar" style="display:none" id="thirdpar"> |
|
150 |
<div class="section">Select parameters</div> |
|
151 |
<div id="contentParameters"> |
|
152 |
<div class="field"> |
|
153 |
<span class="fieldName">Number of records</span> |
|
154 |
<%-- <s:textfield name="records" id="records" value="10" cssClass="smallInp"/> --%> |
|
155 |
<s:radio name="selectionRecords" id="selectionRecords" list="#{'all':'All','custom':'Custom'}" cssClass="radioselectRecords"/> |
|
156 |
<s:textfield name="records" id="records" value="10" cssClass="smallInp"/> |
|
157 |
</div> |
|
158 |
|
|
159 |
<div class="field"> |
|
160 |
<span class="fieldName">Set </span> |
|
161 |
<span id="log_res"><!-- spanner --></span> |
|
162 |
<span id="reposets"> |
|
163 |
<s:select name="set" list="{'All Sets', 'Choose another set...'}" id="set"/> |
|
164 |
</span> |
|
165 |
</div> |
|
166 |
|
|
167 |
<div class="note"> |
|
168 |
<div class="field"> |
|
169 |
<span class="fieldName">Would you like to group your results by a specific record's field?</span> |
|
170 |
<br> |
|
171 |
<s:radio name="selectionGroupBy" id="selectionGroupBy" list="#{'no':'No','yes':'Yes'}" cssClass="radioselectGroupBy"/> |
|
172 |
<s:textfield name="groupBy" id="groupBy" value="-XPATH-" cssClass="bigInp"/> <br> |
|
173 |
<b><i>XPath Examples:</i></b> 1. //header/setSpec 2. //record/metadata//*[name()='dc:language'] |
|
174 |
|
|
175 |
|
|
176 |
</div> |
|
177 |
</div> |
|
178 |
|
|
179 |
</div> |
|
180 |
|
|
181 |
</div> |
|
182 |
<div class="fourthpar" style="display:none;" id="fourthpar"> |
|
183 |
|
|
184 |
|
|
185 |
<div class="clearfix"> |
|
186 |
<div class="prev"> <a href="#" onClick="javascript:changeDisplays();"> Previous</a></div> |
|
187 |
</div> |
|
188 |
<div class="info"> |
|
189 |
You will be notified by email with the results of the compatibility test. |
|
190 |
</div> |
|
191 |
|
|
192 |
<div class="clearfix"> |
|
193 |
<span style="float:right"><s:submit value="Start validation" cssClass="button-default" /></span> |
|
194 |
</div> |
|
195 |
|
|
196 |
<p> </p> |
|
197 |
|
|
198 |
|
|
199 |
</div> |
|
200 |
|
|
201 |
</s:form> |
|
202 |
|
|
203 |
</div> |
|
204 |
</div> |
|
205 |
</div> |
|
206 |
</div> |
|
207 |
</div> |
|
208 |
</div> |
|
209 |
</div> |
|
210 |
|
|
211 |
</div> |
|
212 |
<!-- NMI This needs to be the same in all pages and the text is some properties file --> |
|
213 |
<div id="footer"> |
|
214 |
<jsp:include page="footer.jsp"/> |
|
215 |
</div> |
|
216 |
</div> |
|
217 |
</div> |
|
218 |
</body> |
|
219 |
</html> |
modules/uoa-madgik-validator/tags/1.0.0/src/main/webapp/jsps/registerRepository.jsp | ||
---|---|---|
1 |
<%@ page contentType="text/html; charset=UTF-8" pageEncoding="UTF-8"%> |
|
2 |
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd"> |
|
3 |
<%@ taglib prefix="s" uri="/struts-tags"%> |
|
4 |
<html> |
|
5 |
<head> |
|
6 |
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"> |
|
7 |
<title><s:text name="registerRepo.dnet.title"/></title> |
|
8 |
<link href="jsps/favicon.ico" rel="shortcut icon" type="image/x-icon" /> |
|
9 |
<link href="jsps/style.css" rel="stylesheet" type="text/css" media="screen" /> |
|
10 |
<link rel="stylesheet" href="//code.jquery.com/ui/1.11.1/themes/smoothness/jquery-ui.css"> |
|
11 |
</head> |
|
12 |
<body class="left"> |
|
13 |
|
|
14 |
<script src="//code.jquery.com/jquery-1.10.2.js"></script> |
|
15 |
<script src="//code.jquery.com/ui/1.11.1/jquery-ui.js"></script> |
|
16 |
<script type="text/javascript" src="jsps/js/repoInterfaces.js"></script> |
|
17 |
|
|
18 |
<div id="wrapper"> |
|
19 |
<jsp:include page="menu.jsp"/> |
|
20 |
<div id="page"> |
|
21 |
<div id="page-bgtop"> |
|
22 |
<div id="middle"> |
|
23 |
<div class="middle-b"> |
|
24 |
<div class="background"> |
|
25 |
<div id="left"> |
|
26 |
<div id="left_container" > |
|
27 |
<h2 class="helpHdr">Info</h2> |
|
28 |
<s:text name="help.registerRepo"/> |
|
29 |
</div> |
|
30 |
</div> |
|
31 |
<div id="main"> |
|
32 |
<div id="main_container" class="clearfix"> |
|
33 |
<div id="mainmiddle" class="floatbox"> |
|
34 |
<h1><s:text name="registerRepo.dnet.title"/></h1> |
|
35 |
<div class="info"> |
|
36 |
<s:text name="registerRepoDnet.descriptionGen"/> |
|
37 |
</div> |
|
38 |
<s:actionerror/> |
|
39 |
<div class="entry"> |
|
40 |
<s:form cssClass="zebra1" action="registerRepo"> |
|
41 |
<s:hidden name="mode" value="%{mode}"/> |
|
42 |
<s:hidden name="usingOpenDoar" value="%{readonlyFields}"/> |
|
43 |
<s:hidden name="readonlyFields" value="%{readonlyFields}"/> |
|
44 |
<s:hidden name="id" value="%{id}"/> |
|
45 |
<s:hidden name="officialName" value="%{officialName}"/> |
|
46 |
<tr><td colspan="2" class="section"><s:text name="registerRepoDnet.title0"/></td></tr> |
|
47 |
<s:if test="%{mode=='opendoar'}"> |
|
48 |
<tr><td colspan="2"> <div class="alert"><s:text name="registerRepoDnet.descriptionGen0"/><a href="<s:url value="%{idDoar}"/> " target="_blank">OpenDOAR link</a></div></td></tr> |
|
49 |
</s:if> |
|
50 |
<s:if test="%{mode=='re3data'}"> |
|
51 |
<tr><td colspan="2"> <div class="alert"><s:text name="registerRepoDnet.descriptionGen0_data"/><a href="<s:url value="%{idDoar}"/> " target="_blank">Re3data link</a></div></td></tr> |
|
52 |
</s:if> |
|
53 |
<s:if test="%{mode=='opendoar'}"> |
|
54 |
<%-- <tr><th><s:text name="registerRepoDnet.typology"/></th><td><s:property value="repo.typology"/></td></tr> --%> |
|
55 |
<tr><th><s:text name="registerRepoDnet.typology"/></th><td><s:textfield theme="simple" name="repo.typology" value="%{repo.typology}" title="%{getText(\'repoRegistration.tooltip.typology\')}" label="%{getText(\"registerRepoDnet.typology\")}" required="true" readonly="%{readonlyFields}" /></td></tr> |
|
56 |
</s:if> |
|
57 |
<s:else> |
|
58 |
<tr><th><s:text name="registerRepoDnet.typology"/></th><td><s:select theme="simple" name="repo.typology" list="typologies" title="%{getText(\'repoRegistration.tooltip.typology\')}" label="%{getText(\"registerRepoDnet.typology\")}" required="true" readonly="%{readonlyFields}"/></td></tr> |
|
59 |
<tr><td colspan="2"><s:fielderror fieldName="customTypology"/></td></tr> |
|
60 |
<tr><th><s:text name="registerRepo.dnet.customTypology"/></th><td><s:textfield theme = "simple" name="customTypology" title="%{getText(\'repoRegistration.tooltip.typology\')}" label="%{getText(\"registerRepo.dnet.customTypology\")}" size="65" readonly="%{readonlyFields}"/></td></tr> |
|
61 |
</s:else> |
|
62 |
<tr><td colspan="2"><s:fielderror fieldName="officialName"/></td></tr> |
|
63 |
<tr><th><s:text name="registerRepoDnet.officialName"/></th><td><s:textfield theme="simple" name="repo.officialName" size="65" title="%{getText(\'repoRegistration.tooltip.officialName\')}" label="%{getText(\"registerRepoDnet.officialName\")}" required="true" readonly="%{repoMode.trim().toLowerCase().equals(\"dnet\") && readonlyFields}"/></td></tr> |
|
64 |
|
|
65 |
<s:if test="%{mode=='journal'}"> |
|
66 |
<tr><td colspan="2"><s:fielderror fieldName="issn"/></td></tr> |
|
67 |
<tr><th><s:text name="registerRepoDnet.issn"/></th><td><s:textfield theme="simple" name="repo.issn" size="65" title="%{getText(\'repoRegistration.tooltip.issn\')}" label="%{getText(\"registerRepoDnet.issn\")}" required="true"/></td></tr> |
|
68 |
<tr><td colspan="2"><s:fielderror fieldName="eissn"/></td></tr> |
|
69 |
<tr><th><s:text name="registerRepoDnet.eissn"/></th><td><s:textfield theme="simple" name="repo.eissn" size="65" title="%{getText(\'repoRegistration.tooltip.eissn\')}" label="%{getText(\"registerRepoDnet.eissn\")}"/></td></tr> |
|
70 |
<tr><td colspan="2"><s:fielderror fieldName="lssn"/></td></tr> |
|
71 |
<tr><th><s:text name="registerRepoDnet.lissn"/></th><td><s:textfield theme="simple" name="repo.lissn" size="65" title="%{getText(\'repoRegistration.tooltip.lissn\')}" label="%{getText(\"registerRepoDnet.lissn\")}"/></td></tr> |
|
72 |
</s:if> |
|
73 |
<%-- <s:if test="%{readonlyFields}"> --%> |
|
74 |
<tr><th width="150px"><s:text name="registerRepoDnet.description"/></th><td><s:textarea theme="simple" name="repo.description" title="%{getText(\'repoRegistration.tooltip.description\')}" label="%{getText(\"registerRepoDnet.description\")}" cols="50" rows="10" readonly="%{readonlyFields}"/></td></tr> |
|
75 |
<%-- </s:if> --%> |
|
76 |
<%-- <s:textfield name="iconUrl" size="65" title="%{getText(\'repoRegistration.tooltip.iconUrl\')}" label="%{getText(\"registerRepoDnet.iconUrl\")}" required="true" readonly="%{readonlyFields}" /> --%> |
|
77 |
<s:if test="%{readonlyFields}"> |
|
78 |
<tr><td colspan="2"><s:fielderror fieldName="countryName"/></td></tr> |
|
79 |
<tr><th><s:text name="registerRepoDnet.country"/></th><td><s:textfield theme="simple" name="repo.countryName" value="%{repo.countryName}" title="%{getText(\'repoRegistration.tooltip.country\')}" label="%{getText(\"registerRepoDnet.country\")}" required="true" readonly="%{readonlyFields}"/></td></tr> |
|
80 |
</s:if> |
|
81 |
<s:else> |
|
82 |
<tr><td colspan="2"><s:fielderror fieldName="countryName"/></td></tr> |
|
83 |
<tr><th><s:text name="registerRepoDnet.country"/></th><td><s:select theme="simple" name="repo.countryName" list="countries" value="%{repo.countryName}" title="%{getText(\'repoRegistration.tooltip.country\')}" label="%{getText(\"registerRepoDnet.country\")}" required="true"/></td></tr> |
|
84 |
</s:else> |
|
85 |
<tr><td colspan="2"><s:fielderror fieldName="longitude"/></td></tr> |
|
86 |
<tr><th><s:text name="registerRepoDnet.longtitude"/></th><td><s:textfield theme="simple" name="repo.longitude" size="10" title="%{getText(\'repoRegistration.tooltip.longtitude\')}" label="%{getText(\"registerRepoDnet.longtitude\")}" required="true" readonly="%{readonlyFields}"/></td></tr> |
|
87 |
<tr><td colspan="2"><s:fielderror fieldName="latitude"/></td></tr> |
|
88 |
<tr><th><s:text name="registerRepoDnet.latitude"/></th><td><s:textfield theme="simple" name="repo.latitude" size="10" title="%{getText(\'repoRegistration.tooltip.latitude\')}" label="%{getText(\"registerRepoDnet.latitude\")}" required="true" readonly="%{readonlyFields}"/></td></tr> |
|
89 |
<%-- <s:if test="%{readonlyFields}"> --%> |
|
90 |
<%-- <s:textfield name="timezone" list="timezones" listKey="offset" listValue="name" title="%{getText(\'repoRegistration.tooltip.timezone\')}" label="%{getText(\"registerRepoDnet.timezone\")}" required="true" readonly="%{readonlyFields}" /> --%> |
|
91 |
<%-- </s:if> --%> |
|
92 |
<%-- <s:else> --%> |
|
93 |
<%-- <s:select name="timezone" list="timezones" listKey="offset" listValue="name" title="%{getText(\'repoRegistration.tooltip.timezone\')}" label="%{getText(\"registerRepoDnet.timezone\")}" required="true"/> --%> |
|
94 |
<%-- </s:else> --%> |
|
95 |
<tr><td colspan="2"><s:fielderror fieldName="websiteUrl"/></td></tr> |
|
96 |
<tr><th><s:text name="registerRepoDnet.entryUrl"/></th><td><s:textfield theme="simple" name="repo.websiteUrl" size="65" title="%{getText(\'repoRegistration.tooltip.entryUrl\')}" label="%{getText(\"registerRepoDnet.entryUrl\")}" required="true" readonly="%{readonlyFields}" /></td></tr> |
|
97 |
<tr><td colspan="2"><s:fielderror fieldName="organization"/></td></tr> |
|
98 |
<tr><th><s:text name="registerRepoDnet.repoInst"/></th><td><s:textfield theme="simple" name="repo.organization" size="65" title="%{getText(\'repoRegistration.tooltip.repoInst\')}" label="%{getText(\"registerRepoDnet.repoInst\")}" required="true" readonly="%{readonlyFields}" /></td></tr> |
|
99 |
<tr><td colspan="2" class="section"><s:text name="registerRepoDnet.title0b"/></td></tr> |
|
100 |
<tr><td colspan="2"><s:fielderror fieldName="englishName"/></td></tr> |
|
101 |
<tr><th><s:text name="registerRepoDnet.englishName"/></th><td><s:textfield theme="simple" name="repo.englishName" size="65" title="%{getText(\'repoRegistration.tooltip.englishName\')}" label="%{getText(\"registerRepoDnet.englishName\")}" required="true"/></td></tr> |
|
102 |
<tr><th><s:text name="registerRepoDnet.iconUrl"/></th><td><s:textfield theme="simple" name="repo.logoUrl" size="65" title="%{getText(\'repoRegistration.tooltip.iconUrl\')}" label="%{getText(\"registerRepoDnet.iconUrl\")}"/></td></tr> |
|
103 |
<tr><td> </td><td class="comments smallfont">Please make sure that the maximum size of the uploaded image is width=360px, height=240px</td></tr> |
|
104 |
<tr><th><s:text name="registerRepoDnet.timezone"/></th><td><s:select theme="simple" name="repo.timezone" list="timezones" listKey="offset" listValue="name" title="%{getText(\'repoRegistration.tooltip.timezone\')}" label="%{getText(\"registerRepoDnet.timezone\")}" required="true"/></td></tr> |
|
105 |
<tr><td colspan="2" class="section"><s:text name="registerRepoDnet.title1"/></td></tr> |
|
106 |
<tr><td colspan="2"><s:fielderror fieldName="contactEmail"/></td></tr> |
|
107 |
<tr><th><s:text name="registerRepoDnet.adminEmail"/></th><td><s:textfield theme="simple" name="repo.contactEmail" size="65" title="%{getText(\'repoRegistration.tooltip.adminEmail\')}" label="%{getText(\"registerRepoDnet.adminEmail\")}" /></td></tr> |
|
108 |
<tr> <td colspan="2" class="section"><s:text name="registerRepoDnet.title2"/></td></tr> |
|
109 |
|
|
110 |
<tr><td colspan="2"> |
|
111 |
<div class="info"> |
|
112 |
<s:text name="registerRepoDnet.descriptionEmptySet"/> |
|
113 |
</div> |
|
114 |
</td> |
|
115 |
</tr> |
|
116 |
<s:if test="hasFieldErrors()"> |
|
117 |
<tr><td colspan="2"><s:fielderror fieldName="baseUrl"/></td></tr> |
|
118 |
<tr><td colspan="2"><s:fielderror fieldName="validationSet"/></td></tr> |
|
119 |
</s:if> |
|
120 |
<table id="myTable" class="zebra1" style="table-layout:fixed; width:100%"> |
|
121 |
<tbody> |
|
122 |
<s:iterator value="interfaces" var="opendoarrepositoryinterface" status="stat"> |
|
123 |
<tr><th width=30% scope="col" class="numb"></th><th width=65% class="numb"></th><th class="numb" width=5%></th></tr> |
|
124 |
|
|
125 |
<%-- <tr><th width=30% scope="col" class="numb">Interface Number</th><td width=65% class="numb"><s:text name="%{#stat.count}"/></td><td width=5%></td></tr> --%> |
|
126 |
<s:if test="%{dbMode.trim().toLowerCase().equals(\"dms\")}"> |
|
127 |
<tr><th width=30% scope="col"><s:text name="registerRepoDnet.baseUrl"/></th><td><s:textfield theme="simple" size="40" name="interfaces[%{#stat.count-1}].baseUrl" value="%{#opendoarrepositoryinterface.baseUrl}" title="%{getText(\'repoRegistration.tooltip.baseUrl\')}" required="true" /></td><td rowspan="4"></td></tr> |
|
128 |
<tr><th scope="col"><s:text name="registerRepoDnet.validationSet"/></th><td><s:textfield theme="simple" size="40" name="interfaces[%{#stat.count-1}].accessSet" value="%{#opendoarrepositoryinterface.accessSet}" title="%{getText(\'repoRegistration.tooltip.accessSet\')}"/></td><td></td></tr> |
|
129 |
<tr><th scope="col"><s:text name="registerRepoDnet.compliance"/></th><td><s:text name="interfaces[%{#stat.count-1}].complianceName" /></td><td></td></tr> |
|
130 |
<%-- <tr><th scope="col"><s:text name="registerRepoDnet.compliance"/></th><td><s:textfield theme="simple" size="40" name="interfaces[%{#stat.count-1}].compliance" value="%{#opendoarrepositoryinterface.compliance}" title="%{getText(\'repoRegistration.tooltip.compliance\')}" readonly="true"/></td><td></td></tr> --%> |
|
131 |
</s:if> |
|
132 |
<s:else> |
|
133 |
<tr><th scope="col"><s:text name="registerRepoDnet.baseUrl"/></th><td><s:textfield theme="simple" size="40" name="interfaces[%{#stat.count-1}].baseUrl" value="%{#opendoarrepositoryinterface.baseUrl}" title="%{getText(\'repoRegistration.tooltip.baseUrl\')}" required="true"/></td><td></td></tr> |
|
134 |
<tr><th scope="col"><s:text name="registerRepoDnet.validationSet"/></th><td><s:textfield theme="simple" size="40" name="interfaces[%{#stat.count-1}].accessSet" value="%{#opendoarrepositoryinterface.accessSet}" title="%{getText(\'repoRegistration.tooltip.accessSet\')}"/></td><td></td></tr> |
|
135 |
</s:else> |
|
136 |
<tr><th scope="col"><s:text name="registerRepoDnet.compatibilityLevel"/></th> |
|
137 |
<td> |
|
138 |
<s:if test="%{mode=='re3data'}"> |
|
139 |
<s:select theme="simple" name="interfaces[%{#stat.count-1}].desiredCompatibilityLevel" |
|
140 |
value="%{#opendoarrepositoryinterface.desiredCompatibilityLevel}" |
|
141 |
list="#{'openaire2.0_data':'OpenAIRE 2.0 (EC funding)'}" |
|
142 |
required="true" |
|
143 |
/> |
|
144 |
</s:if> |
|
145 |
<s:else> |
|
146 |
<s:select theme="simple" name="interfaces[%{#stat.count-1}].desiredCompatibilityLevel" |
|
147 |
value="%{#opendoarrepositoryinterface.desiredCompatibilityLevel}" |
|
148 |
list="#{'openaire3.0':'OpenAIRE 3.0 (OA, funding)', 'openaire2.0':'OpenAIRE 2.0 (EC funding)', 'driver':'OpenAIRE Basic (DRIVER OA)'}" |
|
149 |
required="true" |
|
150 |
/> |
|
151 |
</s:else> |
|
152 |
</td><td></td> |
|
153 |
</tr> |
|
154 |
|
|
155 |
<s:hidden name="interfaces[%{#stat.count-1}].accessFormat" value="%{#opendoarrepositoryinterface.accessFormat}"/> |
|
156 |
<s:hidden name="interfaces[%{#stat.count-1}].typology" value="%{#opendoarrepositoryinterface.typology}"/> |
|
157 |
<s:hidden name="interfaces[%{#stat.count-1}].accessProtocol" value="%{#opendoarrepositoryinterface.accessProtocol}"/> |
|
158 |
<s:hidden name="interfaces[%{#stat.count-1}].compliance" value="%{#opendoarrepositoryinterface.compliance}"/> |
|
159 |
<s:hidden name="interfaces[%{#stat.count-1}].id" value="%{#opendoarrepositoryinterface.id}"/> |
|
160 |
<s:hidden name="interfaces[%{#stat.count-1}].removable" value="%{#opendoarrepositoryinterface.removable}"/> |
|
161 |
</s:iterator> |
|
162 |
</tbody> |
|
163 |
</table> |
|
164 |
<table class="zebra" style="table-layout:fixed; width:100%"> |
|
165 |
<s:if test="%{mode=='re3data'}"> |
|
166 |
<s:if test="%{dbMode.trim().toLowerCase().equals(\"dms\")}"> |
|
167 |
<tr><td colspan="1"><a id="cloneButton1" onclick="addNew_data('reg')">[+] Add new Interface</a></td> |
|
168 |
<td colspan="3"><a id="cloneButton1" onclick="removeLast('<s:property value="%{interfaces.size()}"/>')">[-] Remove last added</a></td></tr> |
|
169 |
</s:if> |
|
170 |
<s:else> |
|
171 |
<tr><td colspan="1"><a id="cloneButton1" onclick="addNewDirect_data()">[+] Add new Interface</a></td> |
|
172 |
<td colspan="3"><a id="cloneButton1" onclick="removeLastDirect()">[-] Remove last added</a></td></tr> |
|
173 |
</s:else> |
|
174 |
</s:if> |
|
175 |
<s:else> |
|
176 |
<s:if test="%{dbMode.trim().toLowerCase().equals(\"dms\")}"> |
|
177 |
<tr><td colspan="1"><a id="cloneButton1" onclick="addNew('reg')">[+] Add new Interface</a></td> |
|
178 |
<td colspan="3"><a id="cloneButton1" onclick="removeLast('<s:property value="%{interfaces.size()}"/>')">[-] Remove last added</a></td></tr> |
|
179 |
</s:if> |
|
180 |
<s:else> |
|
181 |
<tr><td colspan="1"><a id="cloneButton1" onclick="addNewDirect()">[+] Add new Interface</a></td> |
|
182 |
<td colspan="3"><a id="cloneButton1" onclick="removeLastDirect()">[-] Remove last added</a></td></tr> |
|
183 |
</s:else> |
|
184 |
</s:else> |
|
185 |
</table> |
|
186 |
<div id="dialog" title="Warning"> |
|
187 |
<p>There is no added interface to remove. If you want to remove an interface completely, you have to manage the repository via 'Manage Your Datasources' option located on main menu.</p> |
|
188 |
</div> |
|
189 |
|
|
190 |
<s:if test="%{dbMode.trim().toLowerCase().equals(\"direct\") && readonlyFields}"> |
|
191 |
<table><tr> <td colspan="2" class="section"><s:text name="registerRepoDnet.title3"/></td></tr></table> |
|
192 |
<table id="myTable1" class="zebra" style="table-layout:fixed; width:100%"> |
|
193 |
<thead> |
|
194 |
<tr> |
|
195 |
<th scope="col" style="width:40%">OpenAIRE Basic (ex DRIVER)</th> |
|
196 |
<th scope="col" style="width:30%">OpenAIRE 2.0</th> |
|
197 |
<th scope="col" style="width:30%">OpenAIRE 3.0</th> |
|
198 |
</tr> |
|
199 |
</thead> |
|
200 |
<tbody> |
|
201 |
<tr> |
|
202 |
<s:iterator value="openaireCompliant" var="compliant" status="stat"> |
|
203 |
<td><s:property value="%{#compliant}" /></td> |
|
204 |
</s:iterator> |
|
205 |
</tr> |
|
206 |
</tbody> |
|
207 |
</table> |
|
208 |
</s:if> |
|
209 |
<s:if test="%{dbMode.trim().toLowerCase().equals(\"dms\") && registrationFilesDownload}"> |
|
210 |
<table id="pdfTable" class="zebra1" style="table-layout:fixed; width:100%"> |
|
211 |
<tr> <td colspan="5" class="section"><s:text name="registerRepoDnet.title4"/></td></tr> |
|
212 |
<tr> <td colspan="4"><s:text name="registerRepoDnet.files.allow"/></td><td><s:checkbox id ="allowPdf" theme="simple" name="pubFileIface.allow"/> </td></tr> |
|
213 |
<tr> |
|
214 |
<td colspan="5" > |
|
215 |
<div class="note"> |
|
216 |
<s:text name="registerRepoDnet.files.allow1"/> |
|
217 |
</div> |
|
218 |
</td> |
|
219 |
</tr> |
|
220 |
<tr class="addSource"> |
|
221 |
<td colspan="5" > |
|
222 |
<div class="info"> |
|
223 |
<s:text name="registerRepoDnet.files.info"/> |
|
224 |
</div> |
|
225 |
</td> |
|
226 |
</tr> |
|
227 |
<tr class="addSource"><th><s:text name="registerRepoDnet.files.methodology"/></th><td colspan="3"><s:radio cssClass="myRadio" theme ="simple" name="pubFileIface.methodology" list="#{'files_from_metadata':'from HTTP addresses in the metadata records (dc:identifier)','files_from_api':'from standard APIs'}"/></td></tr> |
|
228 |
<tr class="harvest"><td> </td><td><s:text name="registerRepoDnet.files.protocol"/></td><td><s:select theme="simple" name="pubFileIface.protocol" value="%{#pubFileIface.protocol}" list="#{'ftp':'FTP'}"/></td><td colspan="2"></td></tr> |
|
229 |
<tr class="harvest"><td> </td><td><s:text name="registerRepoDnet.files.url"/></td><td colspan="2"><s:textfield theme="simple" size ="30" name="pubFileIface.url"/></td><td></td></tr> |
|
230 |
<tr class="harvest"><td> </td><td><s:text name="registerRepoDnet.files.username"/></td ><td colspan="2"><s:textfield theme="simple" size ="30" name="pubFileIface.username"/></td><td></td></tr> |
|
231 |
<tr class="harvest"><td> </td><td><s:text name="registerRepoDnet.files.password"/></td ><td colspan="2"><s:textfield theme="simple" size ="30" name="pubFileIface.password"/></td><td></td></tr> |
|
232 |
<tr class="harvest"><td> </td><td><s:text name="registerRepoDnet.files.namingConvention"/></td><td colspan="2"><s:radio theme="simple" name="pubFileIface.convention" list="#{'oai_pmh_identifier':'OAI-PMH Identifier','doi':'DOI'}"/></td><td></td></tr> |
|
233 |
<tr class="metadata"><td> </td><td><s:text name="registerRepoDnet.files.xpath"/></td ><td colspan="2"><s:textfield theme="simple" size ="30" name="pubFileIface.xpath"/></td><td></td></tr> |
|
234 |
|
|
235 |
</table> |
|
236 |
</s:if> |
|
237 |
<tr><td colspan="2"><hr class="dotted"></td></tr> |
|
238 |
<table id="progressTable" style="table-layout:fixed; width:100%"> |
|
239 |
<tr class="progress"><td> |
|
240 |
<div class="info">Checking if interface's Url and Validation Set are valid... |
|
241 |
</div></td></tr> |
|
242 |
</table> |
|
243 |
<s:submit id="subm" value="Register" cssClass="button-default"/> |
|
244 |
<s:submit id="submWait" value="Please Wait" disabled="true" cssClass="button-default"/> |
|
245 |
</s:form> |
|
246 |
|
|
247 |
</div> |
|
248 |
</div> |
|
249 |
</div> |
|
250 |
</div> |
|
251 |
</div> |
|
252 |
</div> |
|
253 |
</div> |
|
254 |
<div style="clear: both;"> </div> |
|
255 |
</div> |
|
256 |
<!-- NMI This needs to be the same in all pages and the text is some properties file --> |
|
257 |
<div id="footer"> |
|
258 |
<jsp:include page="footer.jsp"/> |
|
259 |
</div> |
|
260 |
</div> |
|
261 |
</div> |
|
262 |
</body> |
|
263 |
</html> |
modules/uoa-madgik-validator/tags/1.0.0/src/main/webapp/jsps/js/repoInterfaces.js | ||
---|---|---|
1 |
$(document).ready(function(){ |
|
2 |
|
|
3 |
|
|
4 |
// jQuery(document).ready(function() { |
|
5 |
|
|
6 |
// }); |
|
7 |
|
|
8 |
$('#dialog').hide(); |
|
9 |
$('#dialog1').hide(); |
|
10 |
|
|
11 |
var checked1; |
|
12 |
var checked2; |
|
13 |
$('#submWait').hide(); |
|
14 |
$('.progress').hide(); |
|
15 |
if($('#allowPdf').is(':checked')) { |
|
16 |
$('.addSource').show(); |
|
17 |
checked1 = ($('#registerRepo_pubFileIface_methodologyfiles_from_api').is(':checked') || $('#editRepo_pubFileIface_methodologyfiles_from_api').is(':checked')); |
|
18 |
checked2 = ($('#registerRepo_pubFileIface_methodologyfiles_from_metadata').is(':checked') || $('#editRepo_pubFileIface_methodologyfiles_from_metadata').is(':checked')); |
|
19 |
if(checked1) { |
|
20 |
$('.harvest').show(); |
|
21 |
$('.metadata').hide(); |
|
22 |
} |
|
23 |
else if(checked2) { |
|
24 |
$('.metadata').show(); |
|
25 |
$('.harvest').hide(); |
|
26 |
} |
|
27 |
} else { |
|
28 |
$('.addSource').hide(); |
|
29 |
$('.harvest').hide(); |
|
30 |
$('.metadata').hide(); |
|
31 |
} |
|
32 |
$('#allowPdf').change(function(){ |
|
33 |
var checked = $(this).is(":checked"); |
|
34 |
if(!checked) { |
|
35 |
$('.addSource').hide(); |
|
36 |
$('.harvest').hide(); |
|
37 |
} else { |
|
38 |
$('.addSource').show(); |
|
39 |
if(checked1) { |
|
40 |
$('.harvest').show(); |
|
41 |
} |
|
42 |
if(checked2) { |
|
43 |
$('.metadata').show(); |
|
44 |
} |
|
45 |
} |
|
46 |
}); |
|
47 |
|
|
48 |
|
|
49 |
// $('#subm').click(function() { |
|
50 |
// $('.progress').show(); |
|
51 |
// $(this).hide(); |
|
52 |
// $('#submWait').show(); |
|
53 |
//// $(this).attr("disabled","disabled"); |
|
54 |
// }); |
|
55 |
|
|
56 |
$('.myRadio').click(function() { |
|
57 |
if($(this).val() == 'files_from_api') { |
|
58 |
$('.harvest').show(); |
|
59 |
$('.metadata').hide(); |
|
60 |
} |
|
61 |
else if($(this).val() == 'files_from_metadata') { |
|
62 |
$('.harvest').hide(); |
|
63 |
$('.metadata').show(); |
|
64 |
} |
|
65 |
}); |
|
66 |
|
|
67 |
jQuery('.tabs .tab-links a').on('click', function(e) { |
|
68 |
var currentAttrValue = jQuery(this).attr('href'); |
|
69 |
|
|
70 |
// Show/Hide Tabs |
|
71 |
jQuery('.tabs ' + currentAttrValue).show().siblings().hide(); |
|
72 |
// Change/remove current tab to active |
|
73 |
jQuery(this).parent('li').addClass('active').siblings().removeClass('active'); |
|
74 |
|
|
75 |
e.preventDefault(); |
|
76 |
|
|
77 |
|
|
78 |
}); |
|
79 |
|
|
80 |
// $('.selectall').change(function() { |
|
81 |
// if ($(this).is(':checked')) { |
|
82 |
// $('div input').attr('checked', true); |
|
83 |
// } else { |
|
84 |
// $('div input').attr('checked', false); |
|
85 |
// } |
|
86 |
// }); |
|
87 |
}); |
|
88 |
|
|
89 |
function removeLast(iFaceBase){ |
|
90 |
var iFaceCount = $('#myTable tr').length -5; |
|
91 |
var temp = $('#myTable tr').length / 5; |
|
92 |
// var tempIfaceBase = kk*5; |
|
93 |
if (temp > iFaceBase) { |
|
94 |
for (var l=0;l<5;l++) { |
|
95 |
$('#myTable tr:eq(' +iFaceCount+ ')').remove(); |
|
96 |
// $('#myTable tr#'+iFaceCount).remove(); |
|
97 |
} |
|
98 |
} else { |
|
99 |
$('#dialog').dialog(); |
|
100 |
} |
|
101 |
} |
|
102 |
|
|
103 |
|
|
104 |
function setEdited(id){ |
|
105 |
$( '#editRepo_interfaces_'+id+'__deleteApi').prop('checked', true); |
|
106 |
} |
|
107 |
|
|
108 |
function removeLastDirect(kk){ |
|
109 |
var iFaceCount = $('#myTable tr').length -4; |
|
110 |
// var tempIfaceBase = kk*5; |
|
111 |
if (iFaceCount >0) { |
|
112 |
for (var l=0;l<4;l++) { |
|
113 |
$('#myTable tr:eq(' +iFaceCount+ ')').remove(); |
|
114 |
// $('#myTable tr#'+iFaceCount).remove(); |
|
115 |
} |
|
116 |
} |
|
117 |
|
|
118 |
} |
|
119 |
|
|
120 |
function addNew(mode){ |
|
121 |
var cssClass; |
|
122 |
var listName; |
|
123 |
if (mode == "reg") { |
|
124 |
cssClass="none" |
|
125 |
listName = "interfaces"; |
|
126 |
} |
|
127 |
if (mode == "edit") { |
|
128 |
cssClass="cd" |
|
129 |
listName = "interfacesNew"; |
|
130 |
} |
|
131 |
var iFaceCount = $('#myTable tr').length / 5; |
|
132 |
var tempIfaceCount = iFaceCount + 1; |
|
133 |
$('#myTable').append( |
|
134 |
'<tr><th class="numb" colspan="3"></th></tr>'+ |
|
135 |
'<tr><th scope="col">Base OAI-PMH Url *</th><td><input type="text" name="'+listName+'['+ iFaceCount + '].baseUrl" size="40" required="true"></td><td class="'+cssClass+'" rowspan="4"><a id="cloneButton2" onclick="removeLast('+iFaceCount+')"></a></td></tr>'+ |
|
136 |
// '<tr id='+iFaceCount+'><th scope="col">Base OAI-PMH Url *</th><td><input type="text" name="interfaces['+ iFaceCount + '].baseUrl" size="40" required="true"></td><td class="cb" rowspan="4"><a id="cloneButton2" onclick="removeLast('+iFaceCount+')">[x]</a></td></tr>'+ |
|
137 |
'<tr><th scope="col">Validation Set</th><td><input type="text" name="'+listName+'['+ iFaceCount + '].accessSet" size="40"></td></tr>'+ |
|
138 |
// '<tr><th scope="col">Current Compatibility Level</th><td>not available</td></tr>'+ |
|
139 |
'<tr></tr>'+ |
|
140 |
'<tr><th scope="col">Desired Compatibility Level</th><td><select name="'+listName+'['+ iFaceCount + '].desiredCompatibilityLevel"> <option value="openaire3.0">OpenAIRE 3.0 (OA, funding)</option> <option value="openaire2.0">OpenAIRE 2.0 (EC funding)</option> <option value="driver">OpenAIRE Basic (DRIVER OA)</option></select></td></tr>'); |
|
141 |
} |
|
142 |
|
|
143 |
function addNewDirect(mode){ |
|
144 |
var iFaceCount = $('#myTable tr').length / 4; |
|
145 |
var tempIfaceCount = iFaceCount + 1; |
|
146 |
var cssClass; |
|
147 |
if (mode == "reg") {cssClass="none"} |
|
148 |
if (mode == "edit") {cssClass="cb"} |
|
149 |
$('#myTable').append( |
|
150 |
// '<tr><th scope="col" class="numb">Interface Number</th><td class="numb">' + tempIfaceCount + '</td></tr>'+ |
|
151 |
'<tr><th class="numb" colspan="3"></th></tr>'+ |
|
152 |
'<tr><th scope="col">Base OAI-PMH Url *</th><td><input type="text" name="interfaces['+ iFaceCount + '].baseUrl" size="40" required="true"></td><td class="'+cssClass+'" rowspan="4"><a id="cloneButton2" onclick="removeLast('+iFaceCount+')"></a></td>'+ |
|
153 |
'<tr><th scope="col">Validation Set</th><td><input type="text" name="interfaces['+ iFaceCount + '].accessSet" size="40"></td>'+ |
|
154 |
'<tr><th scope="col">Desired Compatibility Level</th><td><select name="interfaces['+ iFaceCount + '].desiredCompatibilityLevel"> <option value="openaire3.0">OpenAIRE 3.0 (OA, funding)</option> <option value="openaire2.0">OpenAIRE 2.0 (EC funding)</option> <option value="driver">OpenAIRE Basic (DRIVER OA)</option></select></td>'); |
|
155 |
} |
|
156 |
|
|
157 |
function addNew_data(mode){ |
|
158 |
var cssClass; |
|
159 |
var listName; |
|
160 |
if (mode == "reg") { |
|
161 |
cssClass="none" |
|
162 |
listName = "interfaces"; |
|
163 |
} |
|
164 |
if (mode == "edit") { |
|
165 |
cssClass="cd" |
|
166 |
listName = "interfacesNew"; |
|
167 |
} |
|
168 |
var iFaceCount = $('#myTable tr').length / 5; |
|
169 |
var tempIfaceCount = iFaceCount + 1; |
|
170 |
$('#myTable').append( |
|
171 |
'<tr><th class="numb" colspan="3"></th></tr>'+ |
|
172 |
'<tr><th scope="col">Base OAI-PMH Url *</th><td><input type="text" name="'+listName+'['+ iFaceCount + '].baseUrl" size="40" required="true"></td><td class="'+cssClass+'" rowspan="4"><a id="cloneButton2" onclick="removeLast('+iFaceCount+')"></a></td></tr>'+ |
|
173 |
// '<tr id='+iFaceCount+'><th scope="col">Base OAI-PMH Url *</th><td><input type="text" name="interfaces['+ iFaceCount + '].baseUrl" size="40" required="true"></td><td class="cb" rowspan="4"><a id="cloneButton2" onclick="removeLast('+iFaceCount+')">[x]</a></td></tr>'+ |
|
174 |
'<tr><th scope="col">Validation Set</th><td><input type="text" name="'+listName+'['+ iFaceCount + '].accessSet" size="40"></td></tr>'+ |
|
175 |
// '<tr><th scope="col">Current Compatibility Level</th><td>not available</td></tr>'+ |
|
176 |
'<tr></tr>'+ |
|
177 |
'<tr><th scope="col">Desired Compatibility Level</th><td><select name="'+listName+'['+ iFaceCount + '].desiredCompatibilityLevel"><option value="openaire2.0_data">OpenAIRE 2.0 (EC funding)</option></select></td></tr>'); |
|
178 |
} |
|
179 |
|
|
180 |
function addNewDirect_data(mode){ |
|
181 |
var iFaceCount = $('#myTable tr').length / 4; |
|
182 |
var tempIfaceCount = iFaceCount + 1; |
|
183 |
var cssClass; |
|
184 |
if (mode == "reg") {cssClass="none"} |
|
185 |
if (mode == "edit") {cssClass="cb"} |
|
186 |
$('#myTable').append( |
|
187 |
// '<tr><th scope="col" class="numb">Interface Number</th><td class="numb">' + tempIfaceCount + '</td></tr>'+ |
|
188 |
'<tr><th class="numb" colspan="3"></th>/tr>'+ |
|
189 |
'<tr><th scope="col">Base OAI-PMH Url *</th><td><input type="text" name="interfaces['+ iFaceCount + '].baseUrl" size="40" required="true"></td></tr>'+ |
|
190 |
'<tr><th scope="col">Validation Set</th><td><input type="text" name="interfaces['+ iFaceCount + '].accessSet" size="40"></td></tr>'+ |
|
191 |
'<tr><th scope="col">Desired Compatibility Level</th><td><select name="interfaces['+ iFaceCount + '].desiredCompatibilityLevel"><option value="openaire2.0_data">OpenAIRE 3.0</option></select></td></tr>'); |
|
192 |
} |
modules/uoa-madgik-validator/tags/1.0.0/src/main/webapp/jsps/js/ddmenu.js | ||
---|---|---|
1 |
var ddmenuOptions= |
|
2 |
{ |
|
3 |
menuId: "ddmenu", |
|
4 |
linkIdToMenuHtml: null, |
|
5 |
effect: "slide", |
|
6 |
delay: 50, |
|
7 |
//dl114 |
|
8 |
/* license: "2c7u1" */ |
|
9 |
//production |
|
10 |
license: "2c1o2" |
|
11 |
}; |
|
12 |
|
|
13 |
var ddmenu=new McDdMenu(ddmenuOptions); |
|
14 |
|
|
15 |
/* Menucool Drop Down Menu v2013.3.18 Copyright www.menucool.com */ |
|
16 |
function McDdMenu(d){var o=function(a,b){return a.getElementsByTagName(b)},k=function(b,d){if(window.getComputedStyle)var c=window.getComputedStyle(b,null);else if(b.currentStyle)c=b.currentStyle;else c=b[a];return c[d]},e=function(a,c,b){if(a.addEventListener)a.addEventListener(c,b,false);else a.attachEvent&&a.attachEvent("on"+c,b)},t=function(a){if(a&&a.stopPropagation)a.stopPropagation();else window.event.cancelBubble=true},F=function(b){var a=b?b:window.event;a.preventDefault&&a.preventDefault();a.returnValue=false;return false},b,l,y,a,c,i,g,f,n,x=document,L=["$1$2$3","$1$2$3","$1$24","$1$23","$1$22"];mcDdl=0;var K=[/(?:.*\.)?(\w)([\w\-])[^.]*(\w)\.[^.]+$/,/.*([\w\-])\.(\w)(\w)\.[^.]+$/,/^(?:.*\.)?(\w)(\w)\.[^.]+$/,/.*([\w\-])([\w\-])\.com\.[^.]+$/,/^(\w)[^.]*(\w)+$/],D=function(){var c=50,b=navigator.userAgent,a;if((a=b.indexOf("MSIE "))!=-1)c=parseInt(b.substring(a+5,b.indexOf(".",a)));return c},B=function(){b={a:d.license,b:d.menuId,c:d.effect=="none"?0:1,d:d.delay,e:d.linkIdToMenuHtml}},j=D(),m=function(d){var a=d.childNodes,c=[];if(a)for(var b=0,e=a.length;b<e;b++)a[b].nodeType==1&&c.push(a[b]);return c},C=function(b){var a=[],c=b.length;while(c--)a.push(String.fromCharCode(b[c]));return a.join("")},z=function(a){return a.replace(/(?:.*\.)?(\w)([\w\-])?[^.]*(\w)\.[^.]*$/,"$1$3$2")},L_1=function(e,c){var d=function(a){for(var c=a.substr(0,a.length-1),e=a.substr(a.length-1,1),d="",b=0;b<c.length;b++)d+=c.charCodeAt(b)-e;return unescape(d)},a=z(document.domain)+Math.random(),b=d(a);l="%66%75%6E%63%74%69%6F%6E%20%71%51%28%73%2C%6B%29%7B%76%61%72%20%72%3D%27%27%3B%66%6F%72%28%76%61%72%20%69%";if(b.length==39)try{a=(new Function("$","_",w(l))).apply(this,[b,c]);l=a}catch(f){}},M=function(a,b){return b?x[a](b):x[a]},w=function(d,b){for(var c=[],a=0;a<d.length;a++)c[c.length]=String.fromCharCode(d.charCodeAt(a)-(b&&b>7?b:3));return c.join("")},I=function(c,a){var b=function(b){var a=b.charCodeAt(0).toString();return a.substring(a.length-1)};return c+b(a[2])+a[0]+b(a[1])},G=function(a,c){var b=a.length;while(b--)if(a[b]===c)return true;return false},H=function(a,c){var b=false;if(a.className)b=G(a.className.split(" "),c);return b},h=function(a,b,c){if(!H(a,b))if(a.className=="")a.className=b;else if(c)a.className=b+" "+a.className;else a.className+=" "+b},p=function(c,e){if(c.className){for(var d="",b=c.className.split(" "),a=0,f=b.length;a<f;a++)if(b[a]!==e)d+=b[a]+" ";c.className=d}},s=function(a){this.a=null;this.b=a;this.c=null;this.d=null;this.e=null;this.f();this.g()},v=function(a){this.o(a);this.p(a)};s.prototype={j:function(){var a=this;clearTimeout(a.d);j<9&&clearTimeout(a.e);a.d=setTimeout(function(){a.l()},110)},k:function(){h(this.b,"over");this.c[a][c]="block";b.c&&this.m(this.c.mh,this.c.mj)},f:function(){if(j<8)this.b[a][c]="inline";var f=m(this.b);if(f.length)if(f[0][n]!="A"){var b=document.createElement("a");b.setAttribute("href","#");e(b,"click",function(a){t(a);return F(a)});this.b.insertBefore(b,this.b.firstChild);var d;while(d=b.nextSibling){if(d.nodeType==1&&d[n]=="DIV")break;b.appendChild(d)}this.a=b}else this.a=f[0]},m:function(b,h){var i=this;clearTimeout(i.e);var c=this.c[f];if(c<b){var e=Math.ceil((b-c)*.3);if(e<2)e=2;var d=c+e;if(d>b)d=b;this.c[a][g]=d-h+"px";this.e=setTimeout(function(){i.m(b,h)},16)}else delete this.e},g:function(){var d=m(this.b),s=this;if(d.length==2){h(d[0],"arrow",1);h(d[1],"drop",1);this.h();var o=parseInt(k(d[1],"borderTopWidth")),t=parseInt(k(d[1],"borderBottomWidth")),n=k(d[1],"width");d[1][a][i]="3000px";d[1][a].top=d[0][f]-o+"px";d[1][a].overflow="hidden";var l=document.createElement("div");l[a][c]="block";l[a].position="relative";l[a].styleFloat="left";l[a].cssFloat="left";d[1].insertBefore(l,d[1].firstChild);var r;while(r=l.nextSibling)l.appendChild(r);if(n=="auto"||parseInt(n)<l.offsetWidth+1)d[1][a][i]=l.offsetWidth+(j==9?1:j==7?4:0)+"px";else d[1][a][i]=n;l[a].top="auto";l[a].bottom="0";this.c=d[1];this.c.mj=o+t;this.c.mh=this.c[f];var q=this.c.firstChild.offsetTop,u=this.c.mh-q-this.c.firstChild[f]-this.c.mj;this.c.mi=this.c.mh-this.c.mj;this.c[a].paddingTop="0px";this.c[a].paddingBottom="0px";this.c[a][g]=b.c?"0px":this.c.mi+"px";this.c[a][c]="none";l[a].position="absolute";l[a].paddingTop=q+"px";l[a].paddingBottom=u+"px";e(this.b,"mouseover",function(a){s.i(a)});e(this.b,"mouseout",function(a){s.j(a)})}else{e(this.b,"mouseover",function(){h(this,"over")});e(this.b,"mouseout",function(){p(this,"over")})}},h:function(){for(var d=o(this.b,"div"),b=0,e=d.length;b<e;b++)d[b][a][c]="block"},n:function(h,f){var e=this;clearTimeout(e.e);var d=parseInt(this.c[a][g]);if(d>0){var b=Math.floor(d*.7);if(d-b<6)b=d-6;if(b<0)b=0;this.c[a][g]=b+"px";this.e=setTimeout(function(){e.n(h,f)},16)}else{this.c[a][c]="none";delete this.e}},i:function(c){var a=this;clearTimeout(a.d);a.d=setTimeout(function(){a.k()},b.d);t(c)},l:function(){p(this.b,"over");delete this.d;var d=this;if(b.c)d.n(d.c.mh,d.c.mj);else d.c[a][c]="none"}};v.prototype={o:function(a){L_1(a,b.a)},p:function(a){c="display";i="width";g="height";(new Function("a","b","c","d","e","f","g","h","i","j","k","z","y",function(c){for(var b=[],a=0,d=c.length;a<d;a++)b[b.length]=String.fromCharCode(c.charCodeAt(a)-4);return b.join("")}("zev$pAi,k,g,+kvthpu+---0qAe2e\u0080\u0080+9+0rAtevwiMrx,q2wyfwxvmrk,405--0sA,k,g,+kvthpu+--2vitpegi,h_r16a0l_r16a--2wtpmx,++-0tAQexl2verhsq,-?mj,%p\u0080\u0080p2wyfwxvmrk,406-AA+ps+\u0080\u0080qAAj,r/+g+0s--qgHhpA5?ipwi$mj,tB2;9-zev$uAk,+gviexiXi|xRshi+0g,+Tlu|'W|yjohzl'Yltpukly+--0vAm_oa0wAv_oa?mj,tB2<9**w2rshiReqi%A+FSH]+-w_oa2mrwivxFijsvi,u0w-?ipwi$w2mrwivxFijsvi,u0v-?\u0081jsv,zev$xA4?x@~2pirkxl?x//-mj,~_xa2rshiReqiAA+PM+-ri{$},~_xa-?"))).apply(this,[b,C,w,K,z,I,M,L,a,null,y,m(a),s])}};var A=function(b){var a;if(window.XMLHttpRequest)a=new XMLHttpRequest;else a=new ActiveXObject("Microsoft.XMLHTTP");a.onreadystatechange=function(){if(a.readyState==4&&a.status==200){var c=a.responseText,e=/^[\s\S]*<body[^>]*>([\s\S]+)<\/body>[\s\S]*$/i;if(e.test(c))c=c.replace(e,"$1");c=c.replace(/^\s+|\s+$/g,"");var d=document.createElement("div");d.style.padding="0";d.style.margin="0";b.parentNode.insertBefore(d,b);d.innerHTML=c;b.style.display="none";q()}};a.open("GET",b.href,true);a.send()},r=function(){if(b.e){var a=document.getElementById(b.e);if(a)A(a);else alert('Cannot find the anchor (id="'+b.e+'")')}else q()},q=function(){var b=document.getElementById(d.menuId);y="parentNode",a="style",n="nodeName",f="offsetHeight";if(b){b=o(b,"ul");b.length&&new v(b[0])}},E=function(d){var b=false;function a(){if(b)return;b=true;setTimeout(d,4)}if(document.addEventListener)document.addEventListener("DOMContentLoaded",a,false);else if(document.attachEvent){try{var e=window.frameElement!=null}catch(f){}if(document.documentElement.doScroll&&!e){function c(){if(b)return;try{document.documentElement.doScroll("left");a()}catch(d){setTimeout(c,10)}}c()}document.attachEvent("onreadystatechange",function(){document.readyState==="complete"&&a()})}if(window.addEventListener)window.addEventListener("load",a,false);else window.attachEvent&&window.attachEvent("onload",a)};B();var J=document.createElement("nav"),u=o(document,"head");if(!u.length)return;u[0].appendChild(J);E(r);return{init:r}} |
modules/uoa-madgik-validator/tags/1.0.0/src/main/webapp/jsps/js/repoInterfacesBak.js | ||
---|---|---|
1 |
$(document).ready(function(){ |
|
2 |
var checked1; |
|
3 |
$('.progress').hide(); |
|
4 |
if($('#allowPdf').is(':checked')) { |
|
5 |
$('.addSource').show(); |
|
6 |
checked1 = ($('#registerRepo_pubFileIface_methodologyfiles_from_api').is(':checked')); |
|
7 |
checked2 = ($('#registerRepo_pubFileIface_methodologyfiles_from_metadata').is(':checked')); |
|
8 |
if($('#registerRepo_pubFileIface_methodologyfiles_from_api').is(':checked')) { |
|
9 |
$('.harvest').show(); |
|
10 |
$('.metadata').hide(); |
|
11 |
} |
|
12 |
else { |
|
13 |
$('.metadata').show(); |
|
14 |
$('.harvest').hide(); |
|
15 |
} |
|
16 |
} else { |
|
17 |
$('.addSource').hide(); |
|
18 |
$('.harvest').hide(); |
|
19 |
$('.metadata').hide(); |
|
20 |
} |
|
21 |
$('#allowPdf').change(function(){ |
|
22 |
var checked = $(this).is(":checked"); |
|
23 |
if(!checked) { |
|
24 |
$('.addSource').hide(); |
|
25 |
$('.harvest').hide(); |
|
26 |
} else { |
|
27 |
$('.addSource').show(); |
|
28 |
if(checked1) { |
|
29 |
$('.harvest').show(); |
|
30 |
} |
|
31 |
if(checked2) { |
|
32 |
$('.metadata').show(); |
|
33 |
} |
|
34 |
} |
|
35 |
}); |
|
36 |
|
|
37 |
$('#subm').click(function() { |
|
38 |
$('.progress').show(); |
|
39 |
}); |
|
40 |
|
|
41 |
$('.myRadio').click(function() { |
|
42 |
if($(this).val() == 'files_from_api') { |
|
43 |
$('.harvest').show(); |
|
44 |
$('.metadata').hide(); |
|
45 |
} |
|
46 |
else if($(this).val() == 'files_from_metadata') { |
|
47 |
$('.harvest').hide(); |
|
48 |
$('.metadata').show(); |
|
49 |
} |
|
50 |
}); |
|
51 |
}); |
|
52 |
|
|
53 |
function addNew(){ |
|
54 |
var rowCount = $('#myTable tr').length - 1; |
|
55 |
$('#myTable').append('<tr>'+ |
|
56 |
'<td><input type="text" name="interfaces['+ rowCount + '].baseUrl" size="22%" required="true"></td>'+ |
|
57 |
'<td><input type="text" name="interfaces['+ rowCount + '].accessSet" size="14%" required="true"></td>'+ |
|
58 |
'<td><input type="text" name="interfaces['+ rowCount + '].compliance" value="not available" size="30%" required="true"></td>'+ |
|
59 |
'<td><select name="interfaces['+ rowCount + '].desiredCompatibilityLevel"> <option value="openaire3.0">OpenAIRE 3.0 (OA, funding)</option> <option value="openaire2.0">OpenAIRE 2.0 (EC funding)</option> <option value="driver">OpenAIRE Basic (DRIVER OA)</option></select></td>'+ |
|
60 |
'<td></td>'+ |
|
61 |
'</tr>'); |
|
62 |
} |
|
63 |
|
|
64 |
function addNewDirect(){ |
|
65 |
var rowCount = $('#myTable tr').length - 1; |
|
66 |
$('#myTable').append('<tr>'+ |
|
67 |
'<td><input type="text" name="interfaces['+ rowCount + '].baseUrl" size="30%" required="true"></td>'+ |
|
68 |
'<td><input type="text" name="interfaces['+ rowCount + '].accessSet" size="20%" required="true"></td>'+ |
|
69 |
'<td><select name="interfaces['+ rowCount + '].desiredCompatibilityLevel"> <option value="openaire3.0">OpenAIRE 3.0 (OA, funding)</option> <option value="openaire2.0">OpenAIRE 2.0 (EC funding)</option> <option value="driver">OpenAIRE Basic (DRIVER OA)</option></select></td>'+ |
|
70 |
'</tr>'); |
|
71 |
} |
|
72 |
|
|
73 |
function addNew_data(){ |
|
74 |
var rowCount = $('#myTable tr').length - 1; |
|
75 |
$('#myTable').append('<tr>'+ |
|
76 |
'<td><input type="text" name="interfaces['+ rowCount + '].baseUrl" size="22%" required="true"></td>'+ |
|
77 |
'<td><input type="text" name="interfaces['+ rowCount + '].accessSet" size="14%" required="true"></td>'+ |
|
78 |
'<td><input type="text" name="interfaces['+ rowCount + '].compliance" value="not available" size="30%" required="true"></td>'+ |
|
79 |
'<td><select name="interfaces['+ rowCount + '].desiredCompatibilityLevel"><option value="openaire3.0_data">OpenAIRE 3.0 (OA, funding)</option></select></td>'+ |
|
80 |
'<td></td>'+ |
|
81 |
'</tr>'); |
|
82 |
} |
|
83 |
|
|
84 |
function addNewDirect_data(){ |
|
85 |
var rowCount = $('#myTable tr').length - 1; |
|
86 |
$('#myTable').append('<tr>'+ |
|
87 |
'<td><input type="text" name="interfaces['+ rowCount + '].baseUrl" size="30%" required="true"></td>'+ |
|
88 |
'<td><input type="text" name="interfaces['+ rowCount + '].accessSet" size="20%" required="true"></td>'+ |
|
89 |
'<td><select name="interfaces['+ rowCount + '].desiredCompatibilityLevel"><option value="openaire3.0_data">OpenAIRE 3.0</option></select></td>'+ |
|
90 |
'</tr>'); |
|
91 |
} |
modules/uoa-madgik-validator/tags/1.0.0/src/main/webapp/jsps/js/populateRules.js | ||
---|---|---|
1 |
|
|
2 |
var thirdparSlide; |
|
3 |
|
|
4 |
function validateUrl() { |
|
5 |
var formurl; |
|
6 |
|
|
7 |
if ($('selectButtonselect').checked) { |
|
8 |
formurl = $('baseUrl').value; |
|
9 |
|
|
10 |
} else { |
|
11 |
formurl = $('baseUrl2').value; |
|
12 |
} |
|
13 |
|
|
14 |
var jsonRequest = new Request({ |
|
15 |
url: 'identifyRepo.action', |
|
16 |
|
|
17 |
onRequest: function() { |
|
18 |
$('urlError').getChildren().each(function(child) { |
|
19 |
child.dispose(); |
|
20 |
}); |
|
21 |
}, |
|
22 |
|
|
23 |
onSuccess: function () { |
|
24 |
$('firstpar').setStyle('display','none'); |
|
25 |
$('firstpar-select').setStyle('display','block'); |
|
26 |
$('secondpar').setStyle('display','block'); |
|
27 |
$('thirdpar').setStyle('display','block'); |
|
28 |
$('fourthpar').setStyle('display','block'); |
|
29 |
|
|
30 |
$('repoUrl').empty(); |
|
31 |
$('repoUrl').appendText(formurl); |
|
32 |
loadSets(formurl); |
|
33 |
}, |
|
34 |
|
|
35 |
|
|
36 |
onFailure: function (xhr) { |
|
37 |
var span = new Element('span'); |
|
38 |
span.appendText('Unable to contact repository. Please check again the given Base URL'); |
|
39 |
$('urlError').grab(span); |
|
40 |
}, |
|
41 |
|
|
42 |
onException: function (headerName, value) { |
|
43 |
alert(headerName); |
|
44 |
alert(value); |
|
45 |
}, |
|
46 |
|
|
47 |
method: 'get' |
|
48 |
|
|
49 |
}).get({'baseUrl':formurl}); |
|
50 |
|
|
51 |
} |
|
52 |
|
|
53 |
function changeDisplays() { |
|
54 |
$('firstpar').setStyle('display','block'); |
|
55 |
$('firstpar-select').setStyle('display','none'); |
|
56 |
$('secondpar').setStyle('display','none'); |
|
57 |
$('thirdpar').setStyle('display','none'); |
|
58 |
$('fourthpar').setStyle('display','none'); |
|
59 |
} |
|
60 |
|
|
61 |
function loadRules(ruleSetId) { |
|
62 |
var jsonRequest = new Request.JSON({url: 'populateList', onSuccess: function(rules) { |
|
63 |
|
|
64 |
<!-- Clean everything --> |
|
65 |
$('contentR').getChildren().each(function(child) { |
|
66 |
child.dispose(); |
|
67 |
}); |
|
68 |
|
|
69 |
$('usage').getChildren().each(function(child) { |
|
70 |
child.dispose(); |
|
71 |
}); |
|
72 |
|
|
73 |
<!-- contentR Rules --> |
|
74 |
for (i = 0; i < rules.contentRules.length; i++) { |
|
75 |
var span = new Element('span', {'class':'rule'}); |
|
76 |
var label = new Element('label', {title:rules.contentRules[i].description}); |
|
77 |
var check = new Element('input', {type:'checkbox', checked:'on', name:'contentRules[' + rules.contentRules[i].id + ']', 'class':'validation-contentRules', value:'true'}); |
|
78 |
|
|
79 |
label.grab(check); |
|
80 |
label.appendText(' ' + rules.contentRules[i].name); |
|
81 |
span.grab(label); |
|
82 |
$('contentR').grab(span); |
|
83 |
$('contentR').grab(new Element('br')); |
|
84 |
} |
|
85 |
|
|
86 |
<!-- Usage Rules --> |
|
87 |
for (i = 0; i < rules.usageRules.length; i++) { |
|
88 |
var span = new Element('span', {'class':'rule'}); |
|
89 |
var label = new Element('label', { title:rules.usageRules[i].description}) |
|
90 |
var check = new Element('input', {type:'checkbox', checked:'on', name:'usageRules[' + rules.usageRules[i].id + ']', 'class':'validation-usageRules', value:'true'}); |
|
91 |
|
|
92 |
label.grab(check); |
|
93 |
label.appendText(' ' + rules.usageRules[i].name); |
|
94 |
span.grab(label); |
|
95 |
$('usage').grab(span); |
|
96 |
$('usage').grab(new Element('br')); |
|
97 |
} |
|
98 |
|
|
99 |
$('contentRules').checked = 'on'; |
|
100 |
$('usageRules').checked = 'on'; |
|
101 |
addRuleEvents(); |
|
102 |
|
|
103 |
$('records').set('disabled', false); |
|
104 |
$('set').set('disabled', false); |
|
105 |
|
|
106 |
}}).get({'ruleSetId': ruleSetId}); |
|
107 |
} |
|
108 |
|
|
109 |
function addRuleEvents() { |
|
110 |
$$('[class="validation"]').each(function (el) { |
|
111 |
$$('[class="validation-' + el.id + '"]').addEvent('change', function () { |
|
112 |
var count = 0; |
|
113 |
var current = 0; |
|
114 |
$$('[class="validation-' + el.id + '"]').each(function (el2) { |
|
115 |
if(el2.checked == false) { |
|
116 |
el.checked = false; |
Also available in: Unified diff
Creating tag for first production release