Skip to content
This repository was archived by the owner on Apr 12, 2024. It is now read-only.

ng-options #11762

Closed
RafaMedina-zz opened this issue Apr 29, 2015 · 7 comments
Closed

ng-options #11762

RafaMedina-zz opened this issue Apr 29, 2015 · 7 comments

Comments

@RafaMedina-zz
Copy link

Hi.

I'm working with an expression in ngOptions, AngularJS v1.4.0-rc.1.

item.SourceID group by item.SourceTypeName disable when item.disable for item in    destination.tempItemList track by item.UUID

The problem occurs when the data is changed and there is an selected element in the ngModel and this is disable in the source. It is only created with the attribute 'disabled', missing the 'selected'

Regards.

@Narretz
Copy link
Contributor

Narretz commented Apr 29, 2015

Can you please post a reproduction on plnkr.co or similar?

@RafaMedina-zz
Copy link
Author

Certainly, the structure in the app is more complex because it has inner objects which feed the select. I did a light version and it's working right.

http://plnkr.co/edit/w21eUVz4Y2gTVJqj0gqI?p=info

I'll try to reproduce the error with a complex structure, and if I get it, i'll let you know it.

Regards.

@petebacondarwin
Copy link
Contributor

I believe that you cannot select a disabled element so this would seem like the correct behaviour to me. Or am I missing something?

@Narretz
Copy link
Contributor

Narretz commented May 4, 2015

Does this happend in all browsers? There are a few similar issues, possibly because select + disabled isn't completely specced out.

@RafaMedina-zz
Copy link
Author

@petebacondarwin, the selected element isn't the disabled one. anyway I had to change to 1.3 because I started to have problems with ngOptions in a simple select too, if I modified the scope, it didn't update the dom, but if manually I selected an element in the browser, the scope was modified. And certainly I'm not sure if my js code is the problem or the angular one.
When I have time, I'll try to reproduce the error again.

@Narretz The problem happend in FF and chrome. Yep, it's a new feature.

@petebacondarwin
Copy link
Contributor

@rafamedina sorry that this is causing you a problem. I would really like to get to the bottom of what is causing your issue. My understanding is that the plunker that you supplied is not exhibiting the issue. Is that right?

@petebacondarwin petebacondarwin self-assigned this May 5, 2015
@petebacondarwin
Copy link
Contributor

Closing due to lack of response.

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

No branches or pull requests

3 participants