Support Migration Notice: To update migrated JIRA cases click here to open a new case use www.vmware.com/go/sr | vFabric Hyperic 5.7.0 is Now Available

Hyperic HQ

Clicking add (+ icon) for Add content to this column: when "Select Portlet" is selected results in a "bad" portlet being added

Details

  • Case Links:
    none
  • Regression:
    No
  • Story Points:
    0
  • Tags:

Description

If a user doesn't select a portlet from the drop down and just clicks the add/plus icon then "bad" portlet is added. The result is

The requested resource (/portal/bad) is not available

gets displayed where the porlet should be. No remove/X icon available to remove it.

Activity

Hide
Greg Turnquist added a comment -

hq-web/src/main/webapp/portlet/AddContentControl.jsp contains the:

<select name="portlet">
<option value="bad" SELECTED><fmt:message key="dash.home.AddContent.select"/></option>
<c:forEach var="portlet" items="${availablePortlets}" >
<option value="<c:out value="${portlet}"/>"><fmt:message key="${portlet}" /></option>
</c:forEach>
</select>

...block, where a "bad" portlet can be selected. I'm trying to trace it back to a controller, where there should some sort of validation that blocks actually adding a "bad" portlet.

Show
Greg Turnquist added a comment - hq-web/src/main/webapp/portlet/AddContentControl.jsp contains the: <select name="portlet"> <option value="bad" SELECTED><fmt:message key="dash.home.AddContent.select"/></option> <c:forEach var="portlet" items="${availablePortlets}" > <option value="<c:out value="${portlet}"/>"><fmt:message key="${portlet}" /></option> </c:forEach> </select> ...block, where a "bad" portlet can be selected. I'm trying to trace it back to a controller, where there should some sort of validation that blocks actually adding a "bad" portlet.
Hide
Greg Turnquist added a comment -

Added some javascript to the JSP that causes it to not allow hitting the button until a valid choice has been made.

Show
Greg Turnquist added a comment - Added some javascript to the JSP that causes it to not allow hitting the button until a valid choice has been made.
Hide
Ryan Morgan added a comment -

Hey Greg,

That SQL will remove the settings for all users in the system. Should't we be a bit more selective?

Show
Ryan Morgan added a comment - Hey Greg, That SQL will remove the settings for all users in the system. Should't we be a bit more selective?
Hide
Greg Turnquist added a comment -

I can try to fine tune the SQL to only reset dashboards that have a "bad" portlet listed on them.

Show
Greg Turnquist added a comment - I can try to fine tune the SQL to only reset dashboards that have a "bad" portlet listed on them.
Hide
Greg Turnquist added a comment -

Make this a 4.6-only patch.

Scott, the SQL resets ALL users' dashboards. Do you need SQL that would slim it down to one selected user, or is this good enough for your situation?

Show
Greg Turnquist added a comment - Make this a 4.6-only patch. Scott, the SQL resets ALL users' dashboards. Do you need SQL that would slim it down to one selected user, or is this good enough for your situation?
Hide
Greg Turnquist added a comment -

Committed changes to master.

Show
Greg Turnquist added a comment - Committed changes to master.
Hide
David Crutchfield added a comment -

This was fixed by GregT via the 4.5.1.x merge

Show
David Crutchfield added a comment - This was fixed by GregT via the 4.5.1.x merge
Hide
Greg Turnquist added a comment -

Refined SQL to reset screens for a single user (or role):

delete from eam_crispo_array
where opt_id in (select id from eam_crispo_opt
where lower(propkey) in ('.dashcontent.portal.portlets.first', '.dashcontent.portal.portlets.second')
and crispo_id in (select crispo_id
from eam_dash_config
where name = 'name or role'
)
);

delete from eam_crispo_opt
where lower(propkey) in ('.dashcontent.portal.portlets.first', '.dashcontent.portal.portlets.second')
and crispo_id = (
select crispo_id
from eam_dash_config
where name = 'name or role'
);

Show
Greg Turnquist added a comment - Refined SQL to reset screens for a single user (or role): delete from eam_crispo_array where opt_id in (select id from eam_crispo_opt where lower(propkey) in ('.dashcontent.portal.portlets.first', '.dashcontent.portal.portlets.second') and crispo_id in (select crispo_id from eam_dash_config where name = 'name or role' ) ); delete from eam_crispo_opt where lower(propkey) in ('.dashcontent.portal.portlets.first', '.dashcontent.portal.portlets.second') and crispo_id = ( select crispo_id from eam_dash_config where name = 'name or role' );

People

Vote (0)
Watch (2)

Dates

  • Created:
    Updated:
    Resolved:
    Last comment:
    2 years, 51 weeks ago