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

#2857 attempt to reapply fix for dropdown #3216

Merged
merged 1 commit into from
Aug 5, 2022
Merged

Conversation

mohdali
Copy link
Member

@mohdali mohdali commented Jul 19, 2022

@sfmskywalker trying to reapply the fix for dropdown as in #2857.

Simply I'm trying to reassign the value at the end of componentWillLoad() to force the default value.

if (this.currentValue != undefined) {
      this.propertyModel.expressions[defaultSyntax] = this.currentValue;
    }

This needs to be validated with the cascading dropdown feature from @jdevillard

@jdevillard
Copy link
Contributor

The fix seems to work correctly on the cascading dropdown 👍, however, it seems to have an other issue on the first load.

image

The value of the third dropdown is undefined :
image

because the call to the api is done with only one dependand value instead of the two :
image

color depends on Brand and Model and only Model is set at the init.

If we change one dropdown, all the events/call are set correctly. It's only at init.
image

@sfmskywalker
Copy link
Member

@mohdali do you want to merge this or look at @jdevillard 's feedback first?

@mohdali
Copy link
Member Author

mohdali commented Aug 5, 2022

@mohdali do you want to merge this or look at @jdevillard 's feedback first?

Please merge, @jdevillard will create a separate PR

@sfmskywalker sfmskywalker merged commit 346a3e9 into master Aug 5, 2022
@sfmskywalker sfmskywalker deleted the dropdown-default branch August 5, 2022 12:13
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

Successfully merging this pull request may close these issues.

None yet

3 participants