diff --git a/ccm-cms/src/com/arsdigita/cms/Loader.java b/ccm-cms/src/com/arsdigita/cms/Loader.java index f8ce22a49..786080b8d 100755 --- a/ccm-cms/src/com/arsdigita/cms/Loader.java +++ b/ccm-cms/src/com/arsdigita/cms/Loader.java @@ -21,7 +21,9 @@ package com.arsdigita.cms; import com.arsdigita.cms.contentsection.ContentSectionSetup; import com.arsdigita.cms.util.Util; import com.arsdigita.cms.installer.xml.XMLContentTypeHandler; +import com.arsdigita.cms.portlet.ContentDirectoryPortlet; import com.arsdigita.cms.portlet.ContentItemPortlet; +import com.arsdigita.cms.portlet.ContentSectionsPortlet; import com.arsdigita.cms.portlet.TaskPortlet; import com.arsdigita.domain.DomainObject; import com.arsdigita.domain.DataObjectNotFoundException; @@ -195,9 +197,9 @@ public class Loader extends PackageLoader { // Loading CMS portlets // Used to be step 7 (last step) in former enterprise.init s_log.debug("CMS.loader going to load portlets"); - //ContentDirectoryPortlet.loadPortletType(); + ContentDirectoryPortlet.loadPortletType(); ContentItemPortlet.loadPortletType(); - //ContentSectionsPortlet.loadPortletType(); + ContentSectionsPortlet.loadPortletType(); TaskPortlet.loadPortletType(); // Loading forms widget into database diff --git a/ccm-cms/src/com/arsdigita/cms/portlet/ContentDirectoryPortlet.java b/ccm-cms/src/com/arsdigita/cms/portlet/ContentDirectoryPortlet.java index a0001fb93..fdd2ccd1a 100755 --- a/ccm-cms/src/com/arsdigita/cms/portlet/ContentDirectoryPortlet.java +++ b/ccm-cms/src/com/arsdigita/cms/portlet/ContentDirectoryPortlet.java @@ -69,10 +69,10 @@ public class ContentDirectoryPortlet extends Portlet { public static void loadPortletType() { PortletType type = PortletType - .createPortletType("Content Directory", + .createPortletType("CMS Content Directory", PortletType.WIDE_PROFILE, ContentDirectoryPortlet.BASE_DATA_OBJECT_TYPE); - type.setDescription("Displays the content directory categories"); + type.setDescription("Displays the CMS content directory categories"); s_log.info("Loading portlet type " + type); } @@ -89,6 +89,7 @@ public class ContentDirectoryPortlet extends Portlet { DomainObjectFactory.registerInstantiator(BASE_DATA_OBJECT_TYPE, new ACSObjectInstantiator() { + @Override public DomainObject doNewInstance(DataObject dataObject) { return new ContentDirectoryPortlet(dataObject); diff --git a/ccm-cms/src/com/arsdigita/cms/portlet/ContentSectionsPortlet.java b/ccm-cms/src/com/arsdigita/cms/portlet/ContentSectionsPortlet.java index 031da4778..a7e413bfa 100755 --- a/ccm-cms/src/com/arsdigita/cms/portlet/ContentSectionsPortlet.java +++ b/ccm-cms/src/com/arsdigita/cms/portlet/ContentSectionsPortlet.java @@ -52,6 +52,7 @@ public class ContentSectionsPortlet extends Portlet { * Retrieve the base data object type (i.e. fully qualified class name). * @return */ + @Override protected String getBaseDataObjectType() { return BASE_DATA_OBJECT_TYPE; } @@ -60,6 +61,7 @@ public class ContentSectionsPortlet extends Portlet { * * @return */ + @Override protected AbstractPortletRenderer doGetPortletRenderer() { return new ContentSectionsPortletRenderer(this); } @@ -95,6 +97,7 @@ public class ContentSectionsPortlet extends Portlet { DomainObjectFactory.registerInstantiator(BASE_DATA_OBJECT_TYPE, new ACSObjectInstantiator() { + @Override public DomainObject doNewInstance(DataObject dataObject) { return new ContentItemPortlet(dataObject); @@ -118,6 +121,7 @@ public class ContentSectionsPortlet extends Portlet { setup.setProfile(PortletType.WIDE_PROFILE); setup.setInstantiator(new ACSObjectInstantiator() { + @Override protected DomainObject doNewInstance(DataObject dataObject) { return new ContentSectionsPortlet(dataObject); } diff --git a/ccm-cms/src/com/arsdigita/cms/portlet/Initializer.java b/ccm-cms/src/com/arsdigita/cms/portlet/Initializer.java index f4b0e1465..bef1cc7ce 100644 --- a/ccm-cms/src/com/arsdigita/cms/portlet/Initializer.java +++ b/ccm-cms/src/com/arsdigita/cms/portlet/Initializer.java @@ -75,14 +75,14 @@ public class Initializer extends CompoundInitializer { // ContentDirectoryPortlet, currently not used. // Portlet of the same name is active in ccm-ldn-portal - //loadContentDirectoryPortlet(); - //ContentDirectoryPortlet.initPortlet(); + // ContentDirectoryPortlet(); + ContentDirectoryPortlet.initPortlet(); // ContentItemPortlet ContentItemPortlet.initPortlet(); // ContentSectionsPortlet - //ContentSectionsPortlet.initPortlet(); + ContentSectionsPortlet.initPortlet(); // TaskPortlet TaskPortlet.initPortlet(); diff --git a/ccm-cms/src/com/arsdigita/cms/ui/portlet/ContentDirectoryPortletRenderer.java b/ccm-cms/src/com/arsdigita/cms/ui/portlet/ContentDirectoryPortletRenderer.java index 576dfdb0d..c54d34c9d 100755 --- a/ccm-cms/src/com/arsdigita/cms/ui/portlet/ContentDirectoryPortletRenderer.java +++ b/ccm-cms/src/com/arsdigita/cms/ui/portlet/ContentDirectoryPortletRenderer.java @@ -49,7 +49,8 @@ public class ContentDirectoryPortletRenderer extends AbstractPortletRenderer { element.addAttribute("id",getIdAttr()); DataQuery categories = SessionManager.getSession().retrieveQuery - ("com.arsdigita.london.portal.portlet.getContentDirectory"); + ("com.arsdigita.portal.portlet.getContentDirectory"); +// ("com.arsdigita.london.portal.portlet.getContentDirectory"); while (categories.next()) { BigDecimal categoryID = (BigDecimal) categories.get("categoryID"); diff --git a/ccm-cms/src/com/arsdigita/cms/ui/portlet/ContentItemPortletRenderer.java b/ccm-cms/src/com/arsdigita/cms/ui/portlet/ContentItemPortletRenderer.java index bd5c0189c..6916bf395 100755 --- a/ccm-cms/src/com/arsdigita/cms/ui/portlet/ContentItemPortletRenderer.java +++ b/ccm-cms/src/com/arsdigita/cms/ui/portlet/ContentItemPortletRenderer.java @@ -103,6 +103,7 @@ public class ContentItemPortletRenderer extends AbstractPortletRenderer { SimpleXMLGenerator.ADAPTER_CONTEXT); } + @Override public String getCacheKey(PageState state) { ContentItem item = m_portlet.getContentItem(); if( null == item ) { @@ -119,6 +120,7 @@ public class ContentItemPortletRenderer extends AbstractPortletRenderer { // For a given cache key a contnet item is *never* dirty, // since upon republishing of a live item, the item_id // changes! + @Override public boolean isDirty(PageState state) { return false; } diff --git a/ccm-cms/src/com/arsdigita/cms/ui/portlet/TaskPortletRenderer.java b/ccm-cms/src/com/arsdigita/cms/ui/portlet/TaskPortletRenderer.java index b17c0114c..c85e2bc2b 100755 --- a/ccm-cms/src/com/arsdigita/cms/ui/portlet/TaskPortletRenderer.java +++ b/ccm-cms/src/com/arsdigita/cms/ui/portlet/TaskPortletRenderer.java @@ -36,7 +36,7 @@ import com.arsdigita.workflow.simple.Engine; import com.arsdigita.xml.Element; import org.apache.log4j.Logger; -import java.util.ArrayList; +// import java.util.ArrayList; import java.util.Date; import java.util.Iterator; import java.util.List; diff --git a/ccm-core/src/com/arsdigita/portal/Portlet.java b/ccm-core/src/com/arsdigita/portal/Portlet.java index 1a331a26b..9b2bb87fc 100755 --- a/ccm-core/src/com/arsdigita/portal/Portlet.java +++ b/ccm-core/src/com/arsdigita/portal/Portlet.java @@ -64,6 +64,7 @@ public class Portlet extends Resource { "com.arsdigita.portal.Portlet"; private static Logger s_log = Logger.getLogger(Portlet.class); + @Override protected String getBaseDataObjectType() { return BASE_DATA_OBJECT_TYPE; } diff --git a/ccm-forum/src/com/arsdigita/forum/Initializer.java b/ccm-forum/src/com/arsdigita/forum/Initializer.java index e016c1e06..d50796a1d 100755 --- a/ccm-forum/src/com/arsdigita/forum/Initializer.java +++ b/ccm-forum/src/com/arsdigita/forum/Initializer.java @@ -43,7 +43,6 @@ import com.arsdigita.runtime.CompoundInitializer; import com.arsdigita.runtime.ContextInitEvent; import com.arsdigita.runtime.ContextCloseEvent; import com.arsdigita.runtime.DomainInitEvent; -// import com.arsdigita.runtime.LegacyInitEvent; import com.arsdigita.runtime.PDLInitializer; import com.arsdigita.runtime.RuntimeConfig; import com.arsdigita.search.MetadataProviderRegistry; @@ -77,12 +76,14 @@ public class Initializer extends CompoundInitializer { * * @param e */ + @Override public void init(DomainInitEvent e) { super.init(e); e.getFactory().registerInstantiator( Forum.BASE_DATA_OBJECT_TYPE, new ACSObjectInstantiator() { + @Override public DomainObject doNewInstance(DataObject dataObject) { return new Forum(dataObject); } @@ -90,6 +91,7 @@ public class Initializer extends CompoundInitializer { e.getFactory().registerInstantiator( Post.BASE_DATA_OBJECT_TYPE, new ACSObjectInstantiator() { + @Override public DomainObject doNewInstance(DataObject dataObject) { return new Post(dataObject); } @@ -98,6 +100,7 @@ public class Initializer extends CompoundInitializer { e.getFactory().registerInstantiator( PostFileAttachment.BASE_DATA_OBJECT_TYPE, new ACSObjectInstantiator() { + @Override protected DomainObject doNewInstance(DataObject dataObject) { return new PostFileAttachment(dataObject); } @@ -137,6 +140,7 @@ public class Initializer extends CompoundInitializer { e.getFactory().registerInstantiator( ForumSubscription.BASE_DATA_OBJECT_TYPE, new ACSObjectInstantiator() { + @Override public DomainObject doNewInstance(DataObject dataObject) { if (((Boolean)dataObject.get("isModerationAlert")) .booleanValue()) { @@ -162,6 +166,7 @@ public class Initializer extends CompoundInitializer { new PostFileAttachmentURLFinder()); new ResourceTypeConfig(RecentPostingsPortlet.BASE_DATA_OBJECT_TYPE) { + @Override public ResourceConfigFormSection getCreateFormSection (final ResourceType resType, final RequestLocal parentAppRL) { final ResourceConfigFormSection config = diff --git a/ccm-ldn-aplaws/src/com/arsdigita/aplaws/Loader.java b/ccm-ldn-aplaws/src/com/arsdigita/aplaws/Loader.java index 18165d477..b5c7fea67 100755 --- a/ccm-ldn-aplaws/src/com/arsdigita/aplaws/Loader.java +++ b/ccm-ldn-aplaws/src/com/arsdigita/aplaws/Loader.java @@ -42,8 +42,8 @@ import com.arsdigita.london.navigation.Template; import com.arsdigita.london.navigation.TemplateMapping; import com.arsdigita.london.terms.Domain; import com.arsdigita.london.terms.importer.Parser; -import com.arsdigita.london.portal.PageLayout; -import com.arsdigita.london.portal.Workspace; +import com.arsdigita.portalworkspace.PageLayout; +import com.arsdigita.portalworkspace.Workspace; import java.net.URL; import java.net.MalformedURLException; diff --git a/ccm-ldn-aplaws/src/com/arsdigita/aplaws/ui/CategoryPortalSelectionModel.java b/ccm-ldn-aplaws/src/com/arsdigita/aplaws/ui/CategoryPortalSelectionModel.java index df6e2aec4..5aecfcebe 100755 --- a/ccm-ldn-aplaws/src/com/arsdigita/aplaws/ui/CategoryPortalSelectionModel.java +++ b/ccm-ldn-aplaws/src/com/arsdigita/aplaws/ui/CategoryPortalSelectionModel.java @@ -30,8 +30,8 @@ import com.arsdigita.categorization.Category; import com.arsdigita.util.Assert; import com.arsdigita.bebop.PageState; -import com.arsdigita.london.portal.Workspace; -import com.arsdigita.london.portal.ui.WorkspaceSelectionModel; +import com.arsdigita.portalworkspace.Workspace; +import com.arsdigita.portalworkspace.ui.WorkspaceSelectionModel; public class CategoryPortalSelectionModel extends WorkspaceSelectionModel { diff --git a/ccm-ldn-aplaws/src/com/arsdigita/aplaws/ui/HomepagePortalSelectionModel.java b/ccm-ldn-aplaws/src/com/arsdigita/aplaws/ui/HomepagePortalSelectionModel.java index 5de5558c4..5bc195c75 100755 --- a/ccm-ldn-aplaws/src/com/arsdigita/aplaws/ui/HomepagePortalSelectionModel.java +++ b/ccm-ldn-aplaws/src/com/arsdigita/aplaws/ui/HomepagePortalSelectionModel.java @@ -16,8 +16,8 @@ package com.arsdigita.aplaws.ui; import com.arsdigita.bebop.AbstractSingleSelectionModel; -import com.arsdigita.london.portal.ui.PortalSelectionModel; -import com.arsdigita.london.portal.WorkspacePage; +import com.arsdigita.portalworkspace.ui.PortalSelectionModel; +import com.arsdigita.portalworkspace.WorkspacePage; import com.arsdigita.bebop.PageState; import com.arsdigita.bebop.parameters.ParameterModel; import com.arsdigita.domain.DomainObject; diff --git a/ccm-ldn-aplaws/src/com/arsdigita/aplaws/ui/HomepageWorkspace.java b/ccm-ldn-aplaws/src/com/arsdigita/aplaws/ui/HomepageWorkspace.java index fa3836d0f..26581a44c 100755 --- a/ccm-ldn-aplaws/src/com/arsdigita/aplaws/ui/HomepageWorkspace.java +++ b/ccm-ldn-aplaws/src/com/arsdigita/aplaws/ui/HomepageWorkspace.java @@ -26,9 +26,9 @@ import com.arsdigita.kernel.permissions.PermissionDescriptor; import com.arsdigita.kernel.permissions.PrivilegeDescriptor; import com.arsdigita.kernel.Party; import com.arsdigita.kernel.Kernel; -import com.arsdigita.london.portal.ui.PersistentPortal; -import com.arsdigita.london.portal.ui.PortalConstants; -import com.arsdigita.london.portal.Workspace; +import com.arsdigita.portalworkspace.ui.PersistentPortal; +import com.arsdigita.portalworkspace.ui.PortalConstants; +import com.arsdigita.portalworkspace.Workspace; import com.arsdigita.xml.Element; diff --git a/ccm-ldn-aplaws/src/com/arsdigita/aplaws/ui/HomepageWorkspaceSelectionModel.java b/ccm-ldn-aplaws/src/com/arsdigita/aplaws/ui/HomepageWorkspaceSelectionModel.java index 4d461837c..a3d439d50 100755 --- a/ccm-ldn-aplaws/src/com/arsdigita/aplaws/ui/HomepageWorkspaceSelectionModel.java +++ b/ccm-ldn-aplaws/src/com/arsdigita/aplaws/ui/HomepageWorkspaceSelectionModel.java @@ -27,9 +27,9 @@ import com.arsdigita.kernel.permissions.PermissionService; import com.arsdigita.kernel.permissions.PermissionDescriptor; import com.arsdigita.kernel.permissions.PrivilegeDescriptor; -import com.arsdigita.london.portal.Workspace; -import com.arsdigita.london.portal.WorkspacePage; -import com.arsdigita.london.portal.WorkspacePageCollection; +import com.arsdigita.portalworkspace.Workspace; +import com.arsdigita.portalworkspace.WorkspacePage; +import com.arsdigita.portalworkspace.WorkspacePageCollection; import com.arsdigita.london.subsite.Subsite; diff --git a/ccm-ldn-navigation/sql/ccm-ldn-navigation/postgres/upgrade/6.6.0-6.6.1/upd_application_tables.sql b/ccm-ldn-navigation/sql/ccm-ldn-navigation/postgres/upgrade/6.6.0-6.6.1/upd_application_tables.sql index 173a30743..9f36ee892 100644 --- a/ccm-ldn-navigation/sql/ccm-ldn-navigation/postgres/upgrade/6.6.0-6.6.1/upd_application_tables.sql +++ b/ccm-ldn-navigation/sql/ccm-ldn-navigation/postgres/upgrade/6.6.0-6.6.1/upd_application_tables.sql @@ -20,6 +20,9 @@ -- NavigationTreePortlet has been moved from ccm-ldn-portal (where it existed as -- NavigationDirectoryPortlet) to ccm-ldn-navigation because it depends on -- navigation and was misplaced there (generating horizontal dependencies). +-- At the time of this update both ccm-ldn-portal and ccm-ldn-navigation must +-- be installed because of those horizontal dependencies. So existence of +-- ccm-ldn-navigatgion can be taken granted for now. update application_types @@ -30,3 +33,10 @@ update application_types where object_type like 'com.arsdigita.london.portal.portlet.NavigationDirectoryPortlet' ; +update applications + set (title,description) = + ('Navigation Tree', + 'Displays a tree of navigation categories' ) + where title + like 'Navigation Directory' ; + diff --git a/ccm-ldn-navigation/src/com/arsdigita/london/navigation/Initializer.java b/ccm-ldn-navigation/src/com/arsdigita/london/navigation/Initializer.java index a745eb1d2..b83797e68 100755 --- a/ccm-ldn-navigation/src/com/arsdigita/london/navigation/Initializer.java +++ b/ccm-ldn-navigation/src/com/arsdigita/london/navigation/Initializer.java @@ -74,8 +74,6 @@ import java.util.List; import org.apache.log4j.Logger; -// same package -// import com.arsdigita.london.navigation.Template; import com.arsdigita.domain.xml.TraversalHandler; import com.arsdigita.xml.XML; @@ -125,6 +123,7 @@ public class Initializer extends CompoundInitializer { public DomainObject doNewInstance(DataObject dataObject) { return new Template(dataObject); } + @Override public DomainObjectInstantiator resolveInstantiator(DataObject obj) { return this; @@ -134,6 +133,7 @@ public class Initializer extends CompoundInitializer { e.getFactory().registerInstantiator (Navigation.BASE_DATA_OBJECT_TYPE, new ACSObjectInstantiator() { + @Override public DomainObject doNewInstance(DataObject dataObject) { return new Navigation(dataObject); } @@ -145,6 +145,7 @@ public class Initializer extends CompoundInitializer { e.getFactory().registerInstantiator (ItemListPortlet.BASE_DATA_OBJECT_TYPE, new ACSObjectInstantiator() { + @Override public DomainObject doNewInstance(DataObject dataObject) { return new ItemListPortlet(dataObject); } @@ -153,6 +154,7 @@ public class Initializer extends CompoundInitializer { e.getFactory().registerInstantiator (ObjectListPortlet.BASE_DATA_OBJECT_TYPE, new ACSObjectInstantiator() { + @Override public DomainObject doNewInstance(DataObject dataObject) { return new ObjectListPortlet(dataObject); } @@ -164,6 +166,7 @@ public class Initializer extends CompoundInitializer { public DomainObject doNewInstance(DataObject dataObject) { return new TemplateMapping(dataObject); } + @Override public DomainObjectInstantiator resolveInstantiator(DataObject obj) { return this; @@ -173,6 +176,7 @@ public class Initializer extends CompoundInitializer { new ResourceTypeConfig(ObjectListPortlet.BASE_DATA_OBJECT_TYPE) { + @Override public ResourceConfigFormSection getCreateFormSection (final ResourceType resType, final RequestLocal parentAppRL) { final ResourceConfigFormSection config = @@ -181,6 +185,7 @@ public class Initializer extends CompoundInitializer { return config; } + @Override public ResourceConfigFormSection getModifyFormSection (final RequestLocal application) { final ObjectListPortletEditor config = @@ -191,6 +196,7 @@ public class Initializer extends CompoundInitializer { }; new ResourceTypeConfig(ItemListPortlet.BASE_DATA_OBJECT_TYPE) { + @Override public ResourceConfigFormSection getCreateFormSection (final ResourceType resType, final RequestLocal parentAppRL) { final ResourceConfigFormSection config = @@ -199,6 +205,7 @@ public class Initializer extends CompoundInitializer { return config; } + @Override public ResourceConfigFormSection getModifyFormSection (final RequestLocal application) { final ItemListPortletEditor config = diff --git a/ccm-ldn-navigation/src/com/arsdigita/london/navigation/portlet/NavigationTreePortlet.java b/ccm-ldn-navigation/src/com/arsdigita/london/navigation/portlet/NavigationTreePortlet.java index 76e372a18..e83727225 100644 --- a/ccm-ldn-navigation/src/com/arsdigita/london/navigation/portlet/NavigationTreePortlet.java +++ b/ccm-ldn-navigation/src/com/arsdigita/london/navigation/portlet/NavigationTreePortlet.java @@ -93,8 +93,9 @@ public class NavigationTreePortlet extends Portlet { new ResourceTypeConfig(BASE_DATA_OBJECT_TYPE) { - public ResourceConfigFormSection getCreateFormSection(final ResourceType resType, - final RequestLocal parentAppRL) + public ResourceConfigFormSection getCreateFormSection( + final ResourceType resType, + final RequestLocal parentAppRL) { return new NavigationTreePortletEditor(resType, parentAppRL); } diff --git a/ccm-webpage/src/com/arsdigita/cms/webpage/ui/WebpagePortlet.java b/ccm-webpage/src/com/arsdigita/cms/webpage/ui/WebpagePortlet.java index 7c3a34816..b1cef64ce 100755 --- a/ccm-webpage/src/com/arsdigita/cms/webpage/ui/WebpagePortlet.java +++ b/ccm-webpage/src/com/arsdigita/cms/webpage/ui/WebpagePortlet.java @@ -29,7 +29,7 @@ import com.arsdigita.kernel.User; import com.arsdigita.kernel.permissions.PermissionDescriptor; import com.arsdigita.kernel.permissions.PermissionService; import com.arsdigita.kernel.permissions.PrivilegeDescriptor; -import com.arsdigita.london.portal.WorkspacePage; +import com.arsdigita.portalworkspace.WorkspacePage; import com.arsdigita.london.util.UrlUtil; import com.arsdigita.persistence.DataObject; import com.arsdigita.portal.Portal;