Details
-
Type: Bug
-
Status: Closed
-
Priority: Major
-
Resolution: Fixed
-
Affects Version/s: 1.8.2-EE-GA_P02
-
Fix Version/s: 2.0.1, EE-1.8.2.GA_P03
-
Component/s: ICE-Components
-
Labels:None
-
Environment:All
Description
Scenario: There is a dataTable that uses a rowSelector. When a row is selecting a user can delete this row. After the row is deleted when a user selects a new row a PropertyNotFoundException is thrown:
Caused by: javax.el.PropertyNotFoundException: Target Unreachable, identifier 'item' resolved to null
Caused by: javax.el.PropertyNotFoundException: Target Unreachable, identifier 'item' resolved to null
-
Hide
- Case9696Example.war
- 7.87 MB
- Arran Mccullough
-
- META-INF/MANIFEST.MF 0.1 kB
- META-INF/context.xml 0.1 kB
- WEB-INF/classes/com/.../example/Item.class 1 kB
- WEB-INF/classes/.../example/TestBean.class 3 kB
- WEB-INF/faces-config.xml 0.5 kB
- WEB-INF/lib/FastInfoset.jar 281 kB
- WEB-INF/lib/backport-util-concurrent.jar 316 kB
- WEB-INF/lib/commons-beanutils.jar 223 kB
- WEB-INF/lib/commons-collections.jar 554 kB
- WEB-INF/lib/commons-digester.jar 137 kB
- WEB-INF/lib/commons-fileupload.jar 56 kB
- WEB-INF/lib/commons-logging.jar 30 kB
- WEB-INF/lib/icefaces-comps.jar 3.14 MB
- WEB-INF/lib/icefaces.jar 1.20 MB
- WEB-INF/lib/jsf-api.jar 344 kB
- WEB-INF/lib/jsf-impl.jar 802 kB
- WEB-INF/lib/jstl.jar 20 kB
- WEB-INF/lib/jxl.jar 689 kB
- WEB-INF/.../krysalis-jCharts-1.0.0-alpha-1.jar 148 kB
- WEB-INF/web.xml 3 kB
- index.jsp 0.1 kB
- main.jspx 2 kB
-
Hide
- Case9696Example.zip
- 18 kB
- Arran Mccullough
-
- Case9696Example/build.xml 3 kB
- Case9696Example/nbproject/ant-deploy.xml 2 kB
- Case9696Example/nbproject/build-impl.xml 53 kB
- Case9696Example/.../faces-config.NavData 0.2 kB
- Case9696Example/.../genfiles.properties 0.5 kB
- Case9696Example/.../private.properties 0.5 kB
- Case9696Example/nbproject/.../private.xml 0.2 kB
- Case9696Example/.../project.properties 3 kB
- Case9696Example/nbproject/project.xml 1 kB
- Case9696Example/src/conf/MANIFEST.MF 0.0 kB
- Case9696Example/src/.../example/Item.java 0.8 kB
- Case9696Example/src/.../TestBean.java 1 kB
- Case9696Example/web/index.jsp 0.1 kB
- Case9696Example/web/main.jspx 2 kB
- Case9696Example/web/META-INF/context.xml 0.1 kB
- Case9696Example/web/.../faces-config.xml 0.5 kB
- Case9696Example/web/WEB-INF/web.xml 3 kB
-
- error-stacktrace.txt
- 4 kB
- Arran Mccullough
-
- screenshot-01.png
- 155 kB
Activity
- All
- Comments
- History
- Activity
- Remote Attachments
- Subversion
Exception still occurs after fixing deselectPreviousSelection(). Now it is in processDecodes(). See screenshot 1.
Dev comment:
I believe the problem is in this method of RowSelector:
private void deselectPreviousSelection(UIData uiData, int rowindex) {
Integer[] selection = new Integer[currentSelection.size()];
currentSelection.toArray(selection);
for (int i=0; i<selection.length; i++)
uiData.setRowIndex(rowindex);
}
We have code to deselect the previously selected row, when a new row is selected. But, it's not checking if that row had since been removed. In this case, we need to check if the row is available, before calling setValue().
Show
Arran Mccullough
added a comment - Dev comment:
I believe the problem is in this method of RowSelector:
private void deselectPreviousSelection(UIData uiData, int rowindex) {
Integer[] selection = new Integer [currentSelection.size()] ;
currentSelection.toArray(selection);
for (int i=0; i<selection.length; i++)
{
uiData.setRowIndex((selection[i]).intValue());
setValue(Boolean.FALSE);
}
uiData.setRowIndex(rowindex);
}
We have code to deselect the previously selected row, when a new row is selected. But, it's not checking if that row had since been removed. In this case, we need to check if the row is available, before calling setValue().
Revision: 23792
Modified : /icefaces/trunk/icefaces/component/src/com/icesoft/faces/component/ext/RowSelector.java
Revision: 23793
Modified : /icefaces2/trunk/icefaces/compat/components/src/main/java/com/icesoft/faces/component/ext/RowSelector.java