AnsweredAssumed Answered

Component Generator vs. Selected Items

Question asked by jarrett on Apr 28, 2009
Latest reply on Apr 18, 2011 by joshijimit
I am having a hard time getting a component generator/ converter to display the correct information for multiple selects. Following this post I was able to make a working component generator and converter (I think). The component generator creates value option pair for items in a drop down list for a multiple select.

This is what works:
The details page looks great, labels are shown and not the actual values
Drop down menus on the edit page work well, and show the labels and store the value

This is what fails:
When you select an item from the drop down and it is added to the "selected items" the value and not the label is shown. Once you leave edit mode the label is shown. In edit mode on values are shown in the "Selected Items" and not the labels.

From web-client-config-custom.xml my aspect:

   <config evaluator="aspect-name" condition="yg:taxGeography">
         <separator name="sep2" display-label="Geography" component-generator="HeaderSeparatorGenerator" />
         <show-property name="yg:Geography" converter="ListOfValuesQueryConverter" component-generator="ListOfValuesQueryGenerator" />

From my model:
<!– The Constraint –>
      <constraint name="yg:CodeLabel" type="org.contezza.customConstraints.ListOfValuesQueryConstraint">
         <parameter name="allowedValues">
         <parameter name="caseSensitive"><value>true</value></parameter>

<!– The Aspect –>
      <aspect name="yg:taxGeography">
            <property name="yg:Geography">
               <constraints><constraint ref="yg:CodeLabel" /></constraints>

From my faces-config-custom.xml
        <description>Dropdown with lable and value</description>

        <description>Dropdown with lable and value</description>

Any help and insight is greatly appreciated.