gatein SVN: r1282 - portal/trunk/web/eXoResources/src/main/webapp/skin/DefaultSkin/portal/webui/component/view/UIToolbarContainer.
by do-not-reply@jboss.org
Author: thuy.nguyen
Date: 2010-01-14 04:38:53 -0500 (Thu, 14 Jan 2010)
New Revision: 1282
Modified:
portal/trunk/web/eXoResources/src/main/webapp/skin/DefaultSkin/portal/webui/component/view/UIToolbarContainer/Stylesheet.css
Log:
GTNPORTAL-464: IE: Error UI when login to portal with Arabic language
Modified: portal/trunk/web/eXoResources/src/main/webapp/skin/DefaultSkin/portal/webui/component/view/UIToolbarContainer/Stylesheet.css
===================================================================
--- portal/trunk/web/eXoResources/src/main/webapp/skin/DefaultSkin/portal/webui/component/view/UIToolbarContainer/Stylesheet.css 2010-01-14 09:32:20 UTC (rev 1281)
+++ portal/trunk/web/eXoResources/src/main/webapp/skin/DefaultSkin/portal/webui/component/view/UIToolbarContainer/Stylesheet.css 2010-01-14 09:38:53 UTC (rev 1282)
@@ -70,7 +70,8 @@
}
.UIToolbarContainer .UIHorizontalTabs .TabsContainer {
- height: 32px;
+ height: 32px; /* orientation=lt */
+ height: auto; /* orientation=rt */
float: left; /* orientation=lt */
float: none; /* orientation=rt */
}
14 years, 11 months
gatein SVN: r1281 - portal/trunk/web/eXoResources/src/main/webapp/skin/DefaultSkin/portal/webui/component/view/UIDashboard.
by do-not-reply@jboss.org
Author: thuy.nguyen
Date: 2010-01-14 04:32:20 -0500 (Thu, 14 Jan 2010)
New Revision: 1281
Modified:
portal/trunk/web/eXoResources/src/main/webapp/skin/DefaultSkin/portal/webui/component/view/UIDashboard/Stylesheet.css
Log:
GTNPORTAL-465: Error UI in TabsContainer of Dashboard page when change laguage to Arabic
Modified: portal/trunk/web/eXoResources/src/main/webapp/skin/DefaultSkin/portal/webui/component/view/UIDashboard/Stylesheet.css
===================================================================
--- portal/trunk/web/eXoResources/src/main/webapp/skin/DefaultSkin/portal/webui/component/view/UIDashboard/Stylesheet.css 2010-01-14 09:25:41 UTC (rev 1280)
+++ portal/trunk/web/eXoResources/src/main/webapp/skin/DefaultSkin/portal/webui/component/view/UIDashboard/Stylesheet.css 2010-01-14 09:32:20 UTC (rev 1281)
@@ -109,7 +109,8 @@
.UITabPaneDashboard .UIHorizontalTabs .AddDashboard {
background: url('background/AddDashboard.gif') no-repeat bottom;
width: 34px; height: 22px;
- float: left;
+ float: left; /* orientation=lt */
+ float: right; /* orientation=rt */
cursor: pointer;
margin-top: 4px;
}
14 years, 11 months
gatein SVN: r1280 - in portal/trunk/web: eXoResources/src/main/webapp/skin/DefaultSkin/portal/webui/component/view/UIPortalComponent and 1 other directories.
by do-not-reply@jboss.org
Author: thuy.nguyen
Date: 2010-01-14 04:25:41 -0500 (Thu, 14 Jan 2010)
New Revision: 1280
Modified:
portal/trunk/web/eXoResources/src/main/webapp/skin/DefaultSkin/portal/webui/component/UIPortalApplicationSkin.css
portal/trunk/web/eXoResources/src/main/webapp/skin/DefaultSkin/portal/webui/component/view/UIPortalComponent/Stylesheet.css
portal/trunk/web/portal/src/main/webapp/groovy/portal/webui/application/UIPortlet.gtmpl
Log:
GTNPORTAL-458: Error UI when edit portlet
Modified: portal/trunk/web/eXoResources/src/main/webapp/skin/DefaultSkin/portal/webui/component/UIPortalApplicationSkin.css
===================================================================
--- portal/trunk/web/eXoResources/src/main/webapp/skin/DefaultSkin/portal/webui/component/UIPortalApplicationSkin.css 2010-01-14 09:12:12 UTC (rev 1279)
+++ portal/trunk/web/eXoResources/src/main/webapp/skin/DefaultSkin/portal/webui/component/UIPortalApplicationSkin.css 2010-01-14 09:25:41 UTC (rev 1280)
@@ -82,7 +82,6 @@
float: left; /* orientation=rt */
}
-
.ClearFix:after {
content: ".";
display: block;
Modified: portal/trunk/web/eXoResources/src/main/webapp/skin/DefaultSkin/portal/webui/component/view/UIPortalComponent/Stylesheet.css
===================================================================
--- portal/trunk/web/eXoResources/src/main/webapp/skin/DefaultSkin/portal/webui/component/view/UIPortalComponent/Stylesheet.css 2010-01-14 09:12:12 UTC (rev 1279)
+++ portal/trunk/web/eXoResources/src/main/webapp/skin/DefaultSkin/portal/webui/component/view/UIPortalComponent/Stylesheet.css 2010-01-14 09:25:41 UTC (rev 1280)
@@ -21,7 +21,9 @@
padding: 5px;
}
-.UIPortlet .CONTROL-PORTLET {
+.UIPortlet .CONTROL-PORTLET {
+ left: 0; /* orientation=lt */
+ right: 0; /* orientation=rt */
}
.UIPortlet .CONTROL-PORTLET .Login {
@@ -301,7 +303,8 @@
.EdittingContainer .OverContainerBlock {
border: 1px solid #b8babf;
- background: none;
+ background: none;
+ height: 100%;
}
.EdittingContainer .OverContainerBlock .LeftContainerBlock {
Modified: portal/trunk/web/portal/src/main/webapp/groovy/portal/webui/application/UIPortlet.gtmpl
===================================================================
--- portal/trunk/web/portal/src/main/webapp/groovy/portal/webui/application/UIPortlet.gtmpl 2010-01-14 09:12:12 UTC (rev 1279)
+++ portal/trunk/web/portal/src/main/webapp/groovy/portal/webui/application/UIPortlet.gtmpl 2010-01-14 09:25:41 UTC (rev 1280)
@@ -129,7 +129,7 @@
<div class="WindowBarLeft">
<div class="WindowBarRight">
<div class="WindowBarCenter">
- <div class="FixHeight">
+ <div class="FixHeight ClearFix">
<%
String restoreDown = _ctx.appRes("UIPortlet.tooltip.MaximizeRestore");
@@ -231,7 +231,6 @@
%>
<div class="$portletIcon WindowPortletIcon NovaPortletIcon WindowPortletInfo"><div class="PortletName">$title</div></div>
- <div class="ClearBoth"><span></span></div>
</div>
</div>
</div>
@@ -254,10 +253,9 @@
<div class="BottomDecoratorLeft">
<div class="BottomDecoratorRight">
<div class="BottomDecoratorCenter">
- <div class="FixHeight">
+ <div class="FixHeight ClearFix">
<div class="ResizeArea" title="<%=_ctx.appRes("UIPortlet.tooltip.ResizeWindow");%>"><span></span></div>
<div class="Information"><%=_ctx.appRes("UIPortlet.lable.information");%></div>
- <div class="ClearRight"><span></span></div>
</div>
</div>
</div>
@@ -303,7 +301,7 @@
<div class="LeftBar">
<div class="RightBar">
<div class="MiddleBar">
- <div class="FixHeight">
+ <div class="FixHeight ClearFix">
<div class="DragControlArea" title="<%=_ctx.appRes("UIPortlet.tooltip.DragControl");%>" onmousedown="eXo.portal.PortalDragDrop.init.call(this,event);"><span></span></div>
<%
String portletIcon = uicomponent.getIcon();
@@ -316,7 +314,6 @@
<a href="<%=uicomponent.event("DeleteComponent","$uicomponent.id")%>" class="DeletePortletIcon" title="<%=_ctx.appRes("UIPortlet.tooltip.deletePortlet");%>"></a>
<a href="<%=uicomponent.event("EditPortlet","$uicomponent.id")%>;eXo.portal.UIPortal.changeComposerSaveButton()" class="EditPortletPropertiesIcon" title="<%=_ctx.appRes("UIPortlet.tooltip.editPortlet");%>"></a>
</div>
- <div class="ClearLeft"><span></span></div>
</div>
</div>
</div>
14 years, 11 months
gatein SVN: r1279 - in portal/trunk/web/eXoResources/src/main/webapp/skin/DefaultSkin: webui/component/UIPopup/UIPopupWindow and 1 other directory.
by do-not-reply@jboss.org
Author: thuy.nguyen
Date: 2010-01-14 04:12:12 -0500 (Thu, 14 Jan 2010)
New Revision: 1279
Modified:
portal/trunk/web/eXoResources/src/main/webapp/skin/DefaultSkin/portal/webui/component/view/UIPage/Stylesheet.css
portal/trunk/web/eXoResources/src/main/webapp/skin/DefaultSkin/webui/component/UIPopup/UIPopupWindow/Stylesheet.css
Log:
GTNPORTAL-460
Modified: portal/trunk/web/eXoResources/src/main/webapp/skin/DefaultSkin/portal/webui/component/view/UIPage/Stylesheet.css
===================================================================
--- portal/trunk/web/eXoResources/src/main/webapp/skin/DefaultSkin/portal/webui/component/view/UIPage/Stylesheet.css 2010-01-14 08:29:09 UTC (rev 1278)
+++ portal/trunk/web/eXoResources/src/main/webapp/skin/DefaultSkin/portal/webui/component/view/UIPage/Stylesheet.css 2010-01-14 09:12:12 UTC (rev 1279)
@@ -32,7 +32,8 @@
background: url('background/ViewPage.gif') no-repeat left -113px; /* orientation=lt */
background: url('background/ViewPage-rt.gif') no-repeat right -113px; /* orientation=rt */
padding: 0px 0px 0px 143px; /* orientation=lt */
- padding: 0px 143px 0px 0px; /* orientation=rt */
+ padding: 0px 143px 0px 0px; /* orientation=rt */
+ height: 100%;
}
.UIPageBody .PageLayoutDecorator .TopRightPage {
Modified: portal/trunk/web/eXoResources/src/main/webapp/skin/DefaultSkin/webui/component/UIPopup/UIPopupWindow/Stylesheet.css
===================================================================
--- portal/trunk/web/eXoResources/src/main/webapp/skin/DefaultSkin/webui/component/UIPopup/UIPopupWindow/Stylesheet.css 2010-01-14 08:29:09 UTC (rev 1278)
+++ portal/trunk/web/eXoResources/src/main/webapp/skin/DefaultSkin/webui/component/UIPopup/UIPopupWindow/Stylesheet.css 2010-01-14 09:12:12 UTC (rev 1279)
@@ -271,11 +271,11 @@
border: 1px solid #bbbcc2;
height: 50px;
}
+
+.UIPortalComposer .BCPortalComposer {
+
+}
-.UIPortalComposer .BCPortalComposer .UIAction {
- height: 50px;
-}
-
.UIPortalComposer .Bottom {
border-bottom: 1px solid #a2a3a9;
}
@@ -310,5 +310,6 @@
}
.UIPortalComposer .ResizeButton {
- width: 13px; height: 13px;
+ width: 13px; height: 13px;
+ margin: 0;
}
\ No newline at end of file
14 years, 11 months
gatein SVN: r1278 - portal/trunk/portlet/dashboard/src/main/java/org/exoplatform/dashboard/webui/component.
by do-not-reply@jboss.org
Author: tuancn
Date: 2010-01-14 03:29:09 -0500 (Thu, 14 Jan 2010)
New Revision: 1278
Modified:
portal/trunk/portlet/dashboard/src/main/java/org/exoplatform/dashboard/webui/component/UITabPaneDashboard.java
Log:
GTNPORTAL-404: the maximized portlet is still display after deleting the page
Modified: portal/trunk/portlet/dashboard/src/main/java/org/exoplatform/dashboard/webui/component/UITabPaneDashboard.java
===================================================================
--- portal/trunk/portlet/dashboard/src/main/java/org/exoplatform/dashboard/webui/component/UITabPaneDashboard.java 2010-01-14 05:59:09 UTC (rev 1277)
+++ portal/trunk/portlet/dashboard/src/main/java/org/exoplatform/dashboard/webui/component/UITabPaneDashboard.java 2010-01-14 08:29:09 UTC (rev 1278)
@@ -25,6 +25,7 @@
import org.exoplatform.portal.config.model.PageNavigation;
import org.exoplatform.portal.config.model.PageNode;
import org.exoplatform.portal.config.model.PortalConfig;
+import org.exoplatform.portal.webui.page.UIPageBody;
import org.exoplatform.portal.webui.portal.UIPortal;
import org.exoplatform.portal.webui.util.Util;
import org.exoplatform.services.log.ExoLogger;
@@ -386,6 +387,13 @@
//If the node is removed successfully, then redirect to the node specified by tab on the left
if (selectedNode != null)
{
+ // set maximizedUIComponent of UIPageBody is null if it is maximized portlet of removed page
+ UIPortal uiPortal = Util.getUIPortal();
+ UIPageBody uiPageBody = uiPortal.findFirstComponentOfType(UIPageBody.class);
+ if(uiPageBody.getMaximizedUIComponent() != null){
+ uiPageBody.setMaximizedUIComponent(null);
+ }
+
PortalRequestContext prContext = Util.getPortalRequestContext();
prContext.setResponseComplete(true);
prContext.getResponse().sendRedirect(prContext.getPortalURI() + selectedNode.getUri());
14 years, 11 months
gatein SVN: r1277 - portal/trunk/component/portal/src/main/java/org/exoplatform/portal/config.
by do-not-reply@jboss.org
Author: hoang_to
Date: 2010-01-14 00:59:09 -0500 (Thu, 14 Jan 2010)
New Revision: 1277
Modified:
portal/trunk/component/portal/src/main/java/org/exoplatform/portal/config/UserACL.java
Log:
GTNPORTAL-466: Fix error in checking edit permission
Modified: portal/trunk/component/portal/src/main/java/org/exoplatform/portal/config/UserACL.java
===================================================================
--- portal/trunk/component/portal/src/main/java/org/exoplatform/portal/config/UserACL.java 2010-01-14 04:27:54 UTC (rev 1276)
+++ portal/trunk/component/portal/src/main/java/org/exoplatform/portal/config/UserACL.java 2010-01-14 05:59:09 UTC (rev 1277)
@@ -42,6 +42,8 @@
{
public final static String EVERYONE = "Everyone";
+ public final static String MANAGER = "manager";
+
protected static Log log = ExoLogger.getLogger("organization:UserACL");
private final Collection<MembershipEntry> NO_MEMBERSHIP = Collections.emptyList();
@@ -410,8 +412,18 @@
return true;
}
String ownerType = pageNav.getOwnerType();
- if (PortalConfig.GROUP_TYPE.equals(ownerType))
+
+ if(PortalConfig.PORTAL_TYPE.equals(ownerType))
{
+ //For portal navigation, only manager of admin group has edit permission
+ String adminGroup = getAdminGroups();
+ if(adminGroup == null){
+ return false;
+ }
+ return identity.isMemberOf(adminGroup, UserACL.MANAGER);
+ }
+ else if (PortalConfig.GROUP_TYPE.equals(ownerType))
+ {
String temp = pageNav.getOwnerId().trim();
String expAdminGroup = getAdminGroups();
String expPerm = null;
@@ -438,7 +450,7 @@
}
return false;
}
-
+
private boolean hasPermission(Identity identity, Page page)
{
if (PortalConfig.USER_TYPE.equals(page.getOwnerType()))
14 years, 11 months
gatein SVN: r1276 - portal/trunk/portlet/exoadmin/src/main/java/org/exoplatform/wsrp/webui/component.
by do-not-reply@jboss.org
Author: wesleyhales
Date: 2010-01-13 23:27:54 -0500 (Wed, 13 Jan 2010)
New Revision: 1276
Modified:
portal/trunk/portlet/exoadmin/src/main/java/org/exoplatform/wsrp/webui/component/UIWsrpRegistrationDetails.java
Log:
Small tweak so proper error can be seen
Modified: portal/trunk/portlet/exoadmin/src/main/java/org/exoplatform/wsrp/webui/component/UIWsrpRegistrationDetails.java
===================================================================
--- portal/trunk/portlet/exoadmin/src/main/java/org/exoplatform/wsrp/webui/component/UIWsrpRegistrationDetails.java 2010-01-14 04:20:29 UTC (rev 1275)
+++ portal/trunk/portlet/exoadmin/src/main/java/org/exoplatform/wsrp/webui/component/UIWsrpRegistrationDetails.java 2010-01-14 04:27:54 UTC (rev 1276)
@@ -80,7 +80,7 @@
private UIFormInputBase<String> validator;
private UIGrid registrationProperties;
private static final String NAME = "name";
- static String[] FIELDS = {NAME, "description", "label", "hint"};
+ static String[] FIELDS = {"key", NAME, "description", "label", "hint"};
static String[] SELECT_ACTIONS = {"EditProperty", "DeleteProperty"};
static final String POLICY_CLASS = "policyClassName";
static final String VALIDATOR_CLASS = "validatorClassName";
@@ -114,7 +114,7 @@
registrationProperties.registerRendererFor(renderer, LocalizedString.class);
//configure the edit and delete buttons based on an id from the data list - this will also be passed as param to listener
- registrationProperties.configure(NAME, FIELDS, SELECT_ACTIONS);
+ registrationProperties.configure("key", FIELDS, SELECT_ACTIONS);
registrationProperties.getUIPageIterator().setId(REGISTRATION_PROPERTIES_ITERATOR);
registrationProperties.getUIPageIterator().setRendered(false);
addChild(registrationProperties.getUIPageIterator());
14 years, 11 months
gatein SVN: r1275 - in portal/trunk: web/portal/src/main/webapp/WEB-INF/classes/locale/portal and 1 other directory.
by do-not-reply@jboss.org
Author: wesleyhales
Date: 2010-01-13 23:20:29 -0500 (Wed, 13 Jan 2010)
New Revision: 1275
Modified:
portal/trunk/portlet/exoadmin/src/main/java/org/exoplatform/wsrp/webui/component/UIWsrpConsumerEditor.java
portal/trunk/portlet/exoadmin/src/main/java/org/exoplatform/wsrp/webui/component/UIWsrpConsumerOverview.java
portal/trunk/web/portal/src/main/webapp/WEB-INF/classes/locale/portal/webui_en.properties
Log:
Wsrp resource messages for consumer
Modified: portal/trunk/portlet/exoadmin/src/main/java/org/exoplatform/wsrp/webui/component/UIWsrpConsumerEditor.java
===================================================================
--- portal/trunk/portlet/exoadmin/src/main/java/org/exoplatform/wsrp/webui/component/UIWsrpConsumerEditor.java 2010-01-14 04:13:18 UTC (rev 1274)
+++ portal/trunk/portlet/exoadmin/src/main/java/org/exoplatform/wsrp/webui/component/UIWsrpConsumerEditor.java 2010-01-14 04:20:29 UTC (rev 1275)
@@ -25,6 +25,8 @@
import org.exoplatform.commons.utils.LazyPageList;
import org.exoplatform.container.ExoContainer;
import org.exoplatform.container.ExoContainerContext;
+import org.exoplatform.portal.application.PortalRequestContext;
+import org.exoplatform.portal.webui.portal.UIPortal;
import org.exoplatform.web.application.ApplicationMessage;
import org.exoplatform.webui.application.WebuiRequestContext;
import org.exoplatform.webui.config.annotation.ComponentConfig;
@@ -35,6 +37,7 @@
import org.exoplatform.webui.core.lifecycle.UIFormLifecycle;
import org.exoplatform.webui.event.Event;
import org.exoplatform.webui.event.EventListener;
+import org.exoplatform.webui.event.MonitorEvent;
import org.exoplatform.webui.form.UIForm;
import org.exoplatform.webui.form.UIFormInputBase;
import org.exoplatform.webui.form.UIFormStringInput;
@@ -162,26 +165,22 @@
}
consumerEditor.reset();
- //loose the popup
- //update the consumer grid/list using ajax
- //event.getRequestContext().addUIComponentToUpdateByAjax(consumerEditor.getParent().getParent().findComponentById("ConsumerSelector"));
-
- //getChild(UIAccountInputSet.class).reset();
UIPopupWindow popup = consumerEditor.getParent();
popup.setRendered(false);
popup.setShow(false);
- //create a new form, clears out the old, probably a better way
- //popup.setUIComponent(consumerOverview.createUIComponent(UIWsrpConsumerEditor.class, null, null));
+ //temp way to refresh list, should call broadcast event (below)
LazyPageList pageList = consumerOverview.createPageList(consumerOverview.getConfiguredConsumers());
UIGrid uiGrid = consumerOverview.getChild(UIGrid.class);
uiGrid.getUIPageIterator().setPageList(pageList);
+ //uiGrid.configure()
+ //try to broadcast an event back to consumerOverview to refresh grid... works but shows error
+ //PortalRequestContext portalContext = org.exoplatform.portal.webui.util.Util.getPortalRequestContext();
+ //Event<UIWsrpConsumerOverview> pnevent = new Event<UIWsrpConsumerOverview>(consumerOverview, "RefreshGrid", portalContext);
+ //consumerOverview.broadcast(pnevent, Event.Phase.PROCESS);
ctx.addUIComponentToUpdateByAjax(consumerOverview);
-
- //consumerOverview.renderUIComponent(consumerEditor.getParent().getParent().findComponentById("ConsumerSelector"));
- //ctx.sendRedirect(consumerOverview.url("wsrp"));
}
}
@@ -189,19 +188,18 @@
{
ExoContainer manager = ExoContainerContext.getCurrentContainer();
ConsumerRegistry consumerRegistry = (ConsumerRegistry)manager.getComponentInstanceOfType(ConsumerRegistry.class);
- //WSRPConsumer consumer;
UIApplication uiApp = context.getUIApplication();
try
{
consumerRegistry.createConsumer(getConsumerName(), getCacheExpiration(), getWSDLURL());
- uiApp.addMessage(new ApplicationMessage("Consumer Successfully Added", null));
+ uiApp.addMessage(new ApplicationMessage("UIWsrp.consumer.action.add.success", null));
}
catch (ConsumerException ce)
{
//todo - add to resource bundle
- uiApp.addMessage(new ApplicationMessage("Consumer already exists!", null));
+ uiApp.addMessage(new ApplicationMessage("UIWsrp.consumer.action.add.exists", null, ApplicationMessage.ERROR));
}
return true;
}
@@ -222,12 +220,11 @@
try
{
consumerRegistry.updateProducerInfo(producerInfo);
- uiApp.addMessage(new ApplicationMessage("Edit Consumer Successful!", null));
+ uiApp.addMessage(new ApplicationMessage("UIWsrp.consumer.action.edit.success", null));
}
catch (ConsumerException ce)
{
- //todo - add to resource bundle
- uiApp.addMessage(new ApplicationMessage("Edit Consumer Problem!", null));
+ uiApp.addMessage(new ApplicationMessage("UIWsrp.consumer.action.edit.fail", null, ApplicationMessage.ERROR));
}
return true;
}
Modified: portal/trunk/portlet/exoadmin/src/main/java/org/exoplatform/wsrp/webui/component/UIWsrpConsumerOverview.java
===================================================================
--- portal/trunk/portlet/exoadmin/src/main/java/org/exoplatform/wsrp/webui/component/UIWsrpConsumerOverview.java 2010-01-14 04:13:18 UTC (rev 1274)
+++ portal/trunk/portlet/exoadmin/src/main/java/org/exoplatform/wsrp/webui/component/UIWsrpConsumerOverview.java 2010-01-14 04:20:29 UTC (rev 1275)
@@ -26,6 +26,9 @@
import org.exoplatform.commons.utils.ListAccess;
import org.exoplatform.container.ExoContainer;
import org.exoplatform.container.ExoContainerContext;
+import org.exoplatform.portal.application.PortalRequestContext;
+import org.exoplatform.portal.webui.util.Util;
+import org.exoplatform.portal.webui.workspace.UIPortalApplication;
import org.exoplatform.web.application.ApplicationMessage;
import org.exoplatform.webui.application.WebuiRequestContext;
import org.exoplatform.webui.config.annotation.ComponentConfig;
@@ -233,13 +236,13 @@
if (consumer != null)
{
consumerRegistry.destroyConsumer(id);
- uiApp.addMessage(new ApplicationMessage("Consumer has been deleted.", null));
+ uiApp.addMessage(new ApplicationMessage("UIWsrp.consumer.grid.action.delete.success", null, ApplicationMessage.INFO));
consumerOverview.refreshGrid(event);
}
}
catch (Exception e)
{
- uiApp.addMessage(new ApplicationMessage("Failed to delete Consumer. Cause: " + e.getCause(), null, ApplicationMessage.ERROR));
+ uiApp.addMessage(new ApplicationMessage("UIWsrp.consumer.grid.action.delete.fail", new String[]{e.getCause().toString()}, ApplicationMessage.ERROR));
}
}
@@ -259,12 +262,12 @@
{
ConsumerRegistry registry = consumerOverview.getConsumerRegistry();
registry.deactivateConsumerWith(consumer.getProducerId());
- uiApp.addMessage(new ApplicationMessage("Consumer successfully deactivated", null));
+ uiApp.addMessage(new ApplicationMessage("UIWsrp.consumer.grid.action.deactivate.success", null));
consumerOverview.refreshGrid(event);
}
else
{
- uiApp.addMessage(new ApplicationMessage("Consumer Must be Active to Deactivate", null));
+ uiApp.addMessage(new ApplicationMessage("UIWsrp.consumer.grid.action.deactivate.fail", null));
}
}
}
@@ -284,12 +287,12 @@
{
ConsumerRegistry registry = consumerOverview.getConsumerRegistry();
registry.activateConsumerWith(consumer.getProducerId());
- uiApp.addMessage(new ApplicationMessage("Consumer successfully activated", null));
+ uiApp.addMessage(new ApplicationMessage("UIWsrp.consumer.grid.action.activate.success", null));
consumerOverview.refreshGrid(event);
}
catch (Exception e)
{
- uiApp.addMessage(new ApplicationMessage("Problem Activating Consumer: " + e.getCause(), null, ApplicationMessage.ERROR));
+ uiApp.addMessage(new ApplicationMessage("UIWsrp.consumer.grid.action.activate.fail" , new String[]{e.getCause().toString()}, ApplicationMessage.ERROR));
e.printStackTrace();
}
}
@@ -321,7 +324,7 @@
// refresh had issues, we should deactivate this consumer
registry.deactivateConsumerWith(consumer.getProducerId());
- uiApp.addMessage(new ApplicationMessage("Consumer refresh resulted in errors that need to be fixed: " + result.getStatus().toString(), null, ApplicationMessage.ERROR));
+ uiApp.addMessage(new ApplicationMessage("UIWsrp.consumer.grid.action.refresh.fail", null, ApplicationMessage.ERROR));
}
else
{
@@ -334,14 +337,14 @@
{
registry.deactivateConsumerWith(consumer.getProducerId());
}
- uiApp.addMessage(new ApplicationMessage("Consumer Refreshed Successfully", null, ApplicationMessage.INFO));
+ uiApp.addMessage(new ApplicationMessage("UIWsrp.consumer.grid.action.refresh.success", null, ApplicationMessage.INFO));
}
consumerOverview.refreshGrid(event);
}
}
catch (Exception e)
{
- uiApp.addMessage(new ApplicationMessage("Failed to refresh Consumer: " + e.getCause(), null, ApplicationMessage.ERROR));
+ uiApp.addMessage(new ApplicationMessage("UIWsrp.consumer.grid.action.refresh.fail" + e.getCause(), null, ApplicationMessage.ERROR));
e.printStackTrace();
}
}
Modified: portal/trunk/web/portal/src/main/webapp/WEB-INF/classes/locale/portal/webui_en.properties
===================================================================
--- portal/trunk/web/portal/src/main/webapp/WEB-INF/classes/locale/portal/webui_en.properties 2010-01-14 04:13:18 UTC (rev 1274)
+++ portal/trunk/web/portal/src/main/webapp/WEB-INF/classes/locale/portal/webui_en.properties 2010-01-14 04:20:29 UTC (rev 1275)
@@ -1389,4 +1389,22 @@
UIGadget.tooltip.Maximize=Maximize
UIGadget.tooltip.Unmaximize=Restore Down
UIGadget.tooltip.editGadget=Edit Gadget
-UIGadget.tooltip.deleteGadget=Delete Gadget
\ No newline at end of file
+UIGadget.tooltip.deleteGadget=Delete Gadget
+
+ ############################################################################
+ # org.exoplatform.wsrp.webui.component.UIWsrp #
+ ############################################################################
+
+UIWsrp.consumer.action.add.success=Consumer Successfully Added
+UIWsrp.consumer.action.add.exists=Consumer already exists!
+UIWsrp.consumer.action.edit.success=Edit Consumer Successful!
+UIWsrp.consumer.action.edit.fail=Edit Consumer Problem!
+UIWsrp.consumer.grid.action.delete.success=Consumer has been deleted.
+UIWsrp.consumer.grid.action.delete.fail=Failed to delete Consumer. Cause: {0}
+UIWsrp.consumer.grid.action.refresh.success=Consumer Refreshed Successfully.
+UIWsrp.consumer.grid.action.refresh.needfix=Consumer refresh resulted in errors that need to be fixed.
+UIWsrp.consumer.grid.action.refresh.fail=Failed to refresh Consumer.
+UIWsrp.consumer.grid.action.activate.success=Consumer successfully activated.
+UIWsrp.consumer.grid.action.activate.fail=Problem Activating Consumer: {0}
+UIWsrp.consumer.grid.action.deactivate.success=Consumer successfully deactivated.
+UIWsrp.consumer.grid.action.deactivate.fail=Consumer Must be Active to Deactivate.
\ No newline at end of file
14 years, 11 months
gatein SVN: r1274 - portal/trunk/portlet/exoadmin/src/main/java/org/exoplatform/organization/webui/component.
by do-not-reply@jboss.org
Author: truong.le
Date: 2010-01-13 23:13:18 -0500 (Wed, 13 Jan 2010)
New Revision: 1274
Modified:
portal/trunk/portlet/exoadmin/src/main/java/org/exoplatform/organization/webui/component/UIAccountEditInputSet.java
Log:
GTNPORTAL-246: Error occur when changing an existing e-mail
Be sure it keeps old value
Modified: portal/trunk/portlet/exoadmin/src/main/java/org/exoplatform/organization/webui/component/UIAccountEditInputSet.java
===================================================================
--- portal/trunk/portlet/exoadmin/src/main/java/org/exoplatform/organization/webui/component/UIAccountEditInputSet.java 2010-01-14 03:57:13 UTC (rev 1273)
+++ portal/trunk/portlet/exoadmin/src/main/java/org/exoplatform/organization/webui/component/UIAccountEditInputSet.java 2010-01-14 04:13:18 UTC (rev 1274)
@@ -105,6 +105,7 @@
UIApplication uiApp = context.getUIApplication();
String username = getUIStringInput(USERNAME).getValue();
User user = service.getUserHandler().findUserByName(username);
+ String oldEmail = user.getEmail();
if (user == null)
{
uiApp.addMessage(new ApplicationMessage("UIAccountInputSet.msg.user-is-deleted", null));
@@ -138,9 +139,13 @@
//Check if mail address is already used
Query query = new Query();
- query.setEmail(getUIStringInput("email").getValue());
- if (service.getUserHandler().findUsers(query).getAll().size() > 0)
+ String email = getUIStringInput("email").getValue();
+ query.setEmail(email);
+ if (service.getUserHandler().findUsers(query).getAll().size() > 0 && !oldEmail.equals(email))
{
+ //Be sure it keep old value
+ user.setEmail(oldEmail);
+ query.setEmail(oldEmail);
Object[] args = {username};
uiApp.addMessage(new ApplicationMessage("UIAccountInputSet.msg.email-exist", args));
return false;
@@ -169,5 +174,6 @@
((UIFormStringInput)password1.setValue(null)).setRendered(isChange);
((UIFormStringInput)password2.setValue(null)).setRendered(isChange);
}
+
}
14 years, 11 months
gatein SVN: r1273 - in portal/trunk: portlet/exoadmin/src/main/java/org/exoplatform/toolbar/webui/component and 1 other directories.
by do-not-reply@jboss.org
Author: hoang_to
Date: 2010-01-13 22:57:13 -0500 (Wed, 13 Jan 2010)
New Revision: 1273
Modified:
portal/trunk/component/portal/src/main/java/org/exoplatform/portal/config/UserACL.java
portal/trunk/portlet/exoadmin/src/main/java/org/exoplatform/toolbar/webui/component/UIAdminToolbarPortlet.java
portal/trunk/portlet/exoadmin/src/main/webapp/groovy/admintoolbar/webui/component/UIAdminToolbarPortlet.gtmpl
Log:
GTNPORTAL-466: Fix errors in checking permission
Modified: portal/trunk/component/portal/src/main/java/org/exoplatform/portal/config/UserACL.java
===================================================================
--- portal/trunk/component/portal/src/main/java/org/exoplatform/portal/config/UserACL.java 2010-01-14 02:56:10 UTC (rev 1272)
+++ portal/trunk/component/portal/src/main/java/org/exoplatform/portal/config/UserACL.java 2010-01-14 03:57:13 UTC (rev 1273)
@@ -248,6 +248,31 @@
{
return hasEditPermission(getIdentity(), pconfig);
}
+
+ /**
+ * This method is equivalent to <code>hasEditPermission(PortalConfig)</code>. That allows us
+ * to check edit permission on a UIPortal, without converting UIPortal into PortalConfig via
+ * PortalDataMapper.
+ *
+ * @param ownerType
+ * @param ownerId
+ * @param editPermExpression
+ * @return
+ */
+ public boolean hasEditPermissionOnPortal(String ownerType, String ownerId, String editPermExpression)
+ {
+ Identity identity = this.getIdentity();
+ if(superUser_.equals(identity.getUserId()))
+ {
+ return true;
+ }
+
+ if(PortalConfig.USER_TYPE.equals(ownerType)){
+ return identity.getUserId().equals(ownerId);
+ }
+
+ return hasPermission(identity, editPermExpression);
+ }
public boolean hasCreatePortalPermission()
{
Modified: portal/trunk/portlet/exoadmin/src/main/java/org/exoplatform/toolbar/webui/component/UIAdminToolbarPortlet.java
===================================================================
--- portal/trunk/portlet/exoadmin/src/main/java/org/exoplatform/toolbar/webui/component/UIAdminToolbarPortlet.java 2010-01-14 02:56:10 UTC (rev 1272)
+++ portal/trunk/portlet/exoadmin/src/main/java/org/exoplatform/toolbar/webui/component/UIAdminToolbarPortlet.java 2010-01-14 03:57:13 UTC (rev 1273)
@@ -21,8 +21,10 @@
import org.exoplatform.portal.config.UserACL;
import org.exoplatform.portal.config.model.PageNavigation;
+import org.exoplatform.portal.config.model.PortalConfig;
import org.exoplatform.portal.webui.page.UIPage;
import org.exoplatform.portal.webui.page.UIPageBody;
+import org.exoplatform.portal.webui.portal.UIPortal;
import org.exoplatform.portal.webui.util.Util;
import org.exoplatform.portal.webui.workspace.UIPortalApplication;
import org.exoplatform.portal.webui.workspace.UIWorkingWorkspace;
@@ -58,8 +60,8 @@
{
// A user could view the toolbar portlet iff he/she has edit permission
// either on
- // 'active' page or 'active' portal
- if (hasEditPermissionOnNavigation() || hasEditPermissionOnPage())
+ // 'active' page, 'active' portal or 'active' navigation
+ if (hasEditPermissionOnNavigation() || hasEditPermissionOnPage() || hasEditPermissionOnPortal())
{
super.processRender(app, context);
}
@@ -79,6 +81,14 @@
return userACL.hasEditPermission(selectedNavigation);
}
}
+
+ private boolean hasEditPermissionOnPortal() throws Exception
+ {
+ UIPortalApplication portalApp = Util.getUIPortalApplication();
+ UIPortal currentUIPortal = portalApp.<UIWorkingWorkspace>findComponentById(UIPortalApplication.UI_WORKING_WS_ID).findFirstComponentOfType(UIPortal.class);
+ UserACL userACL = portalApp.getApplicationComponent(UserACL.class);
+ return userACL.hasEditPermissionOnPortal(currentUIPortal.getOwnerType(), currentUIPortal.getOwner(), currentUIPortal.getEditPermission());
+ }
private boolean hasEditPermissionOnPage() throws Exception
{
Modified: portal/trunk/portlet/exoadmin/src/main/webapp/groovy/admintoolbar/webui/component/UIAdminToolbarPortlet.gtmpl
===================================================================
--- portal/trunk/portlet/exoadmin/src/main/webapp/groovy/admintoolbar/webui/component/UIAdminToolbarPortlet.gtmpl 2010-01-14 02:56:10 UTC (rev 1272)
+++ portal/trunk/portlet/exoadmin/src/main/webapp/groovy/admintoolbar/webui/component/UIAdminToolbarPortlet.gtmpl 2010-01-14 03:57:13 UTC (rev 1273)
@@ -22,6 +22,7 @@
boolean userCouldEditNavigation = uicomponent.hasEditPermissionOnNavigation();
boolean userCouldEditPage = uicomponent.hasEditPermissionOnPage();
+ boolean userCouldEditPortal = uicomponent.hasEditPermissionOnPortal();
PageNavigation selectedNav = uicomponent.getSelectedNavigation();
if (selectedNav != null) {
@@ -50,7 +51,7 @@
</div>
<% } %>
- <% if(userCouldEditNavigation){ %>
+ <% if(userCouldEditPortal){ %>
<div class="MenuItem">
<a href="javascript:ajaxGet(eXo.env.server.createPortalURL('UIWorkingWorkspace', 'EditInline', true))" title="" class="ItemIcon EditSiteIcon">$editSiteLayout</a>
</div>
14 years, 11 months