| Author |
Message |
![[Post New]](/JForum/templates/default/images/icon_minipost_new.gif) 28/01/2008 05:06:46
|
nickarls
Joined: 14/11/2006 00:00:00
Messages: 263
Offline
|
Hi,
I have a simple selectOneRadio with partialSubmit="true" and another panel being rendered on the value. 1.6.5 updates the value OK but If I replace the libs to 1.7DR3, there is no submit when changed. Is there something that has changed between the versions?
|
|
|
 |
![[Post New]](/JForum/templates/default/images/icon_minipost_new.gif) 29/01/2008 13:44:14
|
nickarls
Joined: 14/11/2006 00:00:00
Messages: 263
Offline
|
I think it broke between DR2 and DR3 in the 1.7 line since it works on DR2 and I recall having another pre-DR3 checkout where it worked...
|
|
|
 |
![[Post New]](/JForum/templates/default/images/icon_minipost_new.gif) 29/01/2008 16:12:37
|
Baleyba
Joined: 16/11/2006 00:00:00
Messages: 110
Offline
|
Hi,
I get too this problem between these 2 versions :(
Bal.
|
JBoss 4.2.3 | Java 1.6.0_16 | IceFaces 1.8.2 |
|
|
 |
![[Post New]](/JForum/templates/default/images/icon_minipost_new.gif) 30/01/2008 00:35:14
|
nickarls
Joined: 14/11/2006 00:00:00
Messages: 263
Offline
|
Sounds like the place for a JIRA: http://jira.icefaces.org/browse/ICE-2689
|
|
|
 |
![[Post New]](/JForum/templates/default/images/icon_minipost_new.gif) 30/01/2008 17:17:19
|
yip.ng
Joined: 26/10/2004 00:00:00
Messages: 52
Offline
|
I can't seem to reproduce the problem. Please see my comments in the JIRA case. Please provide a concrete example where it does not work. Thanks.
|
|
|
 |
![[Post New]](/JForum/templates/default/images/icon_minipost_new.gif) 31/01/2008 00:45:43
|
nickarls
Joined: 14/11/2006 00:00:00
Messages: 263
Offline
|
Bal, could you comment on your scenario since mine includes both facelets includes and seam fragments and subcomponents? I'll see if I can distill a simplified example from the screen
I should have been more specific in my initial bugreport...
|
|
|
 |
![[Post New]](/JForum/templates/default/images/icon_minipost_new.gif) 31/01/2008 05:15:30
|
Baleyba
Joined: 16/11/2006 00:00:00
Messages: 110
Offline
|
Hi, sorry for my late ...
I will try to explain the problem.
It is not easy :-)
In fact it is working fine in the component-showcase because it doesn't use the valuechangeListener for the ice:selectOneRadio tag.
To test it, you can try this little code.
Code:
<ice:panelGrid id="wizardBody1" styleClass="wizardBody" cellspacing="10">
<ice:selectOneRadio id="radiosources" layout="pageDirection"
partialSubmit="true"
value="#{wizardFormBaseController.selectedSource}"
valueChangeListener="#{wizardFormBaseController.onSourceTypeValueChange}">
<f:selectItem id="DataSource"
itemLabel="value1"
itemValue="value1" />
<f:selectItem id="DataModel"
itemLabel="value2"
itemValue="value2" />
</ice:selectOneRadio>
<ice:selectOneMenu id="selection" styleClass="selectTagMenu"
partialSubmit="false" value="#{wizardFormBaseController.selectedData}"
required="true">
<f:selectItems value="#{wizardFormBaseController.dataItems}"
id="selectItemData" />
</ice:selectOneMenu>
<ice:message for="selection" style="color: red;" />
</ice:panelGrid>
On this page, "normally", when we select one radio button, it must refresh the values list into the second list.
In the 1.7.0.DR2 it was working fine.
Now it doesn't work because the valueChangeListener isn't called at the good time.
In fact I checked that the valueChangeListener of ice:selectOneRadio tag was called after the partialsubmit execution of the value selection into the ice:selectOneMenu tag.
We get the same problem with the ice:selectMultiCheckbox tag
I hope you will succeed in reproduce it because this bug disallows us to use the 1.7.0DR3 release of IceFaces library... :-(
Please keep me informed ;)
regards,
Bal.
|
JBoss 4.2.3 | Java 1.6.0_16 | IceFaces 1.8.2 |
|
|
 |
![[Post New]](/JForum/templates/default/images/icon_minipost_new.gif) 31/01/2008 17:07:53
|
yip.ng
Joined: 26/10/2004 00:00:00
Messages: 52
Offline
|
Sorry, I still couldn't reproduce the problem. I modified a component showcase example to be similar to yours:
<ice:panelGroup>
<ice:selectOneRadio value="#{selectionTags.selectedCountry}" partialSubmit="true"
valueChangeListener="#{selectionTags.countryChanged}">
<f:selectItems value="#{selectionTags.countryItems}"/>
</ice:selectOneRadio>
</ice:panelGroup>
<ice:panelGroup>
<ice:selectOneMenu value="#{selectionTags.selectedCity}" partialSubmit="false" required="true">
<f:selectItems value="#{selectionTags.cityItems}"/>
</ice:selectOneMenu>
</ice:panelGroup>
In the countryChanged() listener, the city list is refreshed like this:
if (newCountry.equals(COUNTRY_CANADA)) {
cityItems = CITIES_CANADA;
} else if (newCountry.equals(COUNTRY_USA)) {
cityItems = CITIES_USA;
} else if (newCountry.equals(COUNTRY_CHINA)) {
cityItems = CITIES_CHINA;
} else if (newCountry.equals(COUNTRY_UK)) {
cityItems = CITIES_UK;
} else if (newCountry.equals(COUNTRY_RUSSIA)) {
cityItems = CITIES_RUSSIA;
} else {
cityItems = null;
}
And it is working as expected.
Maybe you can send me your backing bean class for me to have a look.
|
|
|
 |
![[Post New]](/JForum/templates/default/images/icon_minipost_new.gif) 04/02/2008 05:24:27
|
Baleyba
Joined: 16/11/2006 00:00:00
Messages: 110
Offline
|
Hi,
thanks a lot for your help.
I will give you the code of backing bean.
First, see this little demo to see exactly the bug in situation: Bug Demo
|
JBoss 4.2.3 | Java 1.6.0_16 | IceFaces 1.8.2 |
|
|
 |
![[Post New]](/JForum/templates/default/images/icon_minipost_new.gif) 04/02/2008 05:36:32
|
Baleyba
Joined: 16/11/2006 00:00:00
Messages: 110
Offline
|
For information: we are using jboss 4.2.2. Not facelets nor seam.
Controls are on a modal popup panel on this example but we have the problem too on a non modal panel with checkboxes.
When we debug the application with myEclipse. We don't go into the valuechangelistener function ??
Here is a part of our backing bean
package com.test;
import java.util.ArrayList;
import java.util.List;
import javax.faces.event.ActionEvent;
import javax.faces.event.ValueChangeEvent;
import javax.faces.model.SelectItem;
import com.test.Controller;
import com.test.ejb.uc.manageApplication.ApplicationVO;
import com.test.ejb.uc.manageDataModel.DataModelEntityVO;
import com.test.ejb.uc.manageDataModel.DataModelVO;
import com.test.ejb.uc.manageDataSource.DataSourceVO;
import com.test.ejb.wizard.formBase.WizardTableProperties;
import com.test.jsf.manageDataSource.ManageDataSourceBusinessDelegate;
import com.test.jsf.GeneralWebDesignerController;
import com.test.jsf.manageApplication.ManageApplicationBusinessDelegate;
import com.test.jsf.manageDataModel.ManageDataModelBusinessDelegate;
public class WizardFormBaseController extends Controller
{
private boolean showWizard = false;
private String contentPanel = "page1";
private GeneralWebDesignerController generalWebDesignerController;
private ApplicationVO application;
private DataModelVO dataModel;
private List<DataSourceVO> listDataSource;
private List<DataModelVO> listDataModel;
private String selectedSource;
private List<SelectItem> dataItems = new ArrayList<SelectItem>();
private String selectedData;
private List<WizardTableProperties> listWizardTableProperties = new ArrayList<WizardTableProperties>();
public void refresh()
{
}
private void clear()
{
this.contentPanel = "page1";
this.showWizard = false;
this.application = null;
this.dataModel = null;
this.dataItems = new ArrayList<SelectItem>();
this.selectedData = null;
this.selectedSource = "DataSource";
this.listWizardTableProperties = new ArrayList<WizardTableProperties>();
}
public void launchFormBaseWizard(ApplicationVO application)
{
this.showWizard = true;
this.contentPanel = "page1";
this.application = application;
this.selectedSource = "DataSource";
this.listDataSource = ManageDataSourceBusinessDelegate.getInstance().getDataSourceList();
SelectItem item0 = new SelectItem();
item0.setLabel("");
item0.setValue(null);
this.dataItems.add(item0);
for (DataSourceVO ds : this.listDataSource)
{
SelectItem item = new SelectItem();
item.setLabel(ds.getTitle());
item.setValue(ds.getId());
this.dataItems.add(item);
}
}
public void onSourceTypeValueChange(ValueChangeEvent e)
{
this.dataItems.clear();
SelectItem item0 = new SelectItem();
item0.setLabel("");
item0.setValue(null);
this.dataItems.add(item0);
if (e.getNewValue().toString().equals("DataSource"))
{
this.listDataSource = ManageDataSourceBusinessDelegate.getInstance().getDataSourceList();
for (DataSourceVO ds : this.listDataSource)
{
SelectItem item = new SelectItem();
item.setLabel(ds.getTitle());
item.setValue(ds.getId());
this.dataItems.add(item);
}
}
else if (e.getNewValue().toString().equals("DataModel"))
{
this.listDataModel = ManageDataModelBusinessDelegate.getInstance().getDataModelListWithEntityAttribute();
for (DataModelVO ds : this.listDataModel)
{
SelectItem item = new SelectItem();
item.setLabel(ds.getTitle());
item.setValue(ds.getId());
this.dataItems.add(item);
}
}
}
public void cancelActionListener(ActionEvent e)
{
clear();
}
public boolean isShowWizard()
{
return showWizard;
}
public void setShowWizard(boolean showWizard)
{
this.showWizard = showWizard;
}
public String getContentPanel()
{
return contentPanel;
}
public void setContentPanel(String contentPanel)
{
this.contentPanel = contentPanel;
}
public GeneralWebDesignerController getGeneralWebDesignerController()
{
return generalWebDesignerController;
}
public void setGeneralWebDesignerController(GeneralWebDesignerController generalWebDesignerController)
{
this.generalWebDesignerController = generalWebDesignerController;
}
public String getSelectedSource()
{
return selectedSource;
}
public void setSelectedSource(String selectedSource)
{
this.selectedSource = selectedSource;
}
public String getSelectedData()
{
return selectedData;
}
public void setSelectedData(String selectedData)
{
this.selectedData = selectedData;
}
public List<SelectItem> getDataItems()
{
return dataItems;
}
public void setDataItems(List<SelectItem> dataItems)
{
this.dataItems = dataItems;
}
public List<WizardTableProperties> getListWizardTableProperties()
{
return listWizardTableProperties;
}
public void setListWizardTableProperties(List<WizardTableProperties> listWizardTableProperties)
{
this.listWizardTableProperties = listWizardTableProperties;
}
}
regards,
Bal
|
JBoss 4.2.3 | Java 1.6.0_16 | IceFaces 1.8.2 |
|
|
 |
![[Post New]](/JForum/templates/default/images/icon_minipost_new.gif) 04/02/2008 08:35:04
|
Baleyba
Joined: 16/11/2006 00:00:00
Messages: 110
Offline
|
Re yip.ng>
I have done your simple example under JBOSS 4.2.2 and ICEFaces 1.7.0 DR3 and I get the same problem.
I don't understand why you don't have it.. :(
|
JBoss 4.2.3 | Java 1.6.0_16 | IceFaces 1.8.2 |
|
|
 |
![[Post New]](/JForum/templates/default/images/icon_minipost_new.gif) 04/02/2008 11:19:53
|
yip.ng
Joined: 26/10/2004 00:00:00
Messages: 52
Offline
|
I was testing in Tomcat without popup panels. I will test using JBoss and popup panels later. Thanks.
|
|
|
 |
![[Post New]](/JForum/templates/default/images/icon_minipost_new.gif) 05/02/2008 10:49:12
|
Baleyba
Joined: 16/11/2006 00:00:00
Messages: 110
Offline
|
Hi,
Here is a little example project that bugs on JBOSS 4.2.2.
It is a myEclipse project.
regards
Bal.
| Filename |
test.zip |
Download
|
| Description |
|
| Filesize |
4369 Kbytes
|
| Downloaded: |
81 time(s) |
|
JBoss 4.2.3 | Java 1.6.0_16 | IceFaces 1.8.2 |
|
|
 |
![[Post New]](/JForum/templates/default/images/icon_minipost_new.gif) 06/02/2008 13:43:29
|
mark.collette

Joined: 07/02/2005 00:00:00
Messages: 1593
Offline
|
Baleyba wrote:
Hi,
Here is a little example project that bugs on JBOSS 4.2.2.
It is a myEclipse project.
regards
Bal.
I tested your project, and the valueChangeListener is getting called. It's just that you're not using ValueChangeEvent.getNewValue() but are instead using the set value from the selectOneRadio's value attribute, which is not correct. ValueChangeListeners are called at the end of Validation, but before Update Model, so the new value is not set into the bean yet, so it would still be the old value. Just use ValueChangeEvent.getNewValue() and you'll be ok.
|
|
|
 |
![[Post New]](/JForum/templates/default/images/icon_minipost_new.gif) 07/02/2008 03:28:37
|
Baleyba
Joined: 16/11/2006 00:00:00
Messages: 110
Offline
|
YAISSSEEE !!
Hi Mark!
Thanks for your help!
Sorry but I had done the project example too quickly... :(
You are perfectly right. I'm sorry.
So I corrected my example demo with the "e.getNewValue()" and I found the root of problem! :-D
In fact the bug is here with the folowing attribute: layout="pageDirection"
Please see my attached myeclipse project and you will see the bug in action.
If you remove the "layout" attribute, it is perfectly working ! But with it, partial submit don't work...
thanks for your helps !
regards
Bal.
| Filename |
bug.zip |
Download
|
| Description |
|
| Filesize |
4447 Kbytes
|
| Downloaded: |
92 time(s) |
|
JBoss 4.2.3 | Java 1.6.0_16 | IceFaces 1.8.2 |
|
|
 |
|
|