Hi,
As a source for my jqxInput I have {id: number, name: string}. What I want to achieve is that when something is selected from autocomplete, I want to access this whole object, having ‘name’ as display, and ‘id’ as the value. I’m trying to set [valueMember] and [displayMember] as ‘id’ and ‘name’ correspondingly, but I’m only getting label: name and value: name again. Any suggestion on how to overcome this? Thank you
const source = {
datatype: 'json',
datafields: [
{id: 'id'},
{name: 'name'}
],
localdata: data
};
this.dataAdapter = new jqx.dataAdapter(source);
<jqxInput [source]="dataAdapter" [placeHolder]="'Search patients'"
[valueMember]="'id'" [displayMember]="'name'" (onSelect)="onSelect($event)">
</jqxInput>