Author: ips
Date: 2009-04-06 17:23:13 -0400 (Mon, 06 Apr 2009)
New Revision: 277
Modified:
trunk/core/src/main/webapp/WEB-INF/classes/messages.properties
trunk/core/src/main/webapp/secure/categorySummary.xhtml
trunk/core/src/main/webapp/secure/resourceTypeSummary.xhtml
Log:
require confirmation when user clicks the DELETE button on a Resource subcategory Summary
page (
https://jira.jboss.org/jira/browse/EMBJOPR-91)
Modified: trunk/core/src/main/webapp/WEB-INF/classes/messages.properties
===================================================================
--- trunk/core/src/main/webapp/WEB-INF/classes/messages.properties 2009-04-04 16:58:23 UTC
(rev 276)
+++ trunk/core/src/main/webapp/WEB-INF/classes/messages.properties 2009-04-06 21:23:13 UTC
(rev 277)
@@ -103,6 +103,7 @@
summary.category.type=Type
summary.category.types=Types
+summary.category.confirmDelete=Are you sure you want to delete this Resource?
#Messages for resourceInstanceMetrics.xhtml
metrics.resourceInstance.title=Metrics
Modified: trunk/core/src/main/webapp/secure/categorySummary.xhtml
===================================================================
--- trunk/core/src/main/webapp/secure/categorySummary.xhtml 2009-04-04 16:58:23 UTC (rev
276)
+++ trunk/core/src/main/webapp/secure/categorySummary.xhtml 2009-04-06 21:23:13 UTC (rev
277)
@@ -117,8 +117,10 @@
<h:outputText value="#{resourceItem.availability}"/>
</rich:column>
<rich:column>
+ <ui:param name="confirmDeleteMessage"
value="#{messages['summary.category.confirmDelete']}"/>
<s:button id="removeButton"
action="#{resourceCRUDAction.removeResourceAction()}" value="Delete"
+ onclick="if
(!confirm('#{confirmDeleteMessage}')) return false;"
styleClass="buttonsmall"
rendered="#{resourceItem.resource.resourceType.deletable}">
<f:param name="resourceId"
value="#{resourceItem.resource.id}"/>
Modified: trunk/core/src/main/webapp/secure/resourceTypeSummary.xhtml
===================================================================
--- trunk/core/src/main/webapp/secure/resourceTypeSummary.xhtml 2009-04-04 16:58:23 UTC
(rev 276)
+++ trunk/core/src/main/webapp/secure/resourceTypeSummary.xhtml 2009-04-06 21:23:13 UTC
(rev 277)
@@ -108,7 +108,7 @@
<ui:param name="confirmDeleteMessage"
value="#{messages['summary.resourceType.confirmDelete']}"/>
<s:button id="removeButton"
action="#{resourceCRUDAction.removeResourceAction()}" value="Delete"
- onclick="if
(!confirm('#{confirmDeleteMessage}')) return false"
+ onclick="if
(!confirm('#{confirmDeleteMessage}')) return false;"
rendered="#{resourceItem.resource.resourceType.deletable}"
styleClass="buttonsmall">
<f:param name="resourceId"
value="#{resourceItem.resource.id}"/>