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

onClose event triggers before onChange on single selectboxes #238

Open
remort opened this issue Jan 17, 2019 · 0 comments
Open

onClose event triggers before onChange on single selectboxes #238

remort opened this issue Jan 17, 2019 · 0 comments

Comments

@remort
Copy link

remort commented Jan 17, 2019

Affects single select boxes, not multiselect boxes because it closes by the moment user selects an option (two events happens at the same time).

If I set two actions: one for onClose action and on for onChange action of a single selectbox, onClose works first, onChange after.
This logic seems to be wrong. By the moment select box is start closing in already has to be changed with selected item on it.

For example:
I serialize and send form via ajax GET request to the server whenever select box is being closed.
But ajax send wrong data because form serialization takes old value from select box. And after onClose listener is finished, onChange is being processed and form itself within its field being updated.

Any other controls where two events happens at the same time can be affected by this bug. Check them too please.

@remort remort changed the title on single selectboxes onClose event triggers before onChange onClose event triggers before onChange on single selectboxes Jan 17, 2019
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