Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Bug : onchange modification of selection does not work #19

Open
lucaslaurent04 opened this issue Jan 8, 2025 · 0 comments
Open

Bug : onchange modification of selection does not work #19

lucaslaurent04 opened this issue Jan 8, 2025 · 0 comments

Comments

@lucaslaurent04
Copy link

When modifying selection in onchange method of a Model, the select options are not updated.

Note:

  • Modification of the value work.
public static function onchange($event, $values) {
    $result = [];
    if(isset($event['type'])) {
         $result['subtype'] = [
             'value' => MAP_TYPES_SUBTYPES[$event['type']][0],
             'selection' => MAP_TYPES_SUBTYPES[$event['type']]
         ];
    }

    return $result;
}

In the example above the value is updated in the front-end but not the selection.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant