Uploaded image for project: 'OFBiz'
  1. OFBiz
  2. OFBIZ-13157

Add group option on drow-down in xml screen form

    XMLWordPrintableJSON

Details

    Description

      When you define a drop-down field in xml form, add new optional level with group-options to organize options.

              <field name="group">
                  <drop-down>
                      <group-options description="A">
                          <option key="A1" description="Ad1"/>
                          <option key="A2" description="Ad2"/>
                      </group-options>
                      <group-options description="B">
                          <option key="B1" description="Bd1"/>
                          <option key="B2" description="Bd2"/>
                      </group-options>
                  </drop-down>
              </field> 

      Group-options can received all type options :

              <field name="roleTypeId">
                  <drop-down>
                      <group-options description="Customer roles">
                          <entity-options entity-name="RoleType">
                              <entity-constraint name="parentType" vale="CUSTOMER"/>
                          </entity-options>
                      </group-options>
                      <group-options description="Supplier roles">
                          <entity-options entity-name="RoleType">
                              <entity-constraint name="parentType" vale="SUPPLIER"/>
                          </entity-options>
                      </group-options>
                      <group-options description="Other roles">
                          <list-options list-name="otherRoles"/>
                      </group-options>                
                  </drop-down>
              </field> 

      At this time only the drop-down is supported, group-option can works for radio and check but not implement on ftl macro library.

      Attachments

        Issue Links

          Activity

            People

              nmalin Nicolas Malin
              nmalin Nicolas Malin
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: