Details
-
Type: Bug
-
Status: Closed
-
Priority: Major
-
Resolution: Invalid
-
Affects Version/s: 1.7Beta1
-
Fix Version/s: None
-
Component/s: ICE-Components
-
Labels:None
-
Environment:All
Description
Interaction between programmer and tester, about the selectInputText component:
P: Have the selectInputText inside of a dataTable. SelectInputText has a Map that has the rendered Strings of the select items, back to the SelectItem (which holds the original value). That way if you select an item, or exactly type it in, then SelectInputText.getSelectItem() should have a valid entry. Well, I doubt that works within a dataTable.
T: SelectInputText.getSelectItem() will always get the one for the last component in the column
P: Have the selectInputText inside of a dataTable. SelectInputText has a Map that has the rendered Strings of the select items, back to the SelectItem (which holds the original value). That way if you select an item, or exactly type it in, then SelectInputText.getSelectItem() should have a valid entry. Well, I doubt that works within a dataTable.
T: SelectInputText.getSelectItem() will always get the one for the last component in the column
It is also not possible to create a datatable containing rows with selectInputText when the following conditions are met:
<ice:dataTable id="tab" var="rowvar" value="#
{myBean.someList}" ...>
{rowvar.myLabel}...
<ice:selectInputText id="ifield" width="150" value="#
" listVar="fieldItem"
{myBean.someSelectItemList}listValue="#
"
{myBean.valueChanged}valueChangeListener="#
">
{fieldItem.myLabel}<f:facet name="selectInputText">
<ice:panelGrid columns="1">
<ice:outputText id="otId" value="#
" />
</ice:panelGrid>
</f:facet>
</ice:selectInputText>
...
</ice:dataTable>
The Table iterates over a list L of objects X.
For every row the selectInputText shall be prefilled with the value of String X.getMyLabel();
The valueListener opens a list of SelectItems containing X as value and X.getMyLabel() as Label.
Problem: the displayed value of each selecInputText is now bound to each other, if L contains multiple X with the same Description (of getMyLabel()).
This results in updating all other selectInputText-rows containing the same description value. This also overwrites the currently typed OR selected value from the list making changes to the selectInputText-value impossible (except for the last row containing an equal value).
Creating a table which displays a changeable N-M relation via selectInputText is therefore not possible, while a 1-N relation would work.