Skip to content

setOptions not working in select editor when function is used. #551

@stephenjgray

Description

@stephenjgray

I am using the following schema for a radio control:

    radio: {
        type: 'Radio',
        title: 'Title'
        options: function() {
            return [
                { label: 'radio 1', val: 'value1' },
                { label: 'radio2, val: 'value2'}
            ]
        }
    }

The code seems to get as far as the else if (_.isFunction(options)) block but does not make it into the renderOptions function. I have over-ridden the function in my code and replaced the block with:

    else if (_.isFunction(options)) {
        var newOptions = options();
    
        this.renderOptions(newOptions);
    }

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions