JBoss Portal SVN: r6635 - in trunk: core/src/resources/portal-core-sar/conf/identity and 2 other directories.
by portal-commits@lists.jboss.org
Author: bdaw
Date: 2007-03-12 08:58:18 -0400 (Mon, 12 Mar 2007)
New Revision: 6635
Added:
trunk/identity/src/resources/dtd/identity-config_2_6.dtd
trunk/identity/src/resources/dtd/profile-config_2_6.dtd
Removed:
trunk/identity/src/resources/dtd/identity-config_1_0.dtd
trunk/identity/src/resources/dtd/profile-config_1_0.dtd
Modified:
trunk/core/build.xml
trunk/core/src/resources/portal-core-sar/conf/identity/identity-config.xml
trunk/core/src/resources/portal-core-sar/conf/identity/profile-config.xml
trunk/core/src/resources/portal-core-sar/conf/identity/standardidentity-config.xml
trunk/identity/src/resources/example/portal-sample-local.ldif
Log:
- correct and plug in identity dtd files
Modified: trunk/core/build.xml
===================================================================
--- trunk/core/build.xml 2007-03-12 12:24:31 UTC (rev 6634)
+++ trunk/core/build.xml 2007-03-12 12:58:18 UTC (rev 6635)
@@ -344,6 +344,12 @@
<fileset dir="${facelets.facelets.lib}" includes="jsf-facelets.jar"/>
<fileset dir="${el.el.lib}" includes="el-api.jar,el-ri.jar"/>
</copy>
+
+ <!--dtd-->
+ <copy todir="${build.resources}/jboss-portal/dtd">
+ <fileset dir="${jboss.portal-identity.root}/resources/dtd" includes="*.dtd"/>
+ </copy>
+
</target>
Modified: trunk/core/src/resources/portal-core-sar/conf/identity/identity-config.xml
===================================================================
--- trunk/core/src/resources/portal-core-sar/conf/identity/identity-config.xml 2007-03-12 12:24:31 UTC (rev 6634)
+++ trunk/core/src/resources/portal-core-sar/conf/identity/identity-config.xml 2007-03-12 12:58:18 UTC (rev 6635)
@@ -22,9 +22,9 @@
~ 02110-1301 USA, or see the FSF site: http://www.fsf.org. ~
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~-->
- <!--<!DOCTYPE identity-configuration PUBLIC
+ <!DOCTYPE identity-configuration PUBLIC
"-//JBoss Portal//DTD JBoss Identity Configuration 1.0//EN"
- "http://www.jboss.org/portal/dtd/identity-config_1_0.dtd">-->
+ "http://www.jboss.org/portal/dtd/identity-config_2_6.dtd">
<identity-configuration>
<datasources/>
Modified: trunk/core/src/resources/portal-core-sar/conf/identity/profile-config.xml
===================================================================
--- trunk/core/src/resources/portal-core-sar/conf/identity/profile-config.xml 2007-03-12 12:24:31 UTC (rev 6634)
+++ trunk/core/src/resources/portal-core-sar/conf/identity/profile-config.xml 2007-03-12 12:58:18 UTC (rev 6635)
@@ -22,9 +22,9 @@
~ 02110-1301 USA, or see the FSF site: http://www.fsf.org. ~
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~-->
- <!--<!DOCTYPE profile PUBLIC
+ <!DOCTYPE profile PUBLIC
"-//JBoss Portal//DTD JBoss User Profile Configuration 1.0//EN"
- "http://www.jboss.org/portal/dtd/profile-config_1_0.dtd">-->
+ "http://www.jboss.org/portal/dtd/profile-config_2_6.dtd">
<profile>
<!--Database mapping - jbp_user table column mapping-->
Modified: trunk/core/src/resources/portal-core-sar/conf/identity/standardidentity-config.xml
===================================================================
--- trunk/core/src/resources/portal-core-sar/conf/identity/standardidentity-config.xml 2007-03-12 12:24:31 UTC (rev 6634)
+++ trunk/core/src/resources/portal-core-sar/conf/identity/standardidentity-config.xml 2007-03-12 12:58:18 UTC (rev 6635)
@@ -26,7 +26,7 @@
<!--
<!DOCTYPE identity-configuration PUBLIC
"-//JBoss Portal//DTD JBoss Identity Configuration 1.0//EN"
- "http://www.jboss.org/portal/dtd/identity-config_1_0.dtd">
+ "http://www.jboss.org/portal/dtd/identity-config_2_6.dtd">
-->
<identity-configuration>
Deleted: trunk/identity/src/resources/dtd/identity-config_1_0.dtd
===================================================================
--- trunk/identity/src/resources/dtd/identity-config_1_0.dtd 2007-03-12 12:24:31 UTC (rev 6634)
+++ trunk/identity/src/resources/dtd/identity-config_1_0.dtd 2007-03-12 12:58:18 UTC (rev 6635)
@@ -1,111 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-
-<!--~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
- ~ JBoss, a division of Red Hat ~
- ~ Copyright 2006, Red Hat Middleware, LLC, and individual ~
- ~ contributors as indicated by the @authors tag. See the ~
- ~ copyright.txt in the distribution for a full listing of ~
- ~ individual contributors. ~
- ~ ~
- ~ This is free software; you can redistribute it and/or modify it ~
- ~ under the terms of the GNU Lesser General Public License as ~
- ~ published by the Free Software Foundation; either version 2.1 of ~
- ~ the License, or (at your option) any later version. ~
- ~ ~
- ~ This software is distributed in the hope that it will be useful, ~
- ~ but WITHOUT ANY WARRANTY; without even the implied warranty of ~
- ~ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU ~
- ~ Lesser General Public License for more details. ~
- ~ ~
- ~ You should have received a copy of the GNU Lesser General Public ~
- ~ License along with this software; if not, write to the Free ~
- ~ Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA ~
- ~ 02110-1301 USA, or see the FSF site: http://www.fsf.org. ~
- ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~-->
-
-<!--
-<!DOCTYPE identity-configuration PUBLIC
- "-//JBoss Portal//DTD JBoss Identity Configuration 1.0//EN"
- "http://www.jboss.org/portal/dtd/identity-config_1_0.dtd">
--->
-
-<!--
-.
--->
-<!ELEMENT identity-configuration (datasources,modules, options) >
-
-<!--
-.
--->
-<!ELEMENT datasources (datasource*) >
-
-<!--
-.
--->
-<!ELEMENT datasource (name, service-name?, class?, config) >
-
-<!--
-.
--->
-<!ELEMENT name (#PCDATA) >
-
-<!--
-.
--->
-<!ELEMENT service-name (#PCDATA) >
-
-<!--
-.
--->
-<!ELEMENT class (#PCDATA) >
-
-<!--
-.
--->
-<!ELEMENT config (option*)>
-
-<!--
-.
--->
-<!ELEMENT option (name, value+) >
-
-<!--
-.
--->
-<!ELEMENT value (#PCDATA) >
-
-<!--
-.
--->
-<!ELEMENT modules (module*) >
-
-<!--
-.
--->
-<!ELEMENT module (type, implementation, service-name?, class?, config) >
-
-<!--
-.
--->
-<!ELEMENT type (#PCDATA) >
-
-<!--
-.
--->
-<!ELEMENT implementation (#PCDATA) >
-
-<!--
-.
--->
-<!ELEMENT options (option-group*)>
-
-<!--
-.
--->
-<!ELEMENT option-group (group-name, option+)>
-
-<!--
-.
--->
-<!ELEMENT group-name (#PCDATA) >
-
Copied: trunk/identity/src/resources/dtd/identity-config_2_6.dtd (from rev 6631, trunk/identity/src/resources/dtd/identity-config_1_0.dtd)
===================================================================
--- trunk/identity/src/resources/dtd/identity-config_2_6.dtd (rev 0)
+++ trunk/identity/src/resources/dtd/identity-config_2_6.dtd 2007-03-12 12:58:18 UTC (rev 6635)
@@ -0,0 +1,111 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+
+<!--~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+ ~ JBoss, a division of Red Hat ~
+ ~ Copyright 2006, Red Hat Middleware, LLC, and individual ~
+ ~ contributors as indicated by the @authors tag. See the ~
+ ~ copyright.txt in the distribution for a full listing of ~
+ ~ individual contributors. ~
+ ~ ~
+ ~ This is free software; you can redistribute it and/or modify it ~
+ ~ under the terms of the GNU Lesser General Public License as ~
+ ~ published by the Free Software Foundation; either version 2.1 of ~
+ ~ the License, or (at your option) any later version. ~
+ ~ ~
+ ~ This software is distributed in the hope that it will be useful, ~
+ ~ but WITHOUT ANY WARRANTY; without even the implied warranty of ~
+ ~ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU ~
+ ~ Lesser General Public License for more details. ~
+ ~ ~
+ ~ You should have received a copy of the GNU Lesser General Public ~
+ ~ License along with this software; if not, write to the Free ~
+ ~ Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA ~
+ ~ 02110-1301 USA, or see the FSF site: http://www.fsf.org. ~
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~-->
+
+<!--
+<!DOCTYPE identity-configuration PUBLIC
+ "-//JBoss Portal//DTD JBoss Identity Configuration 1.0//EN"
+ "http://www.jboss.org/portal/dtd/identity-config_2_6.dtd">
+-->
+
+<!--
+.
+-->
+<!ELEMENT identity-configuration (datasources,modules, options) >
+
+<!--
+.
+-->
+<!ELEMENT datasources (datasource*) >
+
+<!--
+.
+-->
+<!ELEMENT datasource (name, service-name?, class?, config) >
+
+<!--
+.
+-->
+<!ELEMENT name (#PCDATA) >
+
+<!--
+.
+-->
+<!ELEMENT service-name (#PCDATA) >
+
+<!--
+.
+-->
+<!ELEMENT class (#PCDATA) >
+
+<!--
+.
+-->
+<!ELEMENT config (option*)>
+
+<!--
+.
+-->
+<!ELEMENT option (name, value+) >
+
+<!--
+.
+-->
+<!ELEMENT value (#PCDATA) >
+
+<!--
+.
+-->
+<!ELEMENT modules (module*) >
+
+<!--
+.
+-->
+<!ELEMENT module (type, implementation, service-name?, class?, config) >
+
+<!--
+.
+-->
+<!ELEMENT type (#PCDATA) >
+
+<!--
+.
+-->
+<!ELEMENT implementation (#PCDATA) >
+
+<!--
+.
+-->
+<!ELEMENT options (option-group*)>
+
+<!--
+.
+-->
+<!ELEMENT option-group (group-name, option+)>
+
+<!--
+.
+-->
+<!ELEMENT group-name (#PCDATA) >
+
Deleted: trunk/identity/src/resources/dtd/profile-config_1_0.dtd
===================================================================
--- trunk/identity/src/resources/dtd/profile-config_1_0.dtd 2007-03-12 12:24:31 UTC (rev 6634)
+++ trunk/identity/src/resources/dtd/profile-config_1_0.dtd 2007-03-12 12:58:18 UTC (rev 6635)
@@ -1,122 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-
-<!--~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
- ~ JBoss, a division of Red Hat ~
- ~ Copyright 2006, Red Hat Middleware, LLC, and individual ~
- ~ contributors as indicated by the @authors tag. See the ~
- ~ copyright.txt in the distribution for a full listing of ~
- ~ individual contributors. ~
- ~ ~
- ~ This is free software; you can redistribute it and/or modify it ~
- ~ under the terms of the GNU Lesser General Public License as ~
- ~ published by the Free Software Foundation; either version 2.1 of ~
- ~ the License, or (at your option) any later version. ~
- ~ ~
- ~ This software is distributed in the hope that it will be useful, ~
- ~ but WITHOUT ANY WARRANTY; without even the implied warranty of ~
- ~ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU ~
- ~ Lesser General Public License for more details. ~
- ~ ~
- ~ You should have received a copy of the GNU Lesser General Public ~
- ~ License along with this software; if not, write to the Free ~
- ~ Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA ~
- ~ 02110-1301 USA, or see the FSF site: http://www.fsf.org. ~
- ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~-->
-
-<!--
-<!DOCTYPE profile PUBLIC
- "-//JBoss Portal//DTD JBoss User Profile Configuration 1.0//EN"
- "http://www.jboss.org/portal/dtd/profile-config_1_0.dtd">
--->
-
-
-<!--<profile>
- --><!--Database mapping - jbp_user table column mapping--><!--
- <property>
- <name>portal.user.name.given</name>
- <type>java.lang.String</type>
- <access-mode>read-write</access-mode>
- <usage>mandatory</usage>
- <display-name xml:lang="en">Name</display-name>
- <description xml:lang="en">The user name</description>
- <mapping>
- <database>
- <type>column</type>
- <value>jbp_username</value>
- </database>
- </mapping>
- </property>-->
-
-<!--
-.
--->
-<!ELEMENT profile (property+) >
-
-<!--
-.
--->
-<!ELEMENT property (name, type, access-mode, usage, display-name, description, mapping>
-
-<!--
-.
--->
-<!ELEMENT name (#PCDATA) >
-
-<!--
-.
--->
-<!ELEMENT type (#PCDATA)>
-
-<!--
-.
--->
-<!ELEMENT access-mode (#PCDATA) >
-
-<!--
-.
--->
-<!ELEMENT usage (#PCDATA) >
-
-<!--
-.
--->
-<!ELEMENT display-name (#PCDATA) >
-
-<!ATTLIST display-name
- xml:lang #PCDATA>
-
-<!--
-.
--->
-<!ELEMENT description (#PCDATA) >
-
-<!ATTLIST description
- xml:lang #PCDATA>
-<!--
-.
--->
-<!ELEMENT mapping (database?, ldap?) >
-
-<!--
-.
--->
-<!ELEMENT database (type, value) >
-
-<!--
-.
--->
-<!ELEMENT type (#PCDATA) >
-
-<!--
-.
--->
-<!ELEMENT value (#PCDATA) >
-
-<!--
-.
--->
-<!ELEMENT ldap (value) >
-
-
-
-
Copied: trunk/identity/src/resources/dtd/profile-config_2_6.dtd (from rev 6631, trunk/identity/src/resources/dtd/profile-config_1_0.dtd)
===================================================================
--- trunk/identity/src/resources/dtd/profile-config_2_6.dtd (rev 0)
+++ trunk/identity/src/resources/dtd/profile-config_2_6.dtd 2007-03-12 12:58:18 UTC (rev 6635)
@@ -0,0 +1,122 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+
+<!--~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+ ~ JBoss, a division of Red Hat ~
+ ~ Copyright 2006, Red Hat Middleware, LLC, and individual ~
+ ~ contributors as indicated by the @authors tag. See the ~
+ ~ copyright.txt in the distribution for a full listing of ~
+ ~ individual contributors. ~
+ ~ ~
+ ~ This is free software; you can redistribute it and/or modify it ~
+ ~ under the terms of the GNU Lesser General Public License as ~
+ ~ published by the Free Software Foundation; either version 2.1 of ~
+ ~ the License, or (at your option) any later version. ~
+ ~ ~
+ ~ This software is distributed in the hope that it will be useful, ~
+ ~ but WITHOUT ANY WARRANTY; without even the implied warranty of ~
+ ~ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU ~
+ ~ Lesser General Public License for more details. ~
+ ~ ~
+ ~ You should have received a copy of the GNU Lesser General Public ~
+ ~ License along with this software; if not, write to the Free ~
+ ~ Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA ~
+ ~ 02110-1301 USA, or see the FSF site: http://www.fsf.org. ~
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~-->
+
+<!--
+<!DOCTYPE profile PUBLIC
+ "-//JBoss Portal//DTD JBoss User Profile Configuration 1.0//EN"
+ "http://www.jboss.org/portal/dtd/profile-config_2_6.dtd">
+-->
+
+
+<!--<profile>
+ --><!--Database mapping - jbp_user table column mapping--><!--
+ <property>
+ <name>portal.user.name.given</name>
+ <type>java.lang.String</type>
+ <access-mode>read-write</access-mode>
+ <usage>mandatory</usage>
+ <display-name xml:lang="en">Name</display-name>
+ <description xml:lang="en">The user name</description>
+ <mapping>
+ <database>
+ <type>column</type>
+ <value>jbp_username</value>
+ </database>
+ </mapping>
+ </property>-->
+
+<!--
+.
+-->
+<!ELEMENT profile (property+) >
+
+<!--
+.
+-->
+<!ELEMENT property (name, type, access-mode, usage, display-name, description, mapping) >
+
+<!--
+.
+-->
+<!ELEMENT name (#PCDATA) >
+
+<!--
+.
+-->
+<!ELEMENT type (#PCDATA)>
+
+<!--
+.
+-->
+<!ELEMENT access-mode (#PCDATA) >
+
+<!--
+.
+-->
+<!ELEMENT usage (#PCDATA) >
+
+<!--
+.
+-->
+<!ELEMENT display-name (#PCDATA) >
+
+<!ATTLIST display-name
+ xml:lang CDATA #IMPLIED>
+
+<!--
+.
+-->
+<!ELEMENT description (#PCDATA) >
+
+<!ATTLIST description
+ xml:lang CDATA #IMPLIED>
+<!--
+.
+-->
+<!ELEMENT mapping (database?, ldap?) >
+
+<!--
+.
+-->
+<!ELEMENT database (type, value) >
+
+<!--
+.
+-->
+<!--<!ELEMENT type (#PCDATA) >-->
+
+<!--
+.
+-->
+<!ELEMENT value (#PCDATA) >
+
+<!--
+.
+-->
+<!ELEMENT ldap (value) >
+
+
+
+
Modified: trunk/identity/src/resources/example/portal-sample-local.ldif
===================================================================
--- trunk/identity/src/resources/example/portal-sample-local.ldif 2007-03-12 12:24:31 UTC (rev 6634)
+++ trunk/identity/src/resources/example/portal-sample-local.ldif 2007-03-12 12:58:18 UTC (rev 6635)
@@ -143,4 +143,4 @@
objectClass: top
cn: TheDuke
description: TheDuke role context
-member: uid=jduke,ou=People,o=test,dc=portal,dc=example,dc=com
\ No newline at end of file
+member: uid=jduke,ou=People,o=test,dc=portal,dc=example,dc=com
17 years, 7 months
JBoss Portal SVN: r6634 - trunk/core-admin/src/resources/portal-admin-war/WEB-INF/jsf.
by portal-commits@lists.jboss.org
Author: thomas.heute(a)jboss.com
Date: 2007-03-12 08:24:31 -0400 (Mon, 12 Mar 2007)
New Revision: 6634
Modified:
trunk/core-admin/src/resources/portal-admin-war/WEB-INF/jsf/editPageLayout.xhtml
Log:
* Renamed "->" to "Delete"
* Moved the delete button with other buttons action on windows (Up and Down)
Modified: trunk/core-admin/src/resources/portal-admin-war/WEB-INF/jsf/editPageLayout.xhtml
===================================================================
--- trunk/core-admin/src/resources/portal-admin-war/WEB-INF/jsf/editPageLayout.xhtml 2007-03-12 12:03:34 UTC (rev 6633)
+++ trunk/core-admin/src/resources/portal-admin-war/WEB-INF/jsf/editPageLayout.xhtml 2007-03-12 12:24:31 UTC (rev 6634)
@@ -21,12 +21,12 @@
<c:choose>
<c:when test="#{status.index > 0}">
<tr>
- <td colspan="3" class="portlet-form-field-label" style="border-width:0px;border-top:1px dashed #d5d5d5">#{regionName} Region</td>
+ <td colspan="2" class="portlet-form-field-label" style="border-width:0px;border-top:1px dashed #d5d5d5">#{regionName} Region</td>
</tr>
</c:when>
<c:otherwise>
<tr>
- <td colspan="3" class="portlet-form-field-label">#{regionName} Region</td>
+ <td colspan="2" class="portlet-form-field-label">#{regionName} Region</td>
</tr>
</c:otherwise>
</c:choose>
@@ -38,6 +38,9 @@
<div>
<h:commandButton value="Down" id="d_#{regionName}" actionListener="#{assignWindowsAction.execute}" styleClass="portlet-form-button"/>
</div>
+ <div style="margin-top: 1em">
+ <h:commandButton value="Delete" id="l_#{regionName}" actionListener="#{assignWindowsAction.execute}" styleClass="portlet-form-button"/>
+ </div>
</td>
<td>
<h:selectManyListbox
@@ -47,12 +50,7 @@
<f:selectItems value="#{portalobjectmgr.windowItemsMap[regionName]}"/>
</h:selectManyListbox>
</td>
- <td>
- <div>
- <h:commandButton value="->" id="l_#{regionName}" actionListener="#{assignWindowsAction.execute}" styleClass="portlet-form-button"/>
- </div>
- </td>
- </tr>
+ </tr>
</tbody>
</c:forEach>
</table>
17 years, 7 months
JBoss Portal SVN: r6633 - in trunk/core-admin/src: main/org/jboss/portal/core/admin/ui/wizard and 3 other directories.
by portal-commits@lists.jboss.org
Author: thomas.heute(a)jboss.com
Date: 2007-03-12 08:03:34 -0400 (Mon, 12 Mar 2007)
New Revision: 6633
Added:
trunk/core-admin/src/main/org/jboss/portal/core/admin/ui/wizard/
trunk/core-admin/src/main/org/jboss/portal/core/admin/ui/wizard/NewWindowWizard.java
trunk/core-admin/src/resources/portal-admin-war/WEB-INF/jsf/wizard/
trunk/core-admin/src/resources/portal-admin-war/WEB-INF/jsf/wizard/newWindowTpl.xhtml
trunk/core-admin/src/resources/portal-admin-war/WEB-INF/jsf/wizard/newWindowWizardConfirm.xhtml
trunk/core-admin/src/resources/portal-admin-war/WEB-INF/jsf/wizard/selectPage.xhtml
trunk/core-admin/src/resources/portal-admin-war/WEB-INF/jsf/wizard/selectPortal.xhtml
trunk/core-admin/src/resources/portal-admin-war/WEB-INF/jsf/wizard/selectPortlet.xhtml
trunk/core-admin/src/resources/portal-admin-war/WEB-INF/jsf/wizard/selectRegion.xhtml
Modified:
trunk/core-admin/src/resources/portal-admin-war/WEB-INF/faces-config.xml
trunk/core-admin/src/resources/portal-admin-war/WEB-INF/jsf/objects.xhtml
Log:
Basic wizard. Use with care.
Added: trunk/core-admin/src/main/org/jboss/portal/core/admin/ui/wizard/NewWindowWizard.java
===================================================================
--- trunk/core-admin/src/main/org/jboss/portal/core/admin/ui/wizard/NewWindowWizard.java (rev 0)
+++ trunk/core-admin/src/main/org/jboss/portal/core/admin/ui/wizard/NewWindowWizard.java 2007-03-12 12:03:34 UTC (rev 6633)
@@ -0,0 +1,358 @@
+/******************************************************************************
+ * JBoss, a division of Red Hat *
+ * Copyright 2006, Red Hat Middleware, LLC, and individual *
+ * contributors as indicated by the @authors tag. See the *
+ * copyright.txt in the distribution for a full listing of *
+ * individual contributors. *
+ * *
+ * This is free software; you can redistribute it and/or modify it *
+ * under the terms of the GNU Lesser General Public License as *
+ * published by the Free Software Foundation; either version 2.1 of *
+ * the License, or (at your option) any later version. *
+ * *
+ * This software is distributed in the hope that it will be useful, *
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of *
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU *
+ * Lesser General Public License for more details. *
+ * *
+ * You should have received a copy of the GNU Lesser General Public *
+ * License along with this software; if not, write to the Free *
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA *
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org. *
+ ******************************************************************************/
+package org.jboss.portal.core.admin.ui.wizard;
+
+import java.util.ArrayList;
+import java.util.Collection;
+import java.util.Collections;
+import java.util.List;
+import java.util.Set;
+
+import javax.faces.context.FacesContext;
+
+import org.jboss.portal.core.model.content.ContentType;
+import org.jboss.portal.core.model.instance.Instance;
+import org.jboss.portal.core.model.instance.InstanceContainer;
+import org.jboss.portal.core.model.portal.Page;
+import org.jboss.portal.core.model.portal.Portal;
+import org.jboss.portal.core.model.portal.PortalObject;
+import org.jboss.portal.core.model.portal.PortalObjectContainer;
+import org.jboss.portal.core.model.portal.PortalObjectId;
+import org.jboss.portal.core.model.portal.Window;
+import org.jboss.portal.portlet.Portlet;
+import org.jboss.portal.portlet.PortletContext;
+import org.jboss.portal.portlet.PortletInvoker;
+import org.jboss.portal.portlet.PortletInvokerException;
+import org.jboss.portal.portlet.federation.FederatingPortletInvoker;
+import org.jboss.portal.security.AuthorizationDomainRegistry;
+import org.jboss.portal.security.RoleSecurityBinding;
+import org.jboss.portal.security.SecurityConstants;
+import org.jboss.portal.security.spi.provider.DomainConfigurator;
+import org.jboss.portal.theme.LayoutService;
+import org.jboss.portal.theme.PortalLayout;
+import org.jboss.portal.theme.ThemeConstants;
+
+/**
+ * @author <a href="mailto:theute@jboss.org">Thomas Heute</a>
+ * @version $Revision$
+ */
+public class NewWindowWizard
+{
+
+ private List steps;
+ private int currentStep;
+ private FederatingPortletInvoker federatingPortletInvoker;
+ private String selectedPortletId;
+ private String selectedPortalId;
+ private String selectedPageId;
+ private String selectedRegionId;
+ private String selectedPortletInvokerId;
+ private String selectedParentPageId;
+ private PortalObjectContainer portalObjectContainer;
+ private InstanceContainer instanceContainer;
+ private LayoutService layoutService;
+ private AuthorizationDomainRegistry authorizationDomainRegistry;
+
+ public NewWindowWizard()
+ {
+ steps = new ArrayList();
+ steps.add("selectPortlet");
+ steps.add("selectPortal");
+ steps.add("selectPage");
+ steps.add("selectRegion");
+ steps.add("newWindowWizardConfirm");
+ currentStep = 0;
+ }
+
+ public String next()
+ {
+ currentStep++;
+ return (String)steps.get(currentStep);
+ }
+
+ public String previous()
+ {
+ currentStep--;
+ return (String)steps.get(currentStep);
+ }
+
+ public String selectPortlet()
+ {
+ FacesContext ctx = FacesContext.getCurrentInstance();
+ selectedPortletId = (String)ctx.getExternalContext().getRequestParameterMap().get("id");
+ selectedPortletInvokerId = (String)ctx.getExternalContext().getRequestParameterMap().get("portletInvokerId");
+ currentStep = 1;
+ return (String)steps.get(currentStep);
+ }
+
+ public String selectPortal()
+ {
+ FacesContext ctx = FacesContext.getCurrentInstance();
+ selectedPortalId = (String)ctx.getExternalContext().getRequestParameterMap().get("id");
+ currentStep = 2;
+ selectedPageId = null;
+ selectedRegionId = null;
+ return (String)steps.get(currentStep);
+ }
+
+ public String selectPage()
+ {
+ FacesContext ctx = FacesContext.getCurrentInstance();
+ selectedPageId = (String)ctx.getExternalContext().getRequestParameterMap().get("id");
+ currentStep = 3;
+ selectedRegionId = null;
+ return (String)steps.get(currentStep);
+ }
+
+ public String selectParentPage()
+ {
+ FacesContext ctx = FacesContext.getCurrentInstance();
+ selectedParentPageId = (String)ctx.getExternalContext().getRequestParameterMap().get("id");
+ currentStep = 2;
+ return (String)steps.get(currentStep);
+ }
+
+ public String selectRegion()
+ {
+ FacesContext ctx = FacesContext.getCurrentInstance();
+ selectedRegionId = (String)ctx.getExternalContext().getRequestParameterMap().get("name");
+ currentStep = 4;
+ return (String)steps.get(currentStep);
+ }
+
+ public Portlet getSelectedPortlet()
+ {
+ PortletInvoker portletInvoker = federatingPortletInvoker.getFederatedInvoker(selectedPortletInvokerId);
+ try
+ {
+ Portlet selectedPortlet = portletInvoker.getPortlet(PortletContext.createPortletContext(selectedPortletId));
+ return selectedPortlet;
+ }
+ catch (IllegalArgumentException e)
+ {
+ // TODO Auto-generated catch block
+ e.printStackTrace();
+ }
+ catch (PortletInvokerException e)
+ {
+ // TODO Auto-generated catch block
+ e.printStackTrace();
+ }
+ return null;
+ }
+
+ public Page getSelectedPage()
+ {
+ return (Page)getObjectFromId(selectedPageId);
+ }
+
+ public Page getSelectedParentPage()
+ {
+ return (Page)getObjectFromId(selectedParentPageId);
+ }
+
+ public Portal getSelectedPortal()
+ {
+ return (Portal)getObjectFromId(selectedPortalId);
+ }
+
+ public PortalObject getObjectFromId(String id)
+ {
+ PortalObjectId objectId = PortalObjectId.parse(id, PortalObjectId.LEGACY_BASE64_FORMAT);
+ return getObjectFromId(objectId);
+ }
+
+ public PortalObject getObjectFromId(PortalObjectId id)
+ {
+ return portalObjectContainer.getObject(id);
+ }
+
+ public List getPages()
+ {
+ if (selectedParentPageId != null)
+ {
+ Collection result = getSelectedParentPage().getChildren(PortalObject.PAGE_MASK);
+ if (result.size() != 0)
+ {
+ return new ArrayList(result);
+ }
+ else
+ {
+ return new ArrayList(getSelectedPage().getParent().getChildren(PortalObject.PAGE_MASK));
+ }
+ }
+ else
+ {
+ return new ArrayList(getSelectedPortal().getChildren(PortalObject.PAGE_MASK));
+ }
+ }
+
+ public String createWindow()
+ {
+ Portlet portlet = getSelectedPortlet();
+ InstanceContainer container = instanceContainer;
+ String instanceId = "wizardInstance_" + container.getDefinitions().size();
+ String windowId = "wizardWindow_" + container.getDefinitions().size();
+ try
+ {
+ if ((container.getDefinition(instanceId) == null) && (getSelectedPage().getWindow(windowId) == null))
+ {
+ Instance instance = container.createDefinition(instanceId, portlet.getContext().getId());
+
+ //
+ DomainConfigurator configurator = authorizationDomainRegistry.getDomain("instance").getConfigurator();
+ Set constraints = Collections.singleton(new RoleSecurityBinding("view", SecurityConstants.UNCHECKED_ROLE_NAME));
+ configurator.setSecurityBindings(instance.getId(), constraints);
+
+ Window window = getSelectedPage().createWindow(windowId, ContentType.PORTLET, instanceId);
+ window.setDeclaredProperty(ThemeConstants.PORTAL_PROP_REGION, getSelectedRegionId());
+ window.setDeclaredProperty(ThemeConstants.PORTAL_PROP_ORDER, "" + Integer.MAX_VALUE);
+
+ return reset();
+ }
+ }
+ catch (Exception e)
+ {
+ e.printStackTrace();
+ }
+ return null;
+ }
+
+ public String cancel()
+ {
+ return reset();
+ }
+
+ public String reset()
+ {
+ selectedPortletId = null;
+ selectedPortalId = null;
+ selectedPageId = null;
+ selectedRegionId = null;
+ selectedPortletInvokerId = null;
+ selectedParentPageId = null;
+ currentStep = 0;
+ return "index";
+ }
+
+ public List getRegions()
+ {
+ Page page = getSelectedPage();
+ String layoutId = page.getProperty(ThemeConstants.PORTAL_PROP_LAYOUT);
+ PortalLayout layout = layoutService.getLayout(layoutId, false);
+ return layout.getLayoutInfo().getRegionNames();
+ }
+
+ public String getSelectedPortletId()
+ {
+ return selectedPortletId;
+ }
+
+ public int getCurrentStep()
+ {
+ return currentStep;
+ }
+
+ public String getSelectedPortalId()
+ {
+ return selectedPortalId;
+ }
+
+ public String getSelectedPageId()
+ {
+ return selectedPageId;
+ }
+
+ public String getSelectedRegionId()
+ {
+ return selectedRegionId;
+ }
+
+ public FederatingPortletInvoker getFederatingPortletInvoker()
+ {
+ return federatingPortletInvoker;
+ }
+
+ public void setFederatingPortletInvoker(FederatingPortletInvoker federatingPortletInvoker)
+ {
+ this.federatingPortletInvoker = federatingPortletInvoker;
+ }
+
+ public PortalObjectContainer getPortalObjectContainer()
+ {
+ return portalObjectContainer;
+ }
+
+ public void setPortalObjectContainer(PortalObjectContainer portalObjectContainer)
+ {
+ this.portalObjectContainer = portalObjectContainer;
+ }
+
+ public LayoutService getLayoutService()
+ {
+ return layoutService;
+ }
+
+ public void setLayoutService(LayoutService layoutService)
+ {
+ this.layoutService = layoutService;
+ }
+
+ public InstanceContainer getInstanceContainer()
+ {
+ return instanceContainer;
+ }
+
+ public void setInstanceContainer(InstanceContainer instanceContainer)
+ {
+ this.instanceContainer = instanceContainer;
+ }
+
+ public AuthorizationDomainRegistry getAuthorizationDomainRegistry()
+ {
+ return authorizationDomainRegistry;
+ }
+
+ public void setAuthorizationDomainRegistry(AuthorizationDomainRegistry authorizationDomainRegistry)
+ {
+ this.authorizationDomainRegistry = authorizationDomainRegistry;
+ }
+
+ public boolean getNextEnabled()
+ {
+ if (currentStep == 1)
+ {
+ return (selectedPortalId != null);
+ }
+ if (currentStep == 2)
+ {
+ return (selectedPageId != null);
+ }
+ if (currentStep == 3)
+ {
+ return (selectedRegionId != null);
+ }
+ return true;
+ }
+
+}
Modified: trunk/core-admin/src/resources/portal-admin-war/WEB-INF/faces-config.xml
===================================================================
--- trunk/core-admin/src/resources/portal-admin-war/WEB-INF/faces-config.xml 2007-03-12 08:38:21 UTC (rev 6632)
+++ trunk/core-admin/src/resources/portal-admin-war/WEB-INF/faces-config.xml 2007-03-12 12:03:34 UTC (rev 6633)
@@ -167,7 +167,34 @@
<value>local</value>
</managed-property>
</managed-bean>
+
<managed-bean>
+ <managed-bean-name>newWindowWizard</managed-bean-name>
+ <managed-bean-class>org.jboss.portal.core.admin.ui.wizard.NewWindowWizard</managed-bean-class>
+ <managed-bean-scope>session</managed-bean-scope>
+ <managed-property>
+ <property-name>instanceContainer</property-name>
+ <value>#{applicationScope.InstanceContainer}</value>
+ </managed-property>
+ <managed-property>
+ <property-name>federatingPortletInvoker</property-name>
+ <value>#{applicationScope.FederatingPortletInvoker}</value>
+ </managed-property>
+ <managed-property>
+ <property-name>portalObjectContainer</property-name>
+ <value>#{applicationScope.PortalObjectContainer}</value>
+ </managed-property>
+ <managed-property>
+ <property-name>layoutService</property-name>
+ <value>#{applicationScope.LayoutService}</value>
+ </managed-property>
+ <managed-property>
+ <property-name>authorizationDomainRegistry</property-name>
+ <value>#{applicationScope.AuthorizationDomainRegistry}</value>
+ </managed-property>
+ </managed-bean>
+
+ <managed-bean>
<managed-bean-name>createInstanceAction</managed-bean-name>
<managed-bean-class>org.jboss.portal.core.admin.ui.actions.CreateInstanceAction</managed-bean-class>
<managed-bean-scope>request</managed-bean-scope>
@@ -192,6 +219,18 @@
<navigation-rule>
<navigation-case>
+ <from-outcome>index</from-outcome>
+ <to-view-id>/WEB-INF/jsf/objects.xhtml</to-view-id>
+ </navigation-case>
+ <navigation-case>
+ <from-outcome>advancedMode</from-outcome>
+ <to-view-id>/WEB-INF/jsf/objects.xhtml</to-view-id>
+ </navigation-case>
+ <navigation-case>
+ <from-outcome>wizardMode</from-outcome>
+ <to-view-id>/WEB-INF/jsf/wizard/selectPortlet.xhtml</to-view-id>
+ </navigation-case>
+ <navigation-case>
<from-outcome>objects</from-outcome>
<to-view-id>/WEB-INF/jsf/objects.xhtml</to-view-id>
</navigation-case>
@@ -231,6 +270,26 @@
<from-outcome>portlets</from-outcome>
<to-view-id>/WEB-INF/jsf/portlets.xhtml</to-view-id>
</navigation-case>
+ <navigation-case>
+ <from-outcome>selectPortlet</from-outcome>
+ <to-view-id>/WEB-INF/jsf/wizard/selectPortlet.xhtml</to-view-id>
+ </navigation-case>
+ <navigation-case>
+ <from-outcome>selectPortal</from-outcome>
+ <to-view-id>/WEB-INF/jsf/wizard/selectPortal.xhtml</to-view-id>
+ </navigation-case>
+ <navigation-case>
+ <from-outcome>selectPage</from-outcome>
+ <to-view-id>/WEB-INF/jsf/wizard/selectPage.xhtml</to-view-id>
+ </navigation-case>
+ <navigation-case>
+ <from-outcome>selectRegion</from-outcome>
+ <to-view-id>/WEB-INF/jsf/wizard/selectRegion.xhtml</to-view-id>
+ </navigation-case>
+ <navigation-case>
+ <from-outcome>newWindowWizardConfirm</from-outcome>
+ <to-view-id>/WEB-INF/jsf/wizard/newWindowWizardConfirm.xhtml</to-view-id>
+ </navigation-case>
</navigation-rule>
<lifecycle>
Modified: trunk/core-admin/src/resources/portal-admin-war/WEB-INF/jsf/objects.xhtml
===================================================================
--- trunk/core-admin/src/resources/portal-admin-war/WEB-INF/jsf/objects.xhtml 2007-03-12 08:38:21 UTC (rev 6632)
+++ trunk/core-admin/src/resources/portal-admin-war/WEB-INF/jsf/objects.xhtml 2007-03-12 12:03:34 UTC (rev 6633)
@@ -3,7 +3,7 @@
xmlns:ui="http://java.sun.com/jsf/facelets"
xmlns:h="http://java.sun.com/jsf/html"
xmlns:c="http://java.sun.com/jstl/core">
-
+
<c:choose>
<c:when test="#{portalobjectmgr.selectedObject.type == 0}">
<ui:include src="editContext.xhtml"/>
@@ -19,5 +19,7 @@
</c:when>
<c:otherwise>FIXME</c:otherwise>
</c:choose>
+
+ <p style="text-align: right"><h:commandLink action="wizardMode">Go to wizard mode</h:commandLink></p>
</div>
Added: trunk/core-admin/src/resources/portal-admin-war/WEB-INF/jsf/wizard/newWindowTpl.xhtml
===================================================================
--- trunk/core-admin/src/resources/portal-admin-war/WEB-INF/jsf/wizard/newWindowTpl.xhtml (rev 0)
+++ trunk/core-admin/src/resources/portal-admin-war/WEB-INF/jsf/wizard/newWindowTpl.xhtml 2007-03-12 12:03:34 UTC (rev 6633)
@@ -0,0 +1,102 @@
+<div
+ xmlns="http://www.w3.org/1999/xhtml"
+ xmlns:h="http://java.sun.com/jsf/html"
+ xmlns:ui="http://java.sun.com/jsf/facelets"
+ xmlns:c="http://java.sun.com/jstl/core"
+ class="admin-ui">
+
+ <div class="portlet-section-header">Adding a new Portlet</div>
+ <p style="text-align: right;"><h:commandLink action="advancedMode">Go to advanced mode</h:commandLink></p>
+
+ <c:choose>
+ <c:when test="#{newWindowWizard.currentStep == 0}">
+ <div class="wizardStepBox" id="selected">
+ <p class="stepNumber">Step 1</p>
+ <p class="stepText">Select Portlet</p>
+ </div>
+ </c:when>
+ <c:otherwise>
+ <div class="wizardStepBox">
+ <p class="stepNumber">Step 1</p>
+ <p class="stepText">Select Portlet</p>
+ </div>
+ </c:otherwise>
+ </c:choose>
+
+ <c:choose>
+ <c:when test="#{newWindowWizard.currentStep == 1}">
+ <div class="wizardStepBox" id="selected">
+ <p class="stepNumber">Step 2</p>
+ <p class="stepText">Select Portal</p>
+ </div>
+ </c:when>
+ <c:otherwise>
+ <div class="wizardStepBox">
+ <p class="stepNumber">Step 2</p>
+ <p class="stepText">Select Portal</p>
+ </div>
+ </c:otherwise>
+ </c:choose>
+
+ <c:choose>
+ <c:when test="#{newWindowWizard.currentStep == 2}">
+ <div class="wizardStepBox" id="selected">
+ <p class="stepNumber">Step 3</p>
+ <p class="stepText">Select Page</p>
+ </div>
+ </c:when>
+ <c:otherwise>
+ <div class="wizardStepBox">
+ <p class="stepNumber">Step 3</p>
+ <p class="stepText">Select Page</p>
+ </div>
+ </c:otherwise>
+ </c:choose>
+
+ <c:choose>
+ <c:when test="#{newWindowWizard.currentStep == 3}">
+ <div class="wizardStepBox" id="selected">
+ <p class="stepNumber">Step 4</p>
+ <p class="stepText">Select Region</p>
+ </div>
+ </c:when>
+ <c:otherwise>
+ <div class="wizardStepBox">
+ <p class="stepNumber">Step 4</p>
+ <p class="stepText">Select Region</p>
+ </div>
+ </c:otherwise>
+ </c:choose>
+
+ <c:choose>
+ <c:when test="#{newWindowWizard.currentStep == 4}">
+ <div class="wizardStepBox" id="selected">
+ <p class="stepNumber">Step 5</p>
+ <p class="stepText">Confirm</p>
+ </div>
+ </c:when>
+ <c:otherwise>
+ <div class="wizardStepBox">
+ <p class="stepNumber">Step 5</p>
+ <p class="stepText">Confirm</p>
+ </div>
+ </c:otherwise>
+ </c:choose>
+
+ <!-- Status message -->
+ <h:message id="status" for="status"/>
+
+
+ <!-- Content -->
+ <div class="wizardContent">
+ <ui:insert name="content">Content</ui:insert>
+ </div>
+
+ <div class="wizardButtonBox">
+ <h:form>
+ <h:commandButton rendered="#{newWindowWizard.currentStep gt 0}" value="Previous" action="#{newWindowWizard.previous}" styleClass="portlet-form-button"/>
+ <h:commandButton disabled="#{!newWindowWizard.nextEnabled}" rendered="#{newWindowWizard.currentStep lt 4}" value="Next" action="#{newWindowWizard.next}" styleClass="portlet-form-button"/>
+ </h:form>
+ </div>
+
+</div>
Added: trunk/core-admin/src/resources/portal-admin-war/WEB-INF/jsf/wizard/newWindowWizardConfirm.xhtml
===================================================================
--- trunk/core-admin/src/resources/portal-admin-war/WEB-INF/jsf/wizard/newWindowWizardConfirm.xhtml (rev 0)
+++ trunk/core-admin/src/resources/portal-admin-war/WEB-INF/jsf/wizard/newWindowWizardConfirm.xhtml 2007-03-12 12:03:34 UTC (rev 6633)
@@ -0,0 +1,26 @@
+<div
+ xmlns="http://www.w3.org/1999/xhtml"
+ xmlns:ui="http://java.sun.com/jsf/facelets"
+ xmlns:h="http://java.sun.com/jsf/html"
+ xmlns:f="http://java.sun.com/jsf/core"
+ xmlns:c="http://java.sun.com/jstl/core">
+
+ <ui:composition template="newWindowTpl.xhtml">
+ <ui:define name="content">
+
+ <table>
+ <tr><td>Portlet</td><td>#{newWindowWizard.selectedPortlet.name.defaultString}</td></tr>
+ <tr><td>Portal</td><td>#{newWindowWizard.selectedPortal.name}</td></tr>
+ <tr><td>Page</td><td>#{newWindowWizard.selectedPage.name}</td></tr>
+ <tr><td>Region</td><td>#{newWindowWizard.selectedRegionId}</td></tr>
+ </table>
+
+ <h:form>
+ <h:commandButton value="Confirm" action="#{newWindowWizard.createWindow}" styleClass="portlet-form-button"/>
+ <h:commandButton value="Cancel" action="#{newWindowWizard.cancel}" styleClass="portlet-form-button"/>
+ </h:form>
+
+ </ui:define>
+ </ui:composition>
+
+</div>
\ No newline at end of file
Added: trunk/core-admin/src/resources/portal-admin-war/WEB-INF/jsf/wizard/selectPage.xhtml
===================================================================
--- trunk/core-admin/src/resources/portal-admin-war/WEB-INF/jsf/wizard/selectPage.xhtml (rev 0)
+++ trunk/core-admin/src/resources/portal-admin-war/WEB-INF/jsf/wizard/selectPage.xhtml 2007-03-12 12:03:34 UTC (rev 6633)
@@ -0,0 +1,41 @@
+<div
+ xmlns="http://www.w3.org/1999/xhtml"
+ xmlns:ui="http://java.sun.com/jsf/facelets"
+ xmlns:h="http://java.sun.com/jsf/html"
+ xmlns:f="http://java.sun.com/jsf/core"
+ xmlns:c="http://java.sun.com/jstl/core">
+
+ <ui:composition template="newWindowTpl.xhtml">
+ <ui:define name="content">
+
+<table>
+ <tbody class="portlet-section-header">
+ <tr>
+ <th>Page</th>
+ <th></th>
+ </tr>
+ </tbody>
+ <tbody>
+ <c:forEach items="#{newWindowWizard.pages}" var="object" varStatus="status">
+ <tr class="#{object.id == newWindowWizard.selectedPageId ? 'portlet-section-selected' : status.index % 2 == 0 ? 'portlet-section-body' : 'portlet-section-alternate'}">
+ <td>
+ <h:commandLink id="cl_#{status.index}" action="#{newWindowWizard.selectPage}">
+ <h:outputText id="ot_#{status.index}" value="#{object.name}"/>
+ <f:param id="f_#{status.index}" name="id" value="#{object.id}"/>
+ </h:commandLink>
+ </td>
+ <td>
+ <c:if test="#{not empty object.pages}">
+ <h:commandLink id="cl2_#{status.index}" action="#{newWindowWizard.selectParentPage}">
+ <h:outputText id="ot2_#{status.index}" value="Sub-Pages"/>
+ <f:param id="f2_#{status.index}" name="id" value="#{object.id}"/>
+ </h:commandLink>
+ </c:if>
+ </td>
+ </tr>
+ </c:forEach>
+ </tbody>
+</table>
+</ui:define>
+ </ui:composition>
+</div>
\ No newline at end of file
Added: trunk/core-admin/src/resources/portal-admin-war/WEB-INF/jsf/wizard/selectPortal.xhtml
===================================================================
--- trunk/core-admin/src/resources/portal-admin-war/WEB-INF/jsf/wizard/selectPortal.xhtml (rev 0)
+++ trunk/core-admin/src/resources/portal-admin-war/WEB-INF/jsf/wizard/selectPortal.xhtml 2007-03-12 12:03:34 UTC (rev 6633)
@@ -0,0 +1,33 @@
+<div
+ xmlns="http://www.w3.org/1999/xhtml"
+ xmlns:ui="http://java.sun.com/jsf/facelets"
+ xmlns:h="http://java.sun.com/jsf/html"
+ xmlns:f="http://java.sun.com/jsf/core"
+ xmlns:c="http://java.sun.com/jstl/core">
+
+ <ui:composition template="newWindowTpl.xhtml">
+ <ui:define name="content">
+ <table width="100%">
+
+ <tbody class="portlet-section-header">
+ <tr>
+ <th>Portal</th>
+ </tr>
+ </tbody>
+ <tbody>
+ <c:forEach items="#{portalobjectmgr.selectedObject.portals}" var="object" varStatus="status">
+ <tr class="#{object.id == newWindowWizard.selectedPortalId ? 'portlet-section-selected' : status.index % 2 == 0 ? 'portlet-section-body' : 'portlet-section-alternate'}">
+ <td>
+ <h:commandLink action="#{newWindowWizard.selectPortal}">
+ <h:outputText value="#{object.name}"/>
+ <f:param name="id" value="#{object.id}"/>
+ </h:commandLink>
+ </td>
+ </tr>
+ </c:forEach>
+ </tbody>
+
+</table>
+</ui:define>
+ </ui:composition>
+</div>
\ No newline at end of file
Added: trunk/core-admin/src/resources/portal-admin-war/WEB-INF/jsf/wizard/selectPortlet.xhtml
===================================================================
--- trunk/core-admin/src/resources/portal-admin-war/WEB-INF/jsf/wizard/selectPortlet.xhtml (rev 0)
+++ trunk/core-admin/src/resources/portal-admin-war/WEB-INF/jsf/wizard/selectPortlet.xhtml 2007-03-12 12:03:34 UTC (rev 6633)
@@ -0,0 +1,49 @@
+<div
+ xmlns="http://www.w3.org/1999/xhtml"
+ xmlns:ui="http://java.sun.com/jsf/facelets"
+ xmlns:h="http://java.sun.com/jsf/html"
+ xmlns:f="http://java.sun.com/jsf/core"
+ xmlns:c="http://java.sun.com/jstl/core">
+ <ui:composition template="newWindowTpl.xhtml">
+ <ui:define name="content">
+ <h:form>
+ <h:outputLabel for="menu">
+ <h:outputText value="Portlet provider: " styleClass="portlet-form-field-label"/>
+ </h:outputLabel>
+ <h:selectOneMenu id="menu" styleClass="portlet-form-field" value="#{portletmgr.selectedPortletInvokerId}">
+ <f:selectItems value="#{portletmgr.portletInvokerItems}"/>
+ </h:selectOneMenu>
+ <h:commandButton value="Change" styleClass="portlet-form-button"/>
+ </h:form>
+
+ <h:form>
+ <table width="100%">
+ <thead class="portlet-section-header">
+ <tr>
+ <th>Name</th>
+ </tr>
+ </thead>
+ <tbody>
+ <c:forEach items="#{portletmgr.selectedPortlets}" var="portlet" varStatus="status">
+ <tr class="#{portlet.context.id == newWindowWizard.selectedPortletId ? 'portlet-section-selected' : (status.index % 2 == 0 ? 'portlet-section-body' : 'portlet-section-alternate')}">
+ <td><h:commandLink action="#{newWindowWizard.selectPortlet}">
+ <h:outputText>#{portlet.name.value}</h:outputText>
+ <f:param name="id" value="#{portlet.context.id}"/>
+ <f:param name="portletInvokerId" value="#{portletmgr.selectedPortletInvokerId}"/>
+ </h:commandLink></td>
+ </tr>
+ </c:forEach>
+ </tbody>
+ </table>
+ <ul class="pagination">
+ <c:forEach begin="0" end="#{portletmgr.portletCount}" step="#{portletmgr.paginationSize}" var="index">
+ <li class="#{index == portletmgr.selectedFrom ? 'selected' : ''}">
+ <h:commandLink action="#{portletmgr.selectFrom}"><f:param name="from" value="#{index}"/><h:outputText value="#{index}"/></h:commandLink>
+ </li>
+ </c:forEach>
+ </ul>
+ </h:form>
+
+ </ui:define>
+ </ui:composition>
+</div>
\ No newline at end of file
Added: trunk/core-admin/src/resources/portal-admin-war/WEB-INF/jsf/wizard/selectRegion.xhtml
===================================================================
--- trunk/core-admin/src/resources/portal-admin-war/WEB-INF/jsf/wizard/selectRegion.xhtml (rev 0)
+++ trunk/core-admin/src/resources/portal-admin-war/WEB-INF/jsf/wizard/selectRegion.xhtml 2007-03-12 12:03:34 UTC (rev 6633)
@@ -0,0 +1,35 @@
+<div
+ xmlns="http://www.w3.org/1999/xhtml"
+ xmlns:ui="http://java.sun.com/jsf/facelets"
+ xmlns:h="http://java.sun.com/jsf/html"
+ xmlns:f="http://java.sun.com/jsf/core"
+ xmlns:c="http://java.sun.com/jstl/core">
+
+ <ui:composition template="newWindowTpl.xhtml">
+ <ui:define name="content">
+
+ <table width="100%">
+
+ <tbody class="portlet-section-header">
+ <tr>
+ <th>Portal</th>
+ </tr>
+ </tbody>
+ <tbody>
+ <c:forEach items="#{newWindowWizard.regions}" var="object" varStatus="status">
+ <tr class="#{object == newWindowWizard.selectedRegionId ? 'portlet-section-selected' : status.index % 2 == 0 ? 'portlet-section-body' : 'portlet-section-alternate'}">
+ <td>
+ <h:commandLink action="#{newWindowWizard.selectRegion}">
+ <h:outputText value="#{object}"/>
+ <f:param name="name" value="#{object}"/>
+ </h:commandLink>
+ </td>
+ </tr>
+ </c:forEach>
+ </tbody>
+
+</table>
+
+</ui:define>
+ </ui:composition>
+</div>
\ No newline at end of file
17 years, 7 months
JBoss Portal SVN: r6632 - in trunk: identity/src/resources/test/config/identity and 1 other directories.
by portal-commits@lists.jboss.org
Author: bdaw
Date: 2007-03-12 04:38:21 -0400 (Mon, 12 Mar 2007)
New Revision: 6632
Modified:
trunk/identity/src/resources/test/config/identity/openldap-config.xml
trunk/identity/src/resources/test/config/openldap-config.xml
trunk/test/src/etc/directories-identity.xml
trunk/test/src/etc/directories-simplerolemodule.xml
trunk/test/src/etc/directories-simpleusermodule.xml
trunk/test/src/etc/directories-staticgroupmembership.xml
trunk/test/src/etc/directories-userprofilemodule.xml
trunk/test/src/etc/directories.xml
Log:
- relocation of OpenLDAP to dev39
Modified: trunk/identity/src/resources/test/config/identity/openldap-config.xml
===================================================================
--- trunk/identity/src/resources/test/config/identity/openldap-config.xml 2007-03-10 22:32:31 UTC (rev 6631)
+++ trunk/identity/src/resources/test/config/identity/openldap-config.xml 2007-03-12 08:38:21 UTC (rev 6632)
@@ -33,7 +33,7 @@
<config>
<option>
<name>host</name>
- <value>dev09.qa.atl.jboss.com</value>
+ <value>dev39.qa.atl.jboss.com</value>
</option>
<option>
<name>port</name>
Modified: trunk/identity/src/resources/test/config/openldap-config.xml
===================================================================
--- trunk/identity/src/resources/test/config/openldap-config.xml 2007-03-10 22:32:31 UTC (rev 6631)
+++ trunk/identity/src/resources/test/config/openldap-config.xml 2007-03-12 08:38:21 UTC (rev 6632)
@@ -33,7 +33,7 @@
<config>
<option>
<name>host</name>
- <value>dev09.qa.atl.jboss.com</value>
+ <value>dev39.qa.atl.jboss.com</value>
</option>
<option>
<name>port</name>
Modified: trunk/test/src/etc/directories-identity.xml
===================================================================
--- trunk/test/src/etc/directories-identity.xml 2007-03-10 22:32:31 UTC (rev 6631)
+++ trunk/test/src/etc/directories-identity.xml 2007-03-12 08:38:21 UTC (rev 6632)
@@ -83,7 +83,7 @@
<description>OpenLDAP Directory in QA Labs (need vpn access) - StaticGroupMembership config</description>
<config-file>test/config/identity/openldap-config.xml</config-file>
- <host>dev09.qa.atl.jboss.com</host>
+ <host>dev39.qa.atl.jboss.com</host>
<port>389</port>
<context-factory>com.sun.jndi.ldap.LdapCtxFactory</context-factory>
<admin-dn>cn=Manager,dc=my-domain,dc=com</admin-dn>
Modified: trunk/test/src/etc/directories-simplerolemodule.xml
===================================================================
--- trunk/test/src/etc/directories-simplerolemodule.xml 2007-03-10 22:32:31 UTC (rev 6631)
+++ trunk/test/src/etc/directories-simplerolemodule.xml 2007-03-12 08:38:21 UTC (rev 6632)
@@ -57,7 +57,7 @@
<description>OpenLDAP Directory in QA Labs (need vpn access)</description>
<config-file>test/config/openldap-config.xml</config-file>
- <host>dev09.qa.atl.jboss.com</host>
+ <host>dev39.qa.atl.jboss.com</host>
<port>389</port>
<context-factory>com.sun.jndi.ldap.LdapCtxFactory</context-factory>
<admin-dn>cn=Manager,dc=my-domain,dc=com</admin-dn>
Modified: trunk/test/src/etc/directories-simpleusermodule.xml
===================================================================
--- trunk/test/src/etc/directories-simpleusermodule.xml 2007-03-10 22:32:31 UTC (rev 6631)
+++ trunk/test/src/etc/directories-simpleusermodule.xml 2007-03-12 08:38:21 UTC (rev 6632)
@@ -57,7 +57,7 @@
<description>OpenLDAP Directory in QA Labs (need vpn access)</description>
<config-file>test/config/openldap-config.xml</config-file>
- <host>dev09.qa.atl.jboss.com</host>
+ <host>dev39.qa.atl.jboss.com</host>
<port>389</port>
<context-factory>com.sun.jndi.ldap.LdapCtxFactory</context-factory>
<admin-dn>cn=Manager,dc=my-domain,dc=com</admin-dn>
Modified: trunk/test/src/etc/directories-staticgroupmembership.xml
===================================================================
--- trunk/test/src/etc/directories-staticgroupmembership.xml 2007-03-10 22:32:31 UTC (rev 6631)
+++ trunk/test/src/etc/directories-staticgroupmembership.xml 2007-03-12 08:38:21 UTC (rev 6632)
@@ -57,7 +57,7 @@
<description>OpenLDAP Directory in QA Labs (need vpn access)</description>
<config-file>test/config/openldap-config.xml</config-file>
- <host>dev09.qa.atl.jboss.com</host>
+ <host>dev39.qa.atl.jboss.com</host>
<port>389</port>
<context-factory>com.sun.jndi.ldap.LdapCtxFactory</context-factory>
<admin-dn>cn=Manager,dc=my-domain,dc=com</admin-dn>
Modified: trunk/test/src/etc/directories-userprofilemodule.xml
===================================================================
--- trunk/test/src/etc/directories-userprofilemodule.xml 2007-03-10 22:32:31 UTC (rev 6631)
+++ trunk/test/src/etc/directories-userprofilemodule.xml 2007-03-12 08:38:21 UTC (rev 6632)
@@ -57,7 +57,7 @@
<description>OpenLDAP Directory in QA Labs (need vpn access)</description>
<config-file>test/config/openldap-config.xml</config-file>
- <host>dev09.qa.atl.jboss.com</host>
+ <host>dev39.qa.atl.jboss.com</host>
<port>389</port>
<context-factory>com.sun.jndi.ldap.LdapCtxFactory</context-factory>
<admin-dn>cn=Manager,dc=my-domain,dc=com</admin-dn>
Modified: trunk/test/src/etc/directories.xml
===================================================================
--- trunk/test/src/etc/directories.xml 2007-03-10 22:32:31 UTC (rev 6631)
+++ trunk/test/src/etc/directories.xml 2007-03-12 08:38:21 UTC (rev 6632)
@@ -72,7 +72,7 @@
<description>OpenLDAP Directory in QA Labs (need vpn access)</description>
<config-file>test/config/openldap-config.xml</config-file>
- <host>dev09.qa.atl.jboss.com</host>
+ <host>dev39.qa.atl.jboss.com</host>
<port>389</port>
<context-factory>com.sun.jndi.ldap.LdapCtxFactory</context-factory>
<admin-dn>cn=Manager,dc=my-domain,dc=com</admin-dn>
17 years, 7 months
JBoss Portal SVN: r6631 - in trunk/widget/src: resources/widget-war/WEB-INF/jsp and 1 other directory.
by portal-commits@lists.jboss.org
Author: julien(a)jboss.com
Date: 2007-03-10 17:32:31 -0500 (Sat, 10 Mar 2007)
New Revision: 6631
Modified:
trunk/widget/src/main/org/jboss/portal/widget/google/type/DataType.java
trunk/widget/src/resources/widget-war/WEB-INF/jsp/edit.jsp
Log:
GG : handle hidden types in an input type=hidden
Modified: trunk/widget/src/main/org/jboss/portal/widget/google/type/DataType.java
===================================================================
--- trunk/widget/src/main/org/jboss/portal/widget/google/type/DataType.java 2007-03-10 22:29:21 UTC (rev 6630)
+++ trunk/widget/src/main/org/jboss/portal/widget/google/type/DataType.java 2007-03-10 22:32:31 UTC (rev 6631)
@@ -23,6 +23,8 @@
package org.jboss.portal.widget.google.type;
/**
+ * An abstract type for the different datatypes.
+ *
* @author <a href="mailto:julien@jboss.org">Julien Viet</a>
* @version $Revision: 1.1 $
*/
Modified: trunk/widget/src/resources/widget-war/WEB-INF/jsp/edit.jsp
===================================================================
--- trunk/widget/src/resources/widget-war/WEB-INF/jsp/edit.jsp 2007-03-10 22:29:21 UTC (rev 6630)
+++ trunk/widget/src/resources/widget-war/WEB-INF/jsp/edit.jsp 2007-03-10 22:32:31 UTC (rev 6631)
@@ -64,6 +64,19 @@
<p>You have selected the widget <%= selWidget.getTitle().getDefaultString() %></p>
<p>
<form action="<p:actionURL><p:param name="meta_action" value="select"/><p:param name="uri" value="<%= selWidget.getId() %>"/></p:actionURL>" method="post">
+ <%
+ for (Iterator i = selWidget.getPreferencesInfo().getPreferencesInfo().iterator(); i.hasNext();)
+ {
+ GGPreferenceInfo prefInfo = (GGPreferenceInfo)i.next();
+ if (prefInfo.getType().getOrdinal() == DataType.HIDDEN)
+ {
+
+ %>
+ <input type="hidden" name="param.<%= prefInfo.getName() %>" value="<%= prefInfo.getDefaultValue() != null ? prefInfo.getDefaultValue() : "" %>"/>
+ <%
+ }
+ }
+ %>
<table>
<tbody>
<%
@@ -76,6 +89,8 @@
<%
switch (prefInfo.getType().getOrdinal())
{
+ case DataType.HIDDEN:
+ break;
case DataType.ENUM:
%>
<td><select name="param.<%= prefInfo.getName() %>" class="portlet-form-field">
17 years, 7 months
JBoss Portal SVN: r6630 - trunk/widget/src/main/org/jboss/portal/widget/google.
by portal-commits@lists.jboss.org
Author: julien(a)jboss.com
Date: 2007-03-10 17:29:21 -0500 (Sat, 10 Mar 2007)
New Revision: 6630
Modified:
trunk/widget/src/main/org/jboss/portal/widget/google/GGWidget.java
Log:
GG : update todo + add link to reference guide
Modified: trunk/widget/src/main/org/jboss/portal/widget/google/GGWidget.java
===================================================================
--- trunk/widget/src/main/org/jboss/portal/widget/google/GGWidget.java 2007-03-10 22:20:40 UTC (rev 6629)
+++ trunk/widget/src/main/org/jboss/portal/widget/google/GGWidget.java 2007-03-10 22:29:21 UTC (rev 6630)
@@ -31,49 +31,11 @@
import java.util.Map;
/**
- * Getting list :
- * http://www.google.com/ig/directory?synd=open
+ * A Google Gadget widget For more details please see the <a href="http://www.google.com/apis/gadgets/reference.html">API Developer Guide</a>.
*
- * synd=open -> mandatory to get the embedable widgets
- * &source=gghp ????
+ * @todo
+ * - Resource bundles implementation
*
- * &start= default=0 [->sa=N ??? ]
- * &num= default=24
- * &cat= default=all (popular|news|tools|communication|funandgames|finance|sports|lifestyle|technology|new)
- *
- * <Module>
- * <ModulePrefs
- * title=""
- * author=""
- * author_email=""
- * author_affiliation=""
- * author_location=""
- * screenshot=""
- * thumbnail=""
- * category=""
- * description=""
- * render_inline="optional"
- * height=""
- * scaling="true|false"
- * scrolling="true|false">
- * <UserPref
- * name=""
- * display_name=""
- * default_value=""/>
- *
- * Getting javascript :
- *
- * http://gmodules.com/ig/ifr?url=
- * up_color=blue
- * synd=open
- * w=554
- * h=205
- * title=Date+%26+Time
- * border=%23ffffff%7C3px%2C1px+solid+%23999999
- * output=js
- * +
- * up_ + user pref name = value
- *
* @author <a href="mailto:julien@jboss.org">Julien Viet</a>
* @version $Revision: 1.1 $
*/
17 years, 7 months
JBoss Portal SVN: r6629 - in trunk: widget/src/resources/widget-war/WEB-INF/jsp and 1 other directory.
by portal-commits@lists.jboss.org
Author: julien(a)jboss.com
Date: 2007-03-10 17:20:40 -0500 (Sat, 10 Mar 2007)
New Revision: 6629
Modified:
trunk/core-admin/src/main/org/jboss/portal/core/admin/ui/portlet/PortletContentEditorPortlet.java
trunk/widget/src/resources/widget-war/WEB-INF/jsp/edit.jsp
Log:
Change the Add word to Select as it works for updating or adding
Modified: trunk/core-admin/src/main/org/jboss/portal/core/admin/ui/portlet/PortletContentEditorPortlet.java
===================================================================
--- trunk/core-admin/src/main/org/jboss/portal/core/admin/ui/portlet/PortletContentEditorPortlet.java 2007-03-10 22:19:19 UTC (rev 6628)
+++ trunk/core-admin/src/main/org/jboss/portal/core/admin/ui/portlet/PortletContentEditorPortlet.java 2007-03-10 22:20:40 UTC (rev 6629)
@@ -126,7 +126,7 @@
writer.println("</option>\n");
}
writer.println("</select>");
- writer.println("<input name=\"meta_action\" value=\"Add\" type=\"submit\"/>");
+ writer.println("<input name=\"meta_action\" value=\"Select\" type=\"submit\"/>");
writer.println("<input name=\"select\" value=\"Info\" type=\"submit\"/>");
writer.print("</form>");
Modified: trunk/widget/src/resources/widget-war/WEB-INF/jsp/edit.jsp
===================================================================
--- trunk/widget/src/resources/widget-war/WEB-INF/jsp/edit.jsp 2007-03-10 22:19:19 UTC (rev 6628)
+++ trunk/widget/src/resources/widget-war/WEB-INF/jsp/edit.jsp 2007-03-10 22:20:40 UTC (rev 6629)
@@ -105,7 +105,7 @@
}
%>
<tr>
- <td colspan="2"><input type="submit" value="Add" class="portlet-form-button"/></td>
+ <td colspan="2"><input type="submit" value="Select" class="portlet-form-button"/></td>
</tr>
</tbody>
</table>
17 years, 7 months
JBoss Portal SVN: r6628 - trunk/core-admin/src/main/org/jboss/portal/core/admin/ui/portlet.
by portal-commits@lists.jboss.org
Author: julien(a)jboss.com
Date: 2007-03-10 17:19:19 -0500 (Sat, 10 Mar 2007)
New Revision: 6628
Modified:
trunk/core-admin/src/main/org/jboss/portal/core/admin/ui/portlet/PortletContentEditorPortlet.java
Log:
2 buttons for portlet content editor portlet : one to show info and the other one to add the portlet
Modified: trunk/core-admin/src/main/org/jboss/portal/core/admin/ui/portlet/PortletContentEditorPortlet.java
===================================================================
--- trunk/core-admin/src/main/org/jboss/portal/core/admin/ui/portlet/PortletContentEditorPortlet.java 2007-03-10 22:02:42 UTC (rev 6627)
+++ trunk/core-admin/src/main/org/jboss/portal/core/admin/ui/portlet/PortletContentEditorPortlet.java 2007-03-10 22:19:19 UTC (rev 6628)
@@ -92,7 +92,6 @@
//
PortletURL actionURL = resp.createActionURL();
- actionURL.setParameter("meta_action", "select");
//
resp.setContentType("text/html");
@@ -127,7 +126,8 @@
writer.println("</option>\n");
}
writer.println("</select>");
- writer.println("<input name=\"select\" value=\"Select\" type=\"submit\"/>");
+ writer.println("<input name=\"meta_action\" value=\"Add\" type=\"submit\"/>");
+ writer.println("<input name=\"select\" value=\"Info\" type=\"submit\"/>");
writer.print("</form>");
//
17 years, 7 months
JBoss Portal SVN: r6627 - in trunk: widget/src/resources/widget-war/WEB-INF/jsp and 1 other directory.
by portal-commits@lists.jboss.org
Author: julien(a)jboss.com
Date: 2007-03-10 17:02:42 -0500 (Sat, 10 Mar 2007)
New Revision: 6627
Modified:
trunk/core-admin/src/resources/portal-admin-war/WEB-INF/jsf/editPageLayout.xhtml
trunk/widget/src/resources/widget-war/WEB-INF/jsp/edit.jsp
Log:
minor layout improvement + corrected styles
Modified: trunk/core-admin/src/resources/portal-admin-war/WEB-INF/jsf/editPageLayout.xhtml
===================================================================
--- trunk/core-admin/src/resources/portal-admin-war/WEB-INF/jsf/editPageLayout.xhtml 2007-03-10 21:53:58 UTC (rev 6626)
+++ trunk/core-admin/src/resources/portal-admin-war/WEB-INF/jsf/editPageLayout.xhtml 2007-03-10 22:02:42 UTC (rev 6627)
@@ -101,7 +101,7 @@
<td class="label">
</td>
<td class="widget">
- <div align="left">
+ <div style="margin-top:3em;">
<jbp:portlet
instanceId="#{portalobjectmgr.selectedContentEditorInstance}"
actionListener="#{portalobjectmgr.processEvent}"
Modified: trunk/widget/src/resources/widget-war/WEB-INF/jsp/edit.jsp
===================================================================
--- trunk/widget/src/resources/widget-war/WEB-INF/jsp/edit.jsp 2007-03-10 21:53:58 UTC (rev 6626)
+++ trunk/widget/src/resources/widget-war/WEB-INF/jsp/edit.jsp 2007-03-10 22:02:42 UTC (rev 6627)
@@ -40,8 +40,8 @@
<form action="<p:renderURL></p:renderURL>" method="post">
- <input type="text" name="query"/>
- <select name="cat">
+ <input type="text" name="query" class="portlet-form-field"/>
+ <select name="cat" class="portlet-form-field">
<option value=""> </option>
<%
for (Iterator i = provider.getCategories().iterator(); i.hasNext();)
@@ -54,7 +54,7 @@
}
%>
</select>
- <input type="submit" value="Search Gadgets"/>
+ <input type="submit" value="Search Gadgets" class="portlet-form-button"/>
</form>
<%
@@ -78,7 +78,7 @@
{
case DataType.ENUM:
%>
- <td><select name="param.<%= prefInfo.getName() %>">
+ <td><select name="param.<%= prefInfo.getName() %>" class="portlet-form-field">
<%
EnumType e = (EnumType)prefInfo.getType();
for (int j = 0;j < e.getSize();j++)
@@ -95,7 +95,7 @@
break;
default:
%>
- <td><input type="text" name="param.<%= prefInfo.getName() %>" value="<%= prefInfo.getDefaultValue() != null ? prefInfo.getDefaultValue() : "" %>"/></td>
+ <td><input type="text" name="param.<%= prefInfo.getName() %>" class="portlet-form-field" value="<%= prefInfo.getDefaultValue() != null ? prefInfo.getDefaultValue() : "" %>"/></td>
<%
break;
}
@@ -105,7 +105,7 @@
}
%>
<tr>
- <td colspan="2"><input type="submit" value="Add"/></td>
+ <td colspan="2"><input type="submit" value="Add" class="portlet-form-button"/></td>
</tr>
</tbody>
</table>
17 years, 7 months
JBoss Portal SVN: r6626 - in trunk: widget/src/main/org/jboss/portal/widget/google and 1 other directories.
by portal-commits@lists.jboss.org
Author: julien(a)jboss.com
Date: 2007-03-10 16:53:58 -0500 (Sat, 10 Mar 2007)
New Revision: 6626
Modified:
trunk/core-admin/src/resources/portal-admin-war/WEB-INF/jsf/editPageLayout.xhtml
trunk/widget/src/main/org/jboss/portal/widget/google/GGWidget.java
trunk/widget/src/resources/widget-war/WEB-INF/jsp/edit.jsp
Log:
- implemented GG enums
- better formatting of GG editor
Modified: trunk/core-admin/src/resources/portal-admin-war/WEB-INF/jsf/editPageLayout.xhtml
===================================================================
--- trunk/core-admin/src/resources/portal-admin-war/WEB-INF/jsf/editPageLayout.xhtml 2007-03-10 20:58:50 UTC (rev 6625)
+++ trunk/core-admin/src/resources/portal-admin-war/WEB-INF/jsf/editPageLayout.xhtml 2007-03-10 21:53:58 UTC (rev 6626)
@@ -99,7 +99,6 @@
</tr>
<tr>
<td class="label">
- <span class="portlet-form-field-label">Portlet content:</span>
</td>
<td class="widget">
<div align="left">
Modified: trunk/widget/src/main/org/jboss/portal/widget/google/GGWidget.java
===================================================================
--- trunk/widget/src/main/org/jboss/portal/widget/google/GGWidget.java 2007-03-10 20:58:50 UTC (rev 6625)
+++ trunk/widget/src/main/org/jboss/portal/widget/google/GGWidget.java 2007-03-10 21:53:58 UTC (rev 6626)
@@ -24,6 +24,7 @@
import org.jboss.portal.common.util.LocalizedString;
import org.jboss.portal.common.util.UUIDGenerator;
+import org.jboss.portal.common.text.FastURLEncoder;
import org.jboss.portal.widget.Widget;
import java.util.Iterator;
@@ -144,7 +145,7 @@
tmp.append("&synd=open");
tmp.append("&w=").append(width);
tmp.append("&h=").append(height);
- tmp.append("&title=").append(title.getDefaultString());
+ tmp.append("&title=").append(FastURLEncoder.DEFAULT_ENCODER.encode(title.getDefaultString()));
tmp.append("&border=%23ffffff%7C3px%2C1px+none+%23999999"); // "&border=%23ffffff%7C3px%2C1px+solid+%23999999"
tmp.append("&output=js");
@@ -152,11 +153,12 @@
for (Iterator i = prefsInfo.getPreferencesInfo().iterator();i.hasNext();)
{
GGPreferenceInfo prefInfo = (GGPreferenceInfo)i.next();
- String[] values = (String[])parameters.get(prefInfo.getName());
+ String prefName = prefInfo.getName();
+ String[] values = (String[])parameters.get(prefName);
String value = values != null ? values[0] : prefInfo.getDefaultValue();
if (value != null)
{
- tmp.append("&_up").append(prefInfo.getName()).append("=").append(prefInfo.getDefaultValue());
+ tmp.append("&up_").append(FastURLEncoder.DEFAULT_ENCODER.encode(prefName)).append("=").append(FastURLEncoder.DEFAULT_ENCODER.encode(value));
}
}
Modified: trunk/widget/src/resources/widget-war/WEB-INF/jsp/edit.jsp
===================================================================
--- trunk/widget/src/resources/widget-war/WEB-INF/jsp/edit.jsp 2007-03-10 20:58:50 UTC (rev 6625)
+++ trunk/widget/src/resources/widget-war/WEB-INF/jsp/edit.jsp 2007-03-10 21:53:58 UTC (rev 6626)
@@ -6,6 +6,7 @@
<%@ page import="org.jboss.portal.widget.google.type.DataType" %>
<%@ page import="org.jboss.portal.widget.google.GGWidgetCategoryInfo" %>
<%@ page import="org.jboss.portal.widget.google.provider.GGQuery" %>
+<%@ page import="org.jboss.portal.widget.google.type.EnumType" %>
<%@ page language="java"%>
<%@ taglib uri="http://java.sun.com/portlet" prefix="p" %>
<%@ page isELIgnored="false" %>
@@ -53,7 +54,7 @@
}
%>
</select>
- <input type="submit"/>
+ <input type="submit" value="Search Gadgets"/>
</form>
<%
@@ -63,23 +64,51 @@
<p>You have selected the widget <%= selWidget.getTitle().getDefaultString() %></p>
<p>
<form action="<p:actionURL><p:param name="meta_action" value="select"/><p:param name="uri" value="<%= selWidget.getId() %>"/></p:actionURL>" method="post">
+ <table>
+ <tbody>
<%
for (Iterator i = selWidget.getPreferencesInfo().getPreferencesInfo().iterator(); i.hasNext();)
{
GGPreferenceInfo prefInfo = (GGPreferenceInfo)i.next();
+ %>
+ <tr>
+ <td><%= prefInfo.getName() %>:</td>
+ <%
switch (prefInfo.getType().getOrdinal())
{
case DataType.ENUM:
- // Todo
+ %>
+ <td><select name="param.<%= prefInfo.getName() %>">
+ <%
+ EnumType e = (EnumType)prefInfo.getType();
+ for (int j = 0;j < e.getSize();j++)
+ {
+ EnumType.Value value = e.getValue(j);
+ boolean selected = value.getValue().equals(prefInfo.getDefaultValue());
+ %>
+ <option <%= selected ? "selected=\"selected\"" : "" %> value="<%= value.getValue() %>"><%= value.getDisplayValue() != null ? value.getDisplayValue() : value.getValue() %></option>
+ <%
+ }
+ %>
+ </select></td>
+ <%
break;
default:
%>
- <div><%= prefInfo.getName() %>: <input type="text" name="param.<%= prefInfo.getName() %>" value="<%= prefInfo.getDefaultValue() != null ? prefInfo.getDefaultValue() : "" %>"/></div>
+ <td><input type="text" name="param.<%= prefInfo.getName() %>" value="<%= prefInfo.getDefaultValue() != null ? prefInfo.getDefaultValue() : "" %>"/></td>
<%
+ break;
}
+ %>
+ </tr>
+ <%
}
%>
- <input type="submit"/>
+ <tr>
+ <td colspan="2"><input type="submit" value="Add"/></td>
+ </tr>
+ </tbody>
+ </table>
</form>
</p>
<%
17 years, 7 months