portals-jetspeed-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From woon...@apache.org
Subject svn commit: r772284 - /portals/jetspeed-2/applications/j2-admin/trunk/src/main/java/org/apache/jetspeed/portlets/prm/portlet/DetailsPanel.java
Date Wed, 06 May 2009 14:42:16 GMT
Author: woonsan
Date: Wed May  6 14:42:16 2009
New Revision: 772284

URL: http://svn.apache.org/viewvc?rev=772284&view=rev
Log:
JS2-990: removes non-serializable member.

Modified:
    portals/jetspeed-2/applications/j2-admin/trunk/src/main/java/org/apache/jetspeed/portlets/prm/portlet/DetailsPanel.java

Modified: portals/jetspeed-2/applications/j2-admin/trunk/src/main/java/org/apache/jetspeed/portlets/prm/portlet/DetailsPanel.java
URL: http://svn.apache.org/viewvc/portals/jetspeed-2/applications/j2-admin/trunk/src/main/java/org/apache/jetspeed/portlets/prm/portlet/DetailsPanel.java?rev=772284&r1=772283&r2=772284&view=diff
==============================================================================
--- portals/jetspeed-2/applications/j2-admin/trunk/src/main/java/org/apache/jetspeed/portlets/prm/portlet/DetailsPanel.java
(original)
+++ portals/jetspeed-2/applications/j2-admin/trunk/src/main/java/org/apache/jetspeed/portlets/prm/portlet/DetailsPanel.java
Wed May  6 14:42:16 2009
@@ -197,7 +197,7 @@
             }
         });
 
-        CloneForm cloneForm = new CloneForm("cloneForm", definition);
+        CloneForm cloneForm = new CloneForm("cloneForm");
         add(cloneForm);                
         
         add(form);
@@ -219,7 +219,7 @@
         
         private String cloneName;
 
-        public CloneForm(String name, final PortletDefinition portlet)
+        public CloneForm(String name)
         {
             super(name);
             add(new TextField("cloneName", new PropertyModel(this, "cloneName")));      
 
@@ -231,15 +231,18 @@
                     try
                     {
                         String cloneName = getCloneName();
+                        
                         if (!StringUtils.isBlank(cloneName))
                         {
                             PortletRegistry registry = ((AbstractAdminWebApplication) getApplication()).getServiceLocator().getPortletRegistry();
-                            registry.clonePortletDefinition(portlet, cloneName);
+                            PortletApplication app = registry.getPortletApplication(paNodeBean.getApplicationName());
+                            PortletDefinition def = app.getPortlet(paNodeBean.getName());
+                            registry.clonePortletDefinition(def, cloneName);
                         }
                     }
                     catch (RegistryException e)
                     {
-                        logger.error("Failed to update jetspeed security constraint defs
of application.", e);
+                        logger.error("Failed to clone portlet definition.", e);
                     }
                 }
             });



---------------------------------------------------------------------
To unsubscribe, e-mail: jetspeed-dev-unsubscribe@portals.apache.org
For additional commands, e-mail: jetspeed-dev-help@portals.apache.org


Mime
View raw message