-
Notifications
You must be signed in to change notification settings - Fork 6.7k
Typeahead with pre-populated model #203
Comments
Since mapping only occurs when an option is selected, nothing is parsing pre-loaded input. I changed |
+1 |
Definitively on my radar, in fact this is the next issue that I want to tackle. But this is a bit more complex since we can't assume that we have all the data to re-create input's text. Current binding language is very flexible so it might be that someone retrieved a complex object from a server, used it to render a label but is binding an id only. I think that the proper solution here is to let people provide input formatter (that would take model and could otput whatever formatted value); |
Typeahead shows incorrect value when it loads an existing model. Does the
where my
|
Here is the relevant line I think from source, "ui-bootstrap-tpls-0.2.0.js", line No. 1611:
|
@drozzy this is precisely what @brendanreen suggests above. More or less!! :-) |
@petebacondarwin Yes, that fixed it! Would be great to know when it's rolled into the main - so I can update ;-) |
Will be working on the fix + tests later today |
@drozzy @petebacondarwin @brendanreen Could you guys give the latest version from |
Any chance you could compile me a version with a template inside it :-) Mine are not under |
@drozzy you can grab a built SNAPSHOT version from the CI server: Don't wait too long though as it will get replaced on the next build (!). |
Opening a separate issue as per @pkozlowski-opensource here.
If the typeahead model is bound to an object prior to user input (e.g., with a server response), the typeahead shows the entire model object instead of the display value.
The text was updated successfully, but these errors were encountered: