Project

General

Profile

1
<?xml version="1.0" encoding="UTF-8"?>
2
<jsp:root xmlns:jsp="http://java.sun.com/JSP/Page" version="2.0">
3
    
4
    <jsp:directive.page contentType="text/html;charset=UTF-8"/>
5
    <jsp:directive.page import="edu.ucsb.nceas.metacat.clientview.ClientViewHelper"/>
6
    <jsp:directive.page import="edu.ucsb.nceas.metacat.clientview.ClientView"/>
7
    <jsp:directive.include file="settings.jsp" />
8
    
9
    <jsp:declaration>
10
        private ClientViewHelper            clientViewHelper;
11
    </jsp:declaration>
12
    
13
    <html xmlns="http://www.w3.org/1999/xhtml">
14
        <head>
15
        	<title>SANParks - South African National Park Data Repository</title>
16
        	<jsp:element name="link">
17
				<jsp:attribute name="rel">stylesheet</jsp:attribute>
18
				<jsp:attribute name="type">text/css</jsp:attribute>
19
				<jsp:attribute name="href">
20
					<jsp:expression>CONTEXT_URL + "/style/skins/sanparks/sanparks.css"</jsp:expression>
21
				</jsp:attribute>
22
			</jsp:element>
23
        </head>
24
        <body style="background: #FFFFFF;">
25
            <jsp:useBean id="clientViewBean" scope="session" class="edu.ucsb.nceas.metacat.clientview.ClientView"/>
26
            <jsp:setProperty name="clientViewBean" property="*"/>
27
            
28
            <h2>Delete Data Packages</h2>
29
            
30
            <jsp:scriptlet>
31
                clientViewHelper = ClientViewHelper.clientViewHelperInstance(request);
32
                clientViewHelper.clientRequest(request, response);
33
                if (clientViewHelper.isLoggedIn()) {
34
            </jsp:scriptlet>
35
            
36
            <table>
37
                <tr>
38
                    <td colspan="3">
39
                        <h3>Search</h3>
40
                        <p class="regtext">
41
                        	Retrieve a list of existing FGDC data packages for a specified scope.
42
                        </p>	
43
                        <form name="scopeForm" method="post" action="SaeonDelete.jspx">
44
                            <input name="returnfield" type="hidden" value="distinfo/stdorder/digform/digtopt/onlinopt/computer/networka/networkr"/>
45
                            <input name="pathExpr" type="hidden" value="/metadata/distinfo/resdesc"/>
46
                            <jsp:element name="input">
47
                                <jsp:attribute name="name">sessionid</jsp:attribute>
48
                                <jsp:attribute name="type">hidden</jsp:attribute>
49
                                <jsp:attribute name="value">
50
                                	<jsp:getProperty name="clientViewBean" property="sessionid"/>
51
                                </jsp:attribute>
52
                            </jsp:element>
53
                            <p class="regtext">
54
                                <!-- Set the pathValue to the username (the scope) -->
55
                                <jsp:element name="input">
56
                                    <jsp:attribute name="name">pathValue</jsp:attribute>
57
                                    <jsp:attribute name="type">text</jsp:attribute>
58
                                    <jsp:attribute name="value">
59
                                    	<jsp:getProperty name="clientViewBean" property="username"/>
60
                                    </jsp:attribute>
61
                                    <jsp:attribute name="size">14</jsp:attribute>
62
                                </jsp:element>
63
                                <input name="action" value="Scope" type="submit" class="button_login"/>
64
                            </p>
65
                        </form>
66
                        
67
                    </td>
68
                </tr>
69
                
70
                <jsp:scriptlet>
71
                    if (clientViewBean.getMessage(ClientView.SELECT_MESSAGE) != null) {
72
                </jsp:scriptlet>
73
                 <tr>
74
                    <td>
75
                    	<h3>Delete</h3>
76
                        <p class="regtext">
77
                            Caution: Removes records from metacat server and, if a metadata Doc Id, any associated Doc Id records.
78
                        </p>
79
                    </td>
80
				</tr>
81
                <tr>
82
                    <td>
83
                        <form name="deleteForm" method="post" action="SaeonDelete.jspx">
84
                            <jsp:element name="input">
85
                                <jsp:attribute name="name">sessionid</jsp:attribute>
86
                                <jsp:attribute name="type">hidden</jsp:attribute>
87
                                <jsp:attribute name="value">
88
                                	<jsp:getProperty name="clientViewBean" property="sessionid"/>
89
                                </jsp:attribute>
90
                            </jsp:element>
91
                            <jsp:expression>clientViewBean.getMessage(ClientView.SELECT_MESSAGE)</jsp:expression>
92
                            
93
                            <input name="action" type="submit" value="Delete" class="button_login"/>
94
                        </form>
95
                        
96
                    </td>
97
                </tr>
98
                <tr>
99
                    <td>
100
                        <p class="regtext">
101
                            <jsp:scriptlet>if (clientViewBean.getMessage(ClientView.DELETE_MESSAGE) != null) {</jsp:scriptlet>
102
								<jsp:expression>clientViewBean.getMessage(ClientView.DELETE_MESSAGE)</jsp:expression>
103
                            <jsp:scriptlet>}</jsp:scriptlet>
104
                        </p>
105
                    </td>
106
                </tr>
107
                <jsp:scriptlet>
108
                    }
109
                </jsp:scriptlet>
110
            </table>
111
            
112
            <jsp:scriptlet>
113
                } else {
114
            </jsp:scriptlet>
115
	            <span class="regtext">
116
	                You must be logged into your user account before deleting a data set.
117
	            </span>
118
            <jsp:scriptlet>
119
                }
120
            </jsp:scriptlet>
121
            
122
            <p class="regtext">
123
                <form action="SaeonLogin.jspx">
124
                    <input name="action" type="submit" value="Back" class="button_login"/>
125
                </form>
126
            </p>
127
            
128
            <br/>DEBUG<br/>
129
            action = <jsp:getProperty name="clientViewBean" property="action"/><br/>
130
            qformat = <jsp:getProperty name="clientViewBean" property="qformat"/><br/>
131
            anyfield = <jsp:getProperty name="clientViewBean" property="anyfield"/><br/>
132
            username = <jsp:getProperty name="clientViewBean" property="username"/><br/>
133
            organization = <jsp:getProperty name="clientViewBean" property="organization"/><br/>
134
        </body>
135
    </html>
136
    
137
</jsp:root>
(2-2/33)