Author: jacopoc
Date: Fri Oct 19 07:04:50 2007 New Revision: 586463 URL: http://svn.apache.org/viewvc?rev=586463&view=rev Log: Misc improvements to the drop-down examples. Modified: ofbiz/trunk/framework/example/widget/example/FormWidgetExampleForms.xml Modified: ofbiz/trunk/framework/example/widget/example/FormWidgetExampleForms.xml URL: http://svn.apache.org/viewvc/ofbiz/trunk/framework/example/widget/example/FormWidgetExampleForms.xml?rev=586463&r1=586462&r2=586463&view=diff ============================================================================== --- ofbiz/trunk/framework/example/widget/example/FormWidgetExampleForms.xml (original) +++ ofbiz/trunk/framework/example/widget/example/FormWidgetExampleForms.xml Fri Oct 19 07:04:50 2007 @@ -119,11 +119,8 @@ title="Field1: optional" tooltip="This is an example of a drop-down field with allow-empty set to true: as you can see, an empty entry is automatically added."> <drop-down allow-empty="true"> - <entity-options entity-name="ExampleType" - key-field-name="exampleTypeId" - description="${description}"> - <entity-order-by field-name="description"/> - </entity-options> + <option key="Y" description="${uiLabelMap.CommonY}"/> + <option key="N" description="${uiLabelMap.CommonN}"/> </drop-down> </field> <!-- ***************** --> @@ -133,11 +130,8 @@ title="Field2: mandatory" tooltip="The same as above, but here allow-empty is set to false (the default, if not specified): as you can see, there is no empty selection."> <drop-down allow-empty="false"> <!-- allow-empty="false" is also the default value, so you can also not specify this attribute here --> - <entity-options entity-name="ExampleType" - key-field-name="exampleTypeId" - description="${description}"> - <entity-order-by field-name="description"/> - </entity-options> + <option key="Y" description="${uiLabelMap.CommonY}"/> + <option key="N" description="${uiLabelMap.CommonN}"/> </drop-down> </field> <!-- ***************** --> @@ -145,13 +139,10 @@ <!-- ***************** --> <field name="field5" title="Field5: selection of a default value from the list" - tooltip="TODO"> - <drop-down no-current-selected-key="INSPIRED"> - <entity-options entity-name="ExampleType" - key-field-name="exampleTypeId" - description="${description}"> - <entity-order-by field-name="description"/> - </entity-options> + tooltip="How to use the no-current-selected-key to select a default value from the options"> + <drop-down no-current-selected-key="N"> + <option key="Y" description="${uiLabelMap.CommonY}"/> + <option key="N" description="${uiLabelMap.CommonN}"/> </drop-down> </field> <!-- ***************** --> @@ -161,13 +152,10 @@ title="Field8: Javascript event" event="onChange" action="return alert('You have changed the value in the select box');" - tooltip="TODO"> - <drop-down allow-empty="true"> - <entity-options entity-name="ExampleType" - key-field-name="exampleTypeId" - description="${description}"> - <entity-order-by field-name="description"/> - </entity-options> + tooltip="How to use the event and action attributes (in the field element) to trigger a Javascript action (in this example a popup message when the option is changed)."> + <drop-down> + <option key="Y" description="${uiLabelMap.CommonY}"/> + <option key="N" description="${uiLabelMap.CommonN}"/> </drop-down> </field> |
Free forum by Nabble | Edit this page |