Project

General

Profile

« Previous | Next » 

Revision 9498

Added by Jing Tao almost 9 years ago

Add a page for configuring the ezid.

View differences:

lib/admin/ezid-configuration.jsp
1
<%@ page language="java" %>
2
<%@ page import="java.util.Set,java.util.Map,java.util.Vector,edu.ucsb.nceas.utilities.PropertiesMetaData" %>
3
<%@ page import="edu.ucsb.nceas.utilities.MetaDataGroup,edu.ucsb.nceas.utilities.MetaDataProperty" %>
4
<% 
5
/**
6
 *  '$RCSfile$'
7
 *    Copyright: 2008 Regents of the University of California and the
8
 *               National Center for Ecological Analysis and Synthesis
9
 *  For Details: http://www.nceas.ucsb.edu/
10
 *
11
 *   '$Author: daigle $'
12
 *     '$Date: 2008-07-29 10:31:02 -0700 (Tue, 29 Jul 2008) $'
13
 * '$Revision: 4176 $'
14
 * 
15
 * This program is free software; you can redistribute it and/or modify
16
 * it under the terms of the GNU General Public License as published by
17
 * the Free Software Foundation; either version 2 of the License, or
18
 * (at your option) any later version.
19
 *
20
 * This program is distributed in the hope that it will be useful,
21
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
22
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
23
 * GNU General Public License for more details.
24
 *
25
 * You should have received a copy of the GNU General Public License
26
 * along with this program; if not, write to the Free Software
27
 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
28
 */
29
%>
30

  
31
<html>
32
<head>
33

  
34
<title>EZID for DOI Configuration</title>
35
<%@ include file="./head-section.jsp"%>
36
</head>
37
<body>
38
<%@ include file="./header-section.jsp"%>
39

  
40
<div class="document">
41
	<h2>EZID for DOI Configuration</h2>
42
	
43
	<p>
44
		Configure the EZID service to generate and assign Digital Object Identifiers (DOIs) to objects
45
	</p>
46
	<!-- MCD TODO add geoserver instructions page -->
47
	<br clear="right"/>
48
	
49
	<%@ include file="page-message-section.jsp"%>
50
	
51
	<form method="POST" name="configuration_form" action="<%= request.getContextPath() %>/admin" 
52
	                                        onsubmit="return submitForm(this);">
53
	
54
		<h3>EZID Service Configuration</h3>
55
		<div class="form-row">
56
            <div class="textinput-label"><label for="guid.ezid.enabled" title="Enable EZID service">Enable EZID service</label></div>
57
    
58
            <%
59
            boolean enable = (Boolean) request.getAttribute("guid.ezid.enabled");
60
            if (enable) { 
61
            %>
62
            <input type="checkbox" class="textinput" id="guid.ezid.enabled" 
63
                    name="guid.ezid.enabled"                                                                                         
64
                    value="true"
65
                    checked="checked"/>
66
            <% } else {%>
67
            <input type="checkbox" class="textinput" id="guid.ezid.enabled" 
68
                    name="guid.ezid.enabled"                                                                                         
69
                    value="true"/>
70
            <% } %>
71
            <!--<i class="icon-question-sign" onClick="helpWindow('<%= request.getContextPath() %>','docs/geoserver.html#GEOSERVER_REGENERATE_CACHE')"></i> -->
72
        </div>
73
		<div class="form-row">
74
                    <div class="textinput-label"><label for="guid.ezid.username" title="EZID user name">User Name</label></div>
75
                    <input class="textinput" id="guid.ezid.username" 
76
                           name="guid.ezid.username"                                                                         
77
                           value="<%= request.getAttribute("guid.ezid.username") %>"/> 
78
                    <!--<i class="icon-question-sign" onClick="helpWindow('<%= request.getContextPath() %>','docs/geoserver.html#GeoserverUpdatePassword')"></i> -->
79
        </div>
80
        <div class="form-row">
81
                    <div class="textinput-label"><label for="guid.ezid.password" title="Password">Password</label></div>
82
                    <input class="textinput"  id="guid.ezid.password" 
83
                           name="guid.ezid.password" 
84
                           type="password"                                                                                      
85
                           value="<%= request.getAttribute("guid.ezid.password") %>"/> 
86
                    <!--<i class="icon-question-sign" onClick="helpWindow('<%= request.getContextPath() %>','docs/geoserver.html#GeoserverUpdatePassword')"></i>-->
87
        </div>
88
        <div class="form-row">
89
            <div class="textinput-label"><label for="guid.ezid.baseurl" title="EZID Service URL">Service base URL</label></div>
90
            <input class="textinput" id="guid.ezid.baseurl" 
91
                    name="guid.ezid.baseurl"                                                                                         
92
                    value="<%= request.getAttribute("guid.ezid.baseurl") %>"/> 
93
            <!--<i class="icon-question-sign" onClick="helpWindow('<%= request.getContextPath() %>','docs/geoserver.html#GEOSERVER_DATA_DIR')"></i> -->
94
        </div>
95
		<div class="form-row">
96
			<div class="textinput-label"><label for="guid.ezid.doishoulder.1" title="DOI shoulder">DOI shoulder</label></div>
97
			<input class="textinput" id="guid.ezid.doishoulder.1" 
98
					name="guid.ezid.doishoulder.1" 	             		    	    	           		    	             			
99
					value="<%= request.getAttribute("guid.ezid.doishoulder.1") %>"/> 
100
			<!--<i class="icon-question-sign" onClick="helpWindow('<%= request.getContextPath() %>','docs/geoserver.html#GeoserverContext')"></i>-->
101
		</div>
102
	
103
		
104
		<div class="buttons-wrapper">
105
			<input type="hidden" name="configureType" value="ezid"/>
106
			<input type="hidden" name="processForm" value="true"/>
107
			<input class=button type="submit" value="Update"/>
108
			<input class=button type="button" value="Bypass" onClick="forward('./admin?configureType=ezid&bypass=true&processForm=true')">
109
			<input class=button type="button" value="Cancel" onClick="forward('./admin')"> 
110
		</div>
111
	</form>
112
</div>
113

  
114
<%@ include file="./footer-section.jsp"%>
115

  
116
</body>
117
</html>
0 118

  
lib/admin/metacat-configuration.jsp
40 40
    Boolean replicationConfigured = (Boolean)request.getAttribute("replicationConfigured");
41 41
    String dataoneConfigured = (String)request.getAttribute("dataoneConfigured");
42 42
    String geoserverConfigured = (String)request.getAttribute("geoserverConfigured");
43
    String ezidConfigured = (String)request.getAttribute("ezidConfigured");
43 44
    Boolean metacatConfigured = (Boolean)request.getAttribute("metacatConfigured");
44 45
    Boolean metacatServletInitialized = (Boolean)request.getAttribute("metcatServletInitialized");
45 46
    String contextURL = (String)request.getAttribute("contextURL");
......
271 272
	%>     	
272 273
	   	</tr>
273 274
	
275
	<!-- ezid -->
276
     <%
277
    
278
        if (ezidConfigured != null && ezidConfigured.equals(PropertyService.CONFIGURED)) {
279
    %>
280
            <tr>
281
            <td class="configured-tag"><i class="icon-ok"></i> configured</td>
282
            <td class="property-title"> Dataone Configuration </td> 
283
            <td class="configure-link"><a href="<%= request.getContextPath() %>/admin?configureType=ezid"><i class="icon-cogs"></i>Reconfigure Now</a> </td>         
284
            </tr>
285
    <%
286
        } else if (ezidConfigured != null && ezidConfigured.equals(PropertyService.BYPASSED)){
287
    %>          
288
            <tr>
289
            <td class="configured-tag"><i class="icon-ok"></i> bypassed </td>  
290
            <td class="property-title">EZID Configuration for DOIs</td>  
291
    <%
292
            if (propsConfigured != null && propsConfigured) {
293
    %>
294
                
295
            <td class="configure-link"> <a href="<%= request.getContextPath() %>/admin?configureType=ezid"><i class="icon-cogs"></i> Reconfigure Now</a> </td>                   
296
    <%
297
            } else {
298
    %> 
299
            <td class="configure-link inactive"> Configure Global Properties First </td>
300
    <%
301
            }
302
                %>      
303
            </tr>
304
    <%
305
        } else {
306
    %>          
307
            <tr>
308
            <td class="unconfigured-tag">unconfigured </td>  
309
            <td class="property-title"> EZID for Digital Object Identifiers (DOIs) Configuration </td>   
310
    <%
311
            if (propsConfigured != null && propsConfigured) {
312
    %>
313
                
314
            <td class="configure-link"><a href="<%= request.getContextPath() %>/admin?configureType=ezid"> <i class="icon-cogs"></i> Configure Now</a> </td>         
315
                
316
    <%
317
            } else {
318
    %> 
319
            <td class="configure-link inactive"> Configure Global Properties First </td>
320
    <%
321
            }
322
    %>      
323
            </tr>
324
    <%
325
        }
326
    %>
274 327
	
275
	
276 328
	<!--  -->
277 329
	</table>
278 330
	

Also available in: Unified diff