Skip to content

Editable List

Screenshot

Stores a list of JSON filters as a view state within a dropdown menu. The list allows users to add or remove custom JSON filters. The component is used in conjunction with Data Filter.

Basics

Screenshot

Data Source

This is an update query which stores the JSON lists and allows users add and remove new filters

Screenshot

Update query:

{[dgAdd;dgUpd;dgDel]

/this sample requires keyed table:
/ table's key matches 'Key' in this dialog
/exampleQueries:: `id xkey ([] id:`int$();name:`symbol$();note1:`symbol$());
/ `exampleQueries upsert(0i;`dummy;`);

    if[count[dgUpd]>0;`screenerFilters upsert flip dgUpd];
    if[count[dgDel]>0;
        delete from `screenerFilters where id in (dgDel[`id])];

    /generate unique ids for new items
    if[count[dgAdd]>0;`screenerFilters upsert flip dgAdd];
}

Data sources

Dropdown
Displays JSON options in a dropdown
Selected Key
A view state parameter assigned to the dropdown, determines which JSON list is selected
Selected Value

A second view state parameter, of type string, which stores the Selected Key JSON.

Screenshot

Vertical
Positions the Editable list within the component
Show New
When enabled, user can create new filters
Show Save
User can save new filters
Show Delete
User can remove unwanted filters
Prompt to Save
When enabled, any changes made by a user will prompt a save request
Confirm Before Deleting
When enabled, any deleted list will require confirmation from the user.
Template

For building a custom layout of an Editable list

Screenshot

Format, Margins

Style for common style settings