Author: phuong_vu
Date: 2011-07-22 06:09:29 -0400 (Fri, 22 Jul 2011)
New Revision: 6914
Modified:
portal/branches/branch-GTNPORTAL-1963/web/eXoResources/src/main/webapp/javascript/eXo/webui/UIDashboard.js
Log:
GTNPORTAL-1951 Javascript error when switch View Mode during edit Dashboard page
Modified:
portal/branches/branch-GTNPORTAL-1963/web/eXoResources/src/main/webapp/javascript/eXo/webui/UIDashboard.js
===================================================================
---
portal/branches/branch-GTNPORTAL-1963/web/eXoResources/src/main/webapp/javascript/eXo/webui/UIDashboard.js 2011-07-22
04:52:05 UTC (rev 6913)
+++
portal/branches/branch-GTNPORTAL-1963/web/eXoResources/src/main/webapp/javascript/eXo/webui/UIDashboard.js 2011-07-22
10:09:29 UTC (rev 6914)
@@ -254,9 +254,12 @@
}
};
- UIDashboard.prototype.onLoad = function(windowId, canEdit) {
- var portletWindow = document.getElementById(windowId) ?
document.getElementById(windowId) : document.getElementById("UIPortlet-" +
windowId);
- if(!portletWindow) return;
+ UIDashboard.prototype.onLoad = function(windowId, canEdit) {
+ var portletWindow = document.getElementById(windowId);
+ if(!portletWindow) {
+ windowId = "UIPortlet-" + windowId;
+ portletWindow = document.getElementById(windowId);
+ }
var DOMUtil = eXo.core.DOMUtil;
var uiDashboard = DOMUtil.findFirstDescendantByClass(portletWindow, "div",
"UIDashboard");