You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository was archived by the owner on Apr 12, 2024. It is now read-only.
Repository navigation
This repository was archived by the owner on Apr 12, 2024. It is now read-only.
Version 1.2.15 broke functionality with select and ng-options #7855
We have some functionality where it's possible that after a select is changed, the model could end up back at the same value it was before. This worked fine up to version 1.2.14. See this fiddle: http://jsfiddle.net/k8EaA/
As the select is changed, the select shows the correct model ('c') after it is changed.
See this fiddle with version 1.2.15: http://jsfiddle.net/kdG38/
As the select is changed, it stays on what it was changed to, and doesn't reflect what's in the model.
We also have some functionality that removes certain options in certain cases. Basically, we have a few selects that all have the same options, and then don't allow the same option to be selected for the other selects. We do this by removing options that are already selected in the other selects.
This issue only seems to be a problem in IE11. In IE11, view this fiddle with version 1.2.14: http://jsfiddle.net/uLUXP/
Change the last select to AAA. All the other selects show the correct value based on the model.
See this fiddle with version 1.2.15: http://jsfiddle.net/S37Yp/
Change the last select to AAA. All the other selects now show the first option, which does not match the model.
It seems very likely that this behavior was introduced with this commit: dc149de
I tried reverting those changes locally, and then the selects work as expected.
I tried all this with the latest 1.2.18 version, and these issues still exist.
@dnchristiansen I'm having trouble understanding the real-world use case for your first issue, where you would want to always change the value back to a hard-coded value after the user has changed the input. Can you describe a situation where you would want to do this, and what you're expecting Angular to do differently?
I tried my app with this commit and the 1st issue is resolved.
I am still having some issues in my app with the 2nd issue, but the fiddle is obviously working. As the 2nd issue only happens in IE11, the 1st issue is higher priority for us. I don't have a problem with this issue being closed, and then I'll see if I can create a fiddle that shows the problem we still have in IE11. If I'm able to do that, I'll just open a new issue.
Is it safe to assume this commit will make its way into the v1.2.x branch?
As I am using the 1.2.x versions of angular, I wanted to confirm this issue was fixed with the next released version. However, the fiddles above with the latest code have definitely fixed the issue, so I will close this issue for now.
Activity
andhernand commentedon Jun 17, 2014
I have also seen the same behavior. See this fiddle: http://jsfiddle.net/andhernand/hLNF2/10/
The effects are heightened in Chrome on Android.
lgalfaso commentedon Jun 17, 2014
Hi,
Can you check is this still an issue with #7136 ?
andhernand commentedon Jun 17, 2014
The above patch does not fix the problem. I am seeing the same behavior with the patch applied.
dnchristiansen commentedon Jun 17, 2014
With that patch, I still have both the issues mentioned above.
jeffbcross commentedon Jul 1, 2014
@dnchristiansen I'm having trouble understanding the real-world use case for your first issue, where you would want to always change the value back to a hard-coded value after the user has changed the input. Can you describe a situation where you would want to do this, and what you're expecting Angular to do differently?
19 remaining items
test(select): add test against updating selected property on digest w…
test(select): add test of updating the model because of ng-change
revert(select): avoid checking option element selected properties in …
test(select): add test against updating selected property on digest w…
test(select): add test of updating the model because of ng-change
revert(select): avoid checking option element selected properties in …
test(select): add test against updating selected property on digest w…
test(select): add test of updating the model because of ng-change
Narretz commentedon Jul 31, 2014
@dnchristiansen
There's a fix (cdc7db3) in master that also fixes both regressions you posted:
http://jsfiddle.net/k8EaA/1/
http://jsfiddle.net/S37Yp/1/
Can you confirm that your issues are fixed with that?
dnchristiansen commentedon Jul 31, 2014
I tried my app with this commit and the 1st issue is resolved.
I am still having some issues in my app with the 2nd issue, but the fiddle is obviously working. As the 2nd issue only happens in IE11, the 1st issue is higher priority for us. I don't have a problem with this issue being closed, and then I'll see if I can create a fiddle that shows the problem we still have in IE11. If I'm able to do that, I'll just open a new issue.
Is it safe to assume this commit will make its way into the v1.2.x branch?
caitp commentedon Jul 31, 2014
The commit which broke it has already been reverted in v1.2.x (I think it was actually a pair of commits, so hopefully both were reverted)
dnchristiansen commentedon Jul 31, 2014
Are those v1.2.x commits in a released version? Or will they be included in the next 1.2.x version?
caitp commentedon Jul 31, 2014
they'll be released on monday I believe
dnchristiansen commentedon Aug 11, 2014
As I am using the 1.2.x versions of angular, I wanted to confirm this issue was fixed with the next released version. However, the fiddles above with the latest code have definitely fixed the issue, so I will close this issue for now.