3

How can I show multiple default values in a multiple choice drop-down field. Suppose a scenario, few students have chosen chemistry as optional subject. After sometime I need to add more, also I can see who have chosen the subject previously.

<default-field title="subject">
    <drop-down allow-empty="false" allow-multiple="true" >
        <list-options list="students" text="${student}"/>
    </drop-down>
</default-field>

This code always shows all the students in the drop down. I want to display few selected students already selected.

Its like updating a list. How I can do that efficiently.

Suraj Khurana
  • 392
  • 3
  • 14

1 Answers1

0

If you want to only include limited items in the drop-down just filter the list with actions in advance (in your code example the "students" list).

David E. Jones
  • 1,721
  • 1
  • 9
  • 8
  • I want to show limited items already selected. The attribute no-current-selected-key only shows one default selection but I want to display multiple default selections. – Suraj Khurana Sep 06 '14 at 06:42
  • There is no good solution for this currently in the framework, just use an inline or included Freemarker template (with the render-mode.text element). This can be used inside form fields as well as anywhere the general screen widgets can be used. – David E. Jones Sep 17 '14 at 14:19