Author: chathura
Date: Wed Dec 5 03:12:38 2007
New Revision: 10542
Log:
Added navigatable path to the UI.
Modified:
trunk/registry/modules/webapps/src/main/java/org/wso2/registry/web/actions/CollectionViewAction.java
trunk/registry/modules/webapps/src/main/java/org/wso2/registry/web/actions/ResourceDetailsAction.java
trunk/registry/modules/webapps/src/main/webapp/admin/registry-resources.jsp
Modified:
trunk/registry/modules/webapps/src/main/java/org/wso2/registry/web/actions/CollectionViewAction.java
==============================================================================
---
trunk/registry/modules/webapps/src/main/java/org/wso2/registry/web/actions/CollectionViewAction.java
(original)
+++
trunk/registry/modules/webapps/src/main/java/org/wso2/registry/web/actions/CollectionViewAction.java
Wed Dec 5 03:12:38 2007
@@ -54,7 +54,7 @@
if (path.equals(RegistryConstants.ROOT_PATH)) {
ResourcePath resourcePath = new ResourcePath();
- resourcePath.setNavigateName("IN_ROOT");
+ resourcePath.setNavigateName("root");
resourcePath.setNavigatePath("#");
navigatablePaths.add(resourcePath);
@@ -63,7 +63,7 @@
// first add the root path
ResourcePath rootPath = new ResourcePath();
- rootPath.setNavigateName("Root");
+ rootPath.setNavigateName("root");
rootPath.setNavigatePath(RegistryConstants.ROOT_PATH);
navigatablePaths.add(rootPath);
Modified:
trunk/registry/modules/webapps/src/main/java/org/wso2/registry/web/actions/ResourceDetailsAction.java
==============================================================================
---
trunk/registry/modules/webapps/src/main/java/org/wso2/registry/web/actions/ResourceDetailsAction.java
(original)
+++
trunk/registry/modules/webapps/src/main/java/org/wso2/registry/web/actions/ResourceDetailsAction.java
Wed Dec 5 03:12:38 2007
@@ -32,6 +32,7 @@
private String relativePath;
private String name;
private String author;
+ private String lastUpdater;
private String description;
private Date createdOn;
private Date lastModified;
@@ -100,6 +101,7 @@
this.path = resource.getPath();
this.createdOn = resource.getCreatedTime();
this.lastModified = resource.getLastModified();
+ this.lastUpdater = resource.getLastUpdaterUserName();
this.mediaType = resource.getMediaType();
this.averageRating = registry.getAverageRating(resource.getPath());
@@ -316,6 +318,14 @@
this.author = author;
}
+ public String getLastUpdater() {
+ return lastUpdater;
+ }
+
+ public void setLastUpdater(String lastUpdater) {
+ this.lastUpdater = lastUpdater;
+ }
+
public String getDescription() {
return description;
}
Modified:
trunk/registry/modules/webapps/src/main/webapp/admin/registry-resources.jsp
==============================================================================
--- trunk/registry/modules/webapps/src/main/webapp/admin/registry-resources.jsp
(original)
+++ trunk/registry/modules/webapps/src/main/webapp/admin/registry-resources.jsp
Wed Dec 5 03:12:38 2007
@@ -6,6 +6,7 @@
<%@ page import="org.wso2.registry.web.actions.utils.VersionPath" %>
<%@ page import="org.wso2.registry.Tag" %>
<%@ page import="org.wso2.registry.Comment" %>
+<%@ page import="org.wso2.registry.web.actions.utils.ResourcePath" %>
<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN"
"http://www.w3.org/TR/html4/strict.dtd">
@@ -31,7 +32,15 @@
<! START body content -->
<div class="content">
<h1 class="headding-registryResources">Registry Resources</h1>
-<div class="breadcrumb"><a href="registry-resources.html">root</a> > WSAS</div>
+<div class="breadcrumb">
+ <%
+ Iterator iNavPaths = collection.getNavigatablePaths().iterator();
+ while (iNavPaths.hasNext()) {
+ ResourcePath resourcePath = (ResourcePath) iNavPaths.next();
+ %>
+ / <a
href="/wso2registry/web<%=resourcePath.getNavigatePath()%>"><%=resourcePath.getNavigateName()%></a>
+ <% } %>
+</div>
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td style="width:700px;" valign="top">
@@ -44,7 +53,7 @@
<td><strong>Created:
</strong><%=details.getCreatedOn().toString()%><strong> Author:
</strong><%=details.getAuthor()%></td><td align="right"><div
id="ratingDiv">Rating...</div></td>
</tr>
<tr>
- <td><strong>Last Updated: </strong>11/26/07 2:35:33 PM.046
<strong>By:</strong> Chanaka</td><td align="right">Avarage User Rating:</td>
+ <td><strong>Last Updated:
</strong><%=details.getLastModified().toString()%><strong>
By:</strong><%=details.getLastUpdater()%></td><td align="right">Avarage User
Rating:</td>
</tr>
</table>
</div>
_______________________________________________
Registry-dev mailing list
[email protected]
http://wso2.org/cgi-bin/mailman/listinfo/registry-dev