Author: nbelaevski
Date: 2008-03-25 16:00:55 -0400 (Tue, 25 Mar 2008)
New Revision: 7236
Modified:
trunk/ui/suggestionbox/src/main/java/org/richfaces/component/UISuggestionBox.java
Log:
http://jira.jboss.com/jira/browse/RF-2576
Modified:
trunk/ui/suggestionbox/src/main/java/org/richfaces/component/UISuggestionBox.java
===================================================================
---
trunk/ui/suggestionbox/src/main/java/org/richfaces/component/UISuggestionBox.java 2008-03-25
19:24:14 UTC (rev 7235)
+++
trunk/ui/suggestionbox/src/main/java/org/richfaces/component/UISuggestionBox.java 2008-03-25
20:00:55 UTC (rev 7236)
@@ -423,19 +423,24 @@
FacesContext context = getFacesContext();
setupValue(context);
- Object modelValues = getModelValuesData();
- Object requestedData = getRequestedValuesData();
AjaxContext ajaxContext = AjaxContext.getCurrentInstance(context);
- if (null != modelValues || null != requestedData) {
- Map<String,Object> map = new HashMap<String, Object>();
- map.put("suggestionObjects", modelValues);
-
- if (requestedData != null) {
- map.put("requestedObjects", requestedData);
+
+ if (this.isUsingSuggestObjects()) {
+ Object modelValues = getModelValuesData();
+ Object requestedData = getRequestedValuesData();
+
+ if (null != modelValues || null != requestedData) {
+ Map<String,Object> map = new HashMap<String, Object>();
+ map.put("suggestionObjects", modelValues);
+
+ if (requestedData != null) {
+ map.put("requestedObjects", requestedData);
+ }
+
+ ajaxContext.setResponseData(map);
}
-
- ajaxContext.setResponseData(map);
}
+
AjaxRendererUtils.addRegionsFromComponent(this, context);
AjaxRendererUtils.addRegionByName(context, this, this.getId());
// setSubmitted(true);