Author: ndkhoiits
Date: 2011-02-23 01:42:19 -0500 (Wed, 23 Feb 2011)
New Revision: 5920
Added:
portal/trunk/portlet/exoadmin/src/main/webapp/WEB-INF/classes/locale/portlet/exoadmin/UserToolbarPortlet_fr.properties
portal/trunk/portlet/exoadmin/src/main/webapp/WEB-INF/classes/locale/portlet/exoadmin/UserToolbarPortlet_vi.properties
Modified:
portal/trunk/
portal/trunk/component/application-registry/src/main/java/org/exoplatform/application/registry/impl/ApplicationRegistryServiceImpl.java
portal/trunk/examples/extension/war/src/main/webapp/WEB-INF/classes/locale/portal/sample_en.properties
portal/trunk/examples/extension/war/src/main/webapp/templates/groovy/webui/component/UIHomePagePortlet.gtmpl
portal/trunk/examples/portal/war/src/main/webapp/WEB-INF/classes/locale/portal/sample_en.properties
portal/trunk/examples/portal/war/src/main/webapp/templates/groovy/webui/component/UIHomePagePortlet.gtmpl
portal/trunk/pom.xml
portal/trunk/portlet/exoadmin/src/main/java/org/exoplatform/applicationregistry/webui/component/UIAddApplicationForm.java
portal/trunk/portlet/exoadmin/src/main/java/org/exoplatform/applicationregistry/webui/component/UIPortletInfo.java
portal/trunk/portlet/exoadmin/src/main/webapp/WEB-INF/classes/locale/portlet/exoadmin/UserToolbarPortlet_en.properties
portal/trunk/portlet/exoadmin/src/main/webapp/groovy/admintoolbar/webui/component/UIUserToolBarDashboardPortlet.gtmpl
portal/trunk/portlet/exoadmin/src/main/webapp/groovy/admintoolbar/webui/component/UIUserToolBarGroupPortlet.gtmpl
portal/trunk/portlet/exoadmin/src/main/webapp/groovy/admintoolbar/webui/component/UIUserToolBarSitePortlet.gtmpl
portal/trunk/portlet/exoadmin/src/main/webapp/skin/applicationregistry/webui/component/UIApplicationRegistryPortlet/DefaultStylesheet.css
portal/trunk/portlet/web/src/main/webapp/skin/portal/webui/component/UILogoPortlet/DefaultStylesheet.css
portal/trunk/web/eXoResources/src/main/webapp/javascript/eXo/gadget/ExoBasedUserPrefStore.js
portal/trunk/web/eXoResources/src/main/webapp/javascript/eXo/gadget/Gadgets.js
portal/trunk/web/eXoResources/src/main/webapp/skin/DefaultSkin/webui/component/UIBarDecorator/UIAction/Stylesheet.css
portal/trunk/webui/portal/src/main/java/org/exoplatform/portal/application/PortalRequestContext.java
portal/trunk/webui/portal/src/main/java/org/exoplatform/portal/webui/application/UIPortlet.java
portal/trunk/webui/portal/src/main/java/org/exoplatform/portal/webui/application/UIPortletLifecycle.java
portal/trunk/webui/portal/src/main/java/org/exoplatform/portal/webui/portal/UIPortalComponentActionListener.java
Log:
GTNPORTAL-1790 Merge the commit branch of sprint 47 back to trunk
Property changes on: portal/trunk
___________________________________________________________________
Added: svn:mergeinfo
+ /portal/branches/branch-GTNPORTAL-1790:5864-5919
Modified:
portal/trunk/component/application-registry/src/main/java/org/exoplatform/application/registry/impl/ApplicationRegistryServiceImpl.java
===================================================================
---
portal/trunk/component/application-registry/src/main/java/org/exoplatform/application/registry/impl/ApplicationRegistryServiceImpl.java 2011-02-22
15:47:32 UTC (rev 5919)
+++
portal/trunk/component/application-registry/src/main/java/org/exoplatform/application/registry/impl/ApplicationRegistryServiceImpl.java 2011-02-23
06:42:19 UTC (rev 5920)
@@ -524,11 +524,25 @@
contentId = info.getApplicationName() + "/" +
info.getName();
}
- //
- app = category.createContent(portletName, contentType, contentId);
- app.setDisplayName(displayName);
- app.setDescription(getLocalizedStringValue(descriptionLS, portletName));
- app.setAccessPermissions(permissions);
+ // Check if the portlet has already existed in this category
+ List<Application> applications = load(category).getApplications();
+ boolean isExist = false;
+ for (Application application : applications)
+ {
+ if (application.getContentId().equals(contentId))
+ {
+ isExist = true;
+ break;
+ }
+ }
+
+ if (!isExist)
+ {
+ app = category.createContent(portletName, contentType, contentId);
+ app.setDisplayName(displayName);
+ app.setDescription(getLocalizedStringValue(descriptionLS,
portletName));
+ app.setAccessPermissions(permissions);
+ }
}
}
}
Modified:
portal/trunk/examples/extension/war/src/main/webapp/WEB-INF/classes/locale/portal/sample_en.properties
===================================================================
---
portal/trunk/examples/extension/war/src/main/webapp/WEB-INF/classes/locale/portal/sample_en.properties 2011-02-22
15:47:32 UTC (rev 5919)
+++
portal/trunk/examples/extension/war/src/main/webapp/WEB-INF/classes/locale/portal/sample_en.properties 2011-02-23
06:42:19 UTC (rev 5920)
@@ -17,4 +17,5 @@
# 02110-1301 USA, or see the FSF site:
http://www.fsf.org.
#
-UIHomePagePortlet.Label.SampleRB.SampleKey=This is a new key from the new Resource Bundle
"locale.portal.sample" of "sample-ext"
\ No newline at end of file
+UIHomePagePortlet.Label.SampleRB.SampleKey=This is a new key from the new Resource Bundle
"locale.portal.sample" of "sample-ext"
+UIHomePagePortlet.Label.ExtendedHomePage=This is the Home Page of the
"sample-ext" (skin has changed, new pages, customized resource bundles) :
\ No newline at end of file
Modified:
portal/trunk/examples/extension/war/src/main/webapp/templates/groovy/webui/component/UIHomePagePortlet.gtmpl
===================================================================
---
portal/trunk/examples/extension/war/src/main/webapp/templates/groovy/webui/component/UIHomePagePortlet.gtmpl 2011-02-22
15:47:32 UTC (rev 5919)
+++
portal/trunk/examples/extension/war/src/main/webapp/templates/groovy/webui/component/UIHomePagePortlet.gtmpl 2011-02-23
06:42:19 UTC (rev 5920)
@@ -4,7 +4,7 @@
<div class="UIHomePagePortlet" id="$uicomponent.id">
<div class="TRContainer">
<div class="PortletDecoration">
- <div class="GuideText">GateIn is the new generation of Open Source
portal, jointly led by Red Hat and eXo Platform who partner to gather the best portal
experts and communities around a robust and intuitive portal that brings rich
administration functionalities to IT systems. <br /> This is the Home Page of the
"sample-ext" (skin has changed, new pages, customized resource bundles)
:</div>
+ <div
class="GuideText"><%=_ctx.appRes("UIHomePagePortlet.Label.IntroText")%>
<br />
<%=_ctx.appRes("UIHomePagePortlet.Label.ExtendedHomePage")%></div>
<a class="VersionIcon"
href="http://www.jboss.org/gatein/"
target="_blank"></a>
<div class="DotLine"><span></span></div>
<div
class="GuideText"><%=_ctx.appRes("UIHomePagePortlet.Label.GuideText")%></div>
Modified:
portal/trunk/examples/portal/war/src/main/webapp/WEB-INF/classes/locale/portal/sample_en.properties
===================================================================
---
portal/trunk/examples/portal/war/src/main/webapp/WEB-INF/classes/locale/portal/sample_en.properties 2011-02-22
15:47:32 UTC (rev 5919)
+++
portal/trunk/examples/portal/war/src/main/webapp/WEB-INF/classes/locale/portal/sample_en.properties 2011-02-23
06:42:19 UTC (rev 5920)
@@ -17,4 +17,5 @@
# 02110-1301 USA, or see the FSF site:
http://www.fsf.org.
#
-UIHomePagePortlet.Label.SampleRB.SampleKey=This is a new key from the new Resource Bundle
"locale.portal.sample" of "sample-portal"
\ No newline at end of file
+UIHomePagePortlet.Label.SampleRB.SampleKey=This is a new key from the new Resource Bundle
"locale.portal.sample" of "sample-portal"
+UIHomePagePortlet.Label.ExtendedHomePage=This is the Home Page of the
"sample-portal" contained in gatein-sample-extension.ear/war, as you can see the
skin has changed, we added new pages, we use our customized resource bundles as you can
see below:
\ No newline at end of file
Modified:
portal/trunk/examples/portal/war/src/main/webapp/templates/groovy/webui/component/UIHomePagePortlet.gtmpl
===================================================================
---
portal/trunk/examples/portal/war/src/main/webapp/templates/groovy/webui/component/UIHomePagePortlet.gtmpl 2011-02-22
15:47:32 UTC (rev 5919)
+++
portal/trunk/examples/portal/war/src/main/webapp/templates/groovy/webui/component/UIHomePagePortlet.gtmpl 2011-02-23
06:42:19 UTC (rev 5920)
@@ -4,7 +4,7 @@
<div class="UIHomePagePortlet" id="$uicomponent.id">
<div class="TRContainer">
<div class="PortletDecoration">
- <div class="GuideText">This is the Home Page of the
"sample-portal" contained in gatein-sample-extension.ear/war, as you can see the
skin has changed, we added new pages, we use our customized resource bundles as you can
see below:
+ <div
class="GuideText"><%=_ctx.appRes("UIHomePagePortlet.Label.ExtendedHomePage")%>
<ul>
<li><b><%=_ctx.appRes("UIHomePagePortlet.Label.SampleKey")%></b></li>
<li><b><%=_ctx.appRes("UIHomePagePortlet.Label.SampleRB.SampleKey")%></b></li>
Modified: portal/trunk/pom.xml
===================================================================
--- portal/trunk/pom.xml 2011-02-22 15:47:32 UTC (rev 5919)
+++ portal/trunk/pom.xml 2011-02-23 06:42:19 UTC (rev 5920)
@@ -42,7 +42,7 @@
<org.exoplatform.ws.version>2.1.7-GA</org.exoplatform.ws.version>
<org.exoplatform.jcr.version>1.12.7-GA</org.exoplatform.jcr.version>
<org.jibx.version>1.2.1</org.jibx.version>
- <org.shindig.version>1.0-r790473-Patch04</org.shindig.version>
+ <org.shindig.version>1.0-r790473-Patch05</org.shindig.version>
<nl.captcha.simplecaptcha.version>1.1.1-GA-Patch01</nl.captcha.simplecaptcha.version>
<org.gatein.common.version>2.0.3-GA</org.gatein.common.version>
<org.gatein.wci.version>2.1.0-Alpha02</org.gatein.wci.version>
Modified:
portal/trunk/portlet/exoadmin/src/main/java/org/exoplatform/applicationregistry/webui/component/UIAddApplicationForm.java
===================================================================
---
portal/trunk/portlet/exoadmin/src/main/java/org/exoplatform/applicationregistry/webui/component/UIAddApplicationForm.java 2011-02-22
15:47:32 UTC (rev 5919)
+++
portal/trunk/portlet/exoadmin/src/main/java/org/exoplatform/applicationregistry/webui/component/UIAddApplicationForm.java 2011-02-23
06:42:19 UTC (rev 5920)
@@ -265,23 +265,24 @@
return;
}
- UIFormRadioBoxInput uiRadio = uiForm.getUIInput("application");
- String displayName = uiForm.getUIStringInput(FIELD_NAME).getValue();
if (uiForm.getApplications().size() == 0)
{
ctx.getUIApplication().addMessage(new
ApplicationMessage("UIAddApplicationForm.msg.appNotExists", null));
ctx.addUIComponentToUpdateByAjax(uiOrganizer);
return;
}
+ UIFormRadioBoxInput uiRadio = uiForm.getUIInput("application");
+ String displayName = uiForm.getUIStringInput(FIELD_NAME).getValue();
Application tmp =
uiForm.getApplications().get(Integer.parseInt(uiRadio.getValue()));
-
+
// check portet name is exist
- if (appRegService.getApplication(selectedCate.getName(),
tmp.getApplicationName()) != null)
+ for (Application application : appRegService.getApplications(selectedCate))
{
- WebuiRequestContext context = WebuiRequestContext.getCurrentInstance();
- UIApplication uiApp = context.getUIApplication();
- uiApp.addMessage(new
ApplicationMessage("UIAddApplicationForm.msg.PortletExist", null));
- return;
+ if (application.getContentId().equals(tmp.getContentId()))
+ {
+ ctx.getUIApplication().addMessage(new
ApplicationMessage("UIAddApplicationForm.msg.PortletExist", null));
+ return;
+ }
}
Application app = cloneApplication(tmp);
Modified:
portal/trunk/portlet/exoadmin/src/main/java/org/exoplatform/applicationregistry/webui/component/UIPortletInfo.java
===================================================================
---
portal/trunk/portlet/exoadmin/src/main/java/org/exoplatform/applicationregistry/webui/component/UIPortletInfo.java 2011-02-22
15:47:32 UTC (rev 5919)
+++
portal/trunk/portlet/exoadmin/src/main/java/org/exoplatform/applicationregistry/webui/component/UIPortletInfo.java 2011-02-23
06:42:19 UTC (rev 5920)
@@ -93,9 +93,12 @@
for (ApplicationCategory category : allCategories)
{
- if (appRegService.getApplication(category.getName(), portlet_.getName()) !=
null)
+ for (Application application : appRegService.getApplications(category))
{
- nameList.add(category.getDisplayName());
+ if (application.getContentId().equals(portlet_.getId()))
+ {
+ nameList.add(category.getDisplayName());
+ }
}
}
StringBuffer names = new StringBuffer("");
Modified:
portal/trunk/portlet/exoadmin/src/main/webapp/WEB-INF/classes/locale/portlet/exoadmin/UserToolbarPortlet_en.properties
===================================================================
---
portal/trunk/portlet/exoadmin/src/main/webapp/WEB-INF/classes/locale/portlet/exoadmin/UserToolbarPortlet_en.properties 2011-02-22
15:47:32 UTC (rev 5919)
+++
portal/trunk/portlet/exoadmin/src/main/webapp/WEB-INF/classes/locale/portlet/exoadmin/UserToolbarPortlet_en.properties 2011-02-23
06:42:19 UTC (rev 5920)
@@ -16,4 +16,6 @@
# Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
# 02110-1301 USA, or see the FSF site:
http://www.fsf.org.
#
-
+UIUserToolBarSitePortlet.header.site=Site
+UIUserToolBarGroupPortlet.header.group=Group
+UIUserToolBarDashboardPortlet.header.dashboard=Dashboard
\ No newline at end of file
Copied:
portal/trunk/portlet/exoadmin/src/main/webapp/WEB-INF/classes/locale/portlet/exoadmin/UserToolbarPortlet_fr.properties
(from rev 5919,
portal/branches/branch-GTNPORTAL-1790/portlet/exoadmin/src/main/webapp/WEB-INF/classes/locale/portlet/exoadmin/UserToolbarPortlet_fr.properties)
===================================================================
---
portal/trunk/portlet/exoadmin/src/main/webapp/WEB-INF/classes/locale/portlet/exoadmin/UserToolbarPortlet_fr.properties
(rev 0)
+++
portal/trunk/portlet/exoadmin/src/main/webapp/WEB-INF/classes/locale/portlet/exoadmin/UserToolbarPortlet_fr.properties 2011-02-23
06:42:19 UTC (rev 5920)
@@ -0,0 +1,21 @@
+#
+# Copyright (C) 2009 eXo Platform SAS.
+#
+# 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.
+#
+UIUserToolBarSitePortlet.header.site=Site
+UIUserToolBarGroupPortlet.header.group=Groupe
+UIUserToolBarDashboardPortlet.header.dashboard=Dashboard
Copied:
portal/trunk/portlet/exoadmin/src/main/webapp/WEB-INF/classes/locale/portlet/exoadmin/UserToolbarPortlet_vi.properties
(from rev 5919,
portal/branches/branch-GTNPORTAL-1790/portlet/exoadmin/src/main/webapp/WEB-INF/classes/locale/portlet/exoadmin/UserToolbarPortlet_vi.properties)
===================================================================
---
portal/trunk/portlet/exoadmin/src/main/webapp/WEB-INF/classes/locale/portlet/exoadmin/UserToolbarPortlet_vi.properties
(rev 0)
+++
portal/trunk/portlet/exoadmin/src/main/webapp/WEB-INF/classes/locale/portlet/exoadmin/UserToolbarPortlet_vi.properties 2011-02-23
06:42:19 UTC (rev 5920)
@@ -0,0 +1,21 @@
+#
+# Copyright (C) 2009 eXo Platform SAS.
+#
+# 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.
+#
+UIUserToolBarSitePortlet.header.site=Site
+UIUserToolBarGroupPortlet.header.group=Nhóm
+UIUserToolBarDashboardPortlet.header.dashboard=Bảng điều khiển
Modified:
portal/trunk/portlet/exoadmin/src/main/webapp/groovy/admintoolbar/webui/component/UIUserToolBarDashboardPortlet.gtmpl
===================================================================
---
portal/trunk/portlet/exoadmin/src/main/webapp/groovy/admintoolbar/webui/component/UIUserToolBarDashboardPortlet.gtmpl 2011-02-22
15:47:32 UTC (rev 5919)
+++
portal/trunk/portlet/exoadmin/src/main/webapp/groovy/admintoolbar/webui/component/UIUserToolBarDashboardPortlet.gtmpl 2011-02-23
06:42:19 UTC (rev 5920)
@@ -99,7 +99,7 @@
<div class="TabsContainer">
<div class="UITab NormalToolbarTab">
<div class="">
- <a class="DashboardIcon TBIcon" href="<%=
uicomponent.url("AddDefaultDashboard", defaultDashboardPage);
%>">Dashboard</a>
+ <a class="DashboardIcon TBIcon" href="<%=
uicomponent.url("AddDefaultDashboard", defaultDashboardPage);
%>"><%=_ctx.appRes("UIUserToolBarDashboardPortlet.header.dashboard")%></a>
</div>
</div>
</div>
@@ -114,7 +114,7 @@
<div class="TabsContainer" >
<div class="UITab NormalToolbarTab">
<div class="">
- <a class="DashboardIcon TBIcon" href="<%= portalURI +
defaultDashboardPage %>">Dashboard</a>
+ <a class="DashboardIcon TBIcon" href="<%= portalURI +
defaultDashboardPage
%>"><%=_ctx.appRes("UIUserToolBarDashboardPortlet.header.dashboard")%></a>
</div>
<% renderDashboards(); %>
</div>
Modified:
portal/trunk/portlet/exoadmin/src/main/webapp/groovy/admintoolbar/webui/component/UIUserToolBarGroupPortlet.gtmpl
===================================================================
---
portal/trunk/portlet/exoadmin/src/main/webapp/groovy/admintoolbar/webui/component/UIUserToolBarGroupPortlet.gtmpl 2011-02-22
15:47:32 UTC (rev 5919)
+++
portal/trunk/portlet/exoadmin/src/main/webapp/groovy/admintoolbar/webui/component/UIUserToolBarGroupPortlet.gtmpl 2011-02-23
06:42:19 UTC (rev 5920)
@@ -87,7 +87,7 @@
<div class="TabsContainer">
<div class="UITab NormalToolbarTab">
<div class="">
- <a class="GroupIcon TBIcon" href="<%= portalURI +
"groupnavigation" %>">Group</a>
+ <a class="GroupIcon TBIcon" href="<%= portalURI +
"groupnavigation"
%>"><%=_ctx.appRes("UIUserToolBarGroupPortlet.header.group")%></a>
</div>
<% if (!groupNavigations.isEmpty()) { %>
<div style="display:none" class="MenuItemContainer">
Modified:
portal/trunk/portlet/exoadmin/src/main/webapp/groovy/admintoolbar/webui/component/UIUserToolBarSitePortlet.gtmpl
===================================================================
---
portal/trunk/portlet/exoadmin/src/main/webapp/groovy/admintoolbar/webui/component/UIUserToolBarSitePortlet.gtmpl 2011-02-22
15:47:32 UTC (rev 5919)
+++
portal/trunk/portlet/exoadmin/src/main/webapp/groovy/admintoolbar/webui/component/UIUserToolBarSitePortlet.gtmpl 2011-02-23
06:42:19 UTC (rev 5920)
@@ -130,7 +130,7 @@
<div class="UITab NormalToolbarTab">
<div class="">
<a class="SitesIcon TBIcon" href="<%= portalURI +
"portalnavigation" %>">
- Site
+ <%=_ctx.appRes("UIUserToolBarSitePortlet.header.site")%>
</a>
</div>
<% renderPortalNavigations() %>
Modified:
portal/trunk/portlet/exoadmin/src/main/webapp/skin/applicationregistry/webui/component/UIApplicationRegistryPortlet/DefaultStylesheet.css
===================================================================
---
portal/trunk/portlet/exoadmin/src/main/webapp/skin/applicationregistry/webui/component/UIApplicationRegistryPortlet/DefaultStylesheet.css 2011-02-22
15:47:32 UTC (rev 5919)
+++
portal/trunk/portlet/exoadmin/src/main/webapp/skin/applicationregistry/webui/component/UIApplicationRegistryPortlet/DefaultStylesheet.css 2011-02-23
06:42:19 UTC (rev 5920)
@@ -483,7 +483,7 @@
/******************************** UIGadgetManagement ******************************/
.UIApplicationRegistryPortlet .UIGadgetManagement .PortletIcons {
- width: 150px; height: 120px;
+ width: 150px;
padding-top: 20px; text-align: center;
}
Modified:
portal/trunk/portlet/web/src/main/webapp/skin/portal/webui/component/UILogoPortlet/DefaultStylesheet.css
===================================================================
---
portal/trunk/portlet/web/src/main/webapp/skin/portal/webui/component/UILogoPortlet/DefaultStylesheet.css 2011-02-22
15:47:32 UTC (rev 5919)
+++
portal/trunk/portlet/web/src/main/webapp/skin/portal/webui/component/UILogoPortlet/DefaultStylesheet.css 2011-02-23
06:42:19 UTC (rev 5920)
@@ -75,7 +75,7 @@
}
.UILogoPortlet a:hover {
- color: #e7e7e7;
+ color: #058ee6;
}
.UILogoPortlet .Name {
Modified:
portal/trunk/web/eXoResources/src/main/webapp/javascript/eXo/gadget/ExoBasedUserPrefStore.js
===================================================================
---
portal/trunk/web/eXoResources/src/main/webapp/javascript/eXo/gadget/ExoBasedUserPrefStore.js 2011-02-22
15:47:32 UTC (rev 5919)
+++
portal/trunk/web/eXoResources/src/main/webapp/javascript/eXo/gadget/ExoBasedUserPrefStore.js 2011-02-23
06:42:19 UTC (rev 5920)
@@ -31,6 +31,7 @@
gadgets.ExoBasedUserPrefStore.prototype.savePrefs = function(gadget, newPrefs) {
//TODO: dang.tung - sent event to portal
var prefs = eXo.core.JSON.stringify(newPrefs || gadget.userPrefs_);
+ prefs = encodeURIComponent(prefs);
var DOMUtil = eXo.core.DOMUtil;
var gadget = document.getElementById("gadget_" + gadget.id) ;
if(gadget != null ) {
Modified: portal/trunk/web/eXoResources/src/main/webapp/javascript/eXo/gadget/Gadgets.js
===================================================================
---
portal/trunk/web/eXoResources/src/main/webapp/javascript/eXo/gadget/Gadgets.js 2011-02-22
15:47:32 UTC (rev 5919)
+++
portal/trunk/web/eXoResources/src/main/webapp/javascript/eXo/gadget/Gadgets.js 2011-02-23
06:42:19 UTC (rev 5920)
@@ -762,26 +762,16 @@
}
}
this.setUserPrefs(prefs);
+ this.refresh();
};
-gadgets.IfrGadget.prototype.setUserPrefs = function(newUserPrefs) {
- gadgets.IfrGadget.superClass_.setUserPrefs.call(this, newUserPrefs);
- this.refresh();
-};
-
-gadgets.IfrGadget.prototype.setUserPref = function(name, value) {
- gadgets.IfrGadget.superClass_.setUserPref.call(this, name, value);
- this.refresh();
-};
-
gadgets.IfrGadget.prototype.handleCancelUserPrefs = function() {
this.hideUserPrefsDialog();
};
gadgets.IfrGadget.prototype.refresh = function() {
var iframeId = this.getIframeId();
- if (document.getElementById(iframeId))
- document.getElementById(iframeId).src = this.getIframeUrl();
+ document.getElementById(iframeId).src = this.getIframeUrl();
};
Modified:
portal/trunk/web/eXoResources/src/main/webapp/skin/DefaultSkin/webui/component/UIBarDecorator/UIAction/Stylesheet.css
===================================================================
---
portal/trunk/web/eXoResources/src/main/webapp/skin/DefaultSkin/webui/component/UIBarDecorator/UIAction/Stylesheet.css 2011-02-22
15:47:32 UTC (rev 5919)
+++
portal/trunk/web/eXoResources/src/main/webapp/skin/DefaultSkin/webui/component/UIBarDecorator/UIAction/Stylesheet.css 2011-02-23
06:42:19 UTC (rev 5920)
@@ -124,18 +124,32 @@
padding: 0px 4px;
}
-.UIAction .SimpleStyle1 .ButtonMiddle .PageProfileIcon {
- background: transparent url(background/PageProfileIcon.gif) no-repeat left; /*
orientation=lt */
- background: transparent url(background/PageProfileIcon.gif) no-repeat right; /*
orientation=rt */
- line-height: 20px;
- padding-left: 22px; /* orientation=lt */
- padding-right: 22px; /* orientation=rt */
-}
-
-.UIAction .SimpleStyle1 .ButtonMiddle .ViewAsBlockIcon {
- background: transparent url(background/ViewAsBlockIcon.gif) no-repeat left; /*
orientation=lt */
- background: transparent url(background/ViewAsBlockIcon.gif) no-repeat right; /*
orientation=rt */
- line-height: 20px;
- padding-left: 22px; /* orientation=lt */
- padding-right: 22px; /* orientation=rt */
+.UIAction .SimpleStyle1 .ButtonMiddle .PageProfileIcon {
+ background: transparent url(background/PageProfileIcon.gif) no-repeat left; /*
orientation=lt */
+ background: transparent url(background/PageProfileIcon.gif) no-repeat right; /*
orientation=rt */
+ line-height: 20px;
+ padding-left: 22px; /* orientation=lt */
+ padding-right: 22px; /* orientation=rt */
+ white-space: nowrap;
}
+
+.UIAction .SimpleStyle1 .ButtonMiddle .ViewAsBlockIcon {
+ background: transparent url(background/ViewAsBlockIcon.gif) no-repeat left; /*
orientation=lt */
+ background: transparent url(background/ViewAsBlockIcon.gif) no-repeat right; /*
orientation=rt */
+ line-height: 20px;
+ padding-left: 22px; /* orientation=lt */
+ padding-right: 22px; /* orientation=rt */
+ white-space: nowrap;
+}
+
+.UIAction .portlet-form-button {
+ -moz-border-radius: 0px;
+ background: none;
+ border: none;
+ display: block;
+ line-height: auto;
+ margin: 0px 3px;
+ padding: 0px;
+ text-align: center;
+ white-space: nowrap;
+}
Modified:
portal/trunk/webui/portal/src/main/java/org/exoplatform/portal/application/PortalRequestContext.java
===================================================================
---
portal/trunk/webui/portal/src/main/java/org/exoplatform/portal/application/PortalRequestContext.java 2011-02-22
15:47:32 UTC (rev 5919)
+++
portal/trunk/webui/portal/src/main/java/org/exoplatform/portal/application/PortalRequestContext.java 2011-02-23
06:42:19 UTC (rev 5920)
@@ -450,9 +450,9 @@
List<String> markupHeaders = new ArrayList<String>();
if (extraMarkupHeaders != null && !extraMarkupHeaders.isEmpty())
{
- StringWriter sw = new StringWriter();
for (Element element : extraMarkupHeaders)
{
+ StringWriter sw = new StringWriter();
DOMSerializer.serialize(element, sw);
markupHeaders.add(sw.toString());
}
Modified:
portal/trunk/webui/portal/src/main/java/org/exoplatform/portal/webui/application/UIPortlet.java
===================================================================
---
portal/trunk/webui/portal/src/main/java/org/exoplatform/portal/webui/application/UIPortlet.java 2011-02-22
15:47:32 UTC (rev 5919)
+++
portal/trunk/webui/portal/src/main/java/org/exoplatform/portal/webui/application/UIPortlet.java 2011-02-23
06:42:19 UTC (rev 5920)
@@ -935,10 +935,12 @@
{
producedOfferedPortlet =
portletInvoker.getPortlet(producerOfferedPortletContext);
}
- catch (NoSuchPortletException nspe)
+ catch (Exception exp)
{
+ // Whenever couldn't invoke the portlet object, set the request
portlet to null for the error tobe
+ // properly handled and displayed when the portlet is rendered
producedOfferedPortlet = null;
- nspe.printStackTrace();
+ exp.printStackTrace();
}
this.adapter = adapter;
Modified:
portal/trunk/webui/portal/src/main/java/org/exoplatform/portal/webui/application/UIPortletLifecycle.java
===================================================================
---
portal/trunk/webui/portal/src/main/java/org/exoplatform/portal/webui/application/UIPortletLifecycle.java 2011-02-22
15:47:32 UTC (rev 5919)
+++
portal/trunk/webui/portal/src/main/java/org/exoplatform/portal/webui/application/UIPortletLifecycle.java 2011-02-23
06:42:19 UTC (rev 5920)
@@ -303,6 +303,10 @@
markup =
Text.create(context.getApplicationResourceBundle().getString("UIPortlet.message.RuntimeError"));
}
}
+ else
+ {
+ uicomponent.setConfiguredTitle(null);
+ }
}
}
catch (Exception e)
Modified:
portal/trunk/webui/portal/src/main/java/org/exoplatform/portal/webui/portal/UIPortalComponentActionListener.java
===================================================================
---
portal/trunk/webui/portal/src/main/java/org/exoplatform/portal/webui/portal/UIPortalComponentActionListener.java 2011-02-22
15:47:32 UTC (rev 5919)
+++
portal/trunk/webui/portal/src/main/java/org/exoplatform/portal/webui/portal/UIPortalComponentActionListener.java 2011-02-23
06:42:19 UTC (rev 5920)
@@ -419,23 +419,29 @@
RemindPasswordTokenService tokenService =
uiPortal.getApplicationComponent(RemindPasswordTokenService.class);
String tokenId =
event.getRequestContext().getRequestParameter("tokenId");
+ WebuiRequestContext requestContext = event.getRequestContext();
GateInToken token = tokenService.getToken(tokenId);
if (token == null)
{
- WebuiRequestContext requestContext = event.getRequestContext();
requestContext.getUIApplication()
.addMessage(new
ApplicationMessage("UIForgetPassword.msg.expration", null));
requestContext.addUIComponentToUpdateByAjax(uiPortal.getParent());
return;
}
- UIPortalApplication uiApp =
uiPortal.getAncestorOfType(UIPortalApplication.class);
- UIMaskWorkspace uiMaskWS =
uiApp.getChildById(UIPortalApplication.UI_MASK_WS_ID);
-
OrganizationService orgSrc =
uiPortal.getApplicationComponent(OrganizationService.class);
// get user
User user =
orgSrc.getUserHandler().findUserByName(token.getPayload().getUsername());
+ if (user == null)
+ {
+ requestContext.getUIApplication()
+ .addMessage(new
ApplicationMessage("UIForgetPassword.msg.user-delete", null));
+ return;
+ }
+ UIPortalApplication uiApp =
uiPortal.getAncestorOfType(UIPortalApplication.class);
+ UIMaskWorkspace uiMaskWS =
uiApp.getChildById(UIPortalApplication.UI_MASK_WS_ID);
+
UIResetPassword uiReset = uiMaskWS.createUIComponent(UIResetPassword.class,
null, null);
uiReset.setUser(user);
uiReset.setTokenId(tokenId);