Open Framnk opened 9 years ago
@Framnk did you have any luck resolving this?
It seams to be fixed by the following commit https://github.com/comerc/meteor-autoform-typeahead/commit/b7dc031c5cf4621e8fea4a1d5f490eaeab819c60 @comerc : hi, would you have some time to build a new package and push it to atmosphere? It would save us from doing a git clone and all this stuff... Thanks a lot!!
I have a field I want to use as a typeahead in my form schemas which is defined as follows:
selected: { type: String, label: 'User', optional: false, autoform: { type: "typeahead", options: function () { return Users.find({name: {$ne:null}}).map(function (d) { return {label: d.name, value: d._id}; }); }, }
However when the typeahead is rendered it uses only the value from the returned select options. Is there a way to allow the displayed value to be the label and what is actually submitted be the value? (Similar to a select).
Note: this options syntax is currently what is shown on the auto form 'demo' site for using this plugin