1. OFBiz
  2. OFBIZ-2507

Sort options in form fields by their visible description (also if localized)


    • Type: Improvement Improvement
    • Status: Open
    • Priority: Major Major
    • Resolution: Unresolved
    • Affects Version/s: Trunk
    • Fix Version/s: None
    • Component/s: framework
    • Labels:
    • Sprint:
      Bug Crush Event - 21/2/2015


      Currently, when options are shown in drop-down fields we can use entity-order-by to sort the options by e.g. description.

      But the order in which options appear is only valid for non-localized descriptions.

      If we have localized descriptions we want to make sure that these also appear in order, otherwise we make it difficult for the user to find the desired option especially in drop-down fields with many options.

      Btw i consider this major because for users who do not use the default language:

      • the presentation is non-standard and a usability obstacle
      • it's simply a real pain to look for an option in 'strangely-ordered' drop-downs

      Proposed Solution

      My proposal is to have a default ordering based on the description value of the OptionValue key-description-pairs in ModelFormField.java.

      The advantage of doing this is that you get what you'd normally expect, by default, in any drop-down field without even having to tell the system to order by description. An implementation should of course respect entity-order-by if present.


        Sharan Foga made changes -
        Rank Ranked higher
        Sharan Foga made changes -
        Rank Ranked higher
        Sharan Foga made changes -
        Rank Ranked higher
        Sharan Foga made changes -
        Sprint Bug Crush Event - 21/2/2015 [ 91 ]
        Jacopo Cappellato made changes -
        Fix Version/s Trunk [ 12311928 ]
        Gavin made changes -
        Workflow jira [ 12464096 ] OFbiz Workflow [ 12506973 ]
        Karim Rahimpur made changes -
        Field Original Value New Value
        Attachment ModelFormField.java.patch [ 12408796 ]
        Karim Rahimpur created issue -


          • Assignee:
            Karim Rahimpur
          • Votes:
            0 Vote for this issue
            0 Start watching this issue


            • Created: