Skip to main content

Update CMS_INPUT_LIST through FS API

Comments

1 comment

  • Zendesk API User
    Author: mbergmann - 12/4/2024 20:49

    Hi, 

    concerning setting the value: no need for that complicated way via OptionProvider. You can directly use a Set of „compatible“ objects in the FormField.set(…) call. Which type is compatible depends on the definition of the INPUT_LIST: If it’s based on simple <ENTRY>s, you can use a Set of Strings, for database based entries (INCLUDE_OPTIONS type="database") a Set of entities or also a Set of Datasets etc.

    You get the values also via the FormField‘s get() method which will return a Set<Option> with Option just being a kind of „container“ for the real values - just use .getValue() on each entry. 

    The type of the returned object via that call (again) depends on the way the INPUT_LIST is configured.

    Hope this helps.

    By the way: Things like these are part of our „Developer Training Advanced“ - you can find upcoming planned schedules here - there is an English course planned in January

    Michael

    0

Please sign in to leave a comment.