BoldDesk®Customer service software offering ticketing, live chat, and omnichannel support, starting at $49/mo. for 10 agents. Try it for free.
// bind the Query instance to query property
public query: Query = new Query().from('Customers').select(['ContactName', 'CustomerID']).take(15); |
public onOpen(args){
...
let listElement: HTMLElement = (this.multiselectObj as any).list;
listElement.addEventListener('scroll', () => {
if ((listElement.scrollTop + listElement.offsetHeight >= listElement.scrollHeight)) {
let filterQuery = this.multiselectObj.query.clone();
this.data.executeQuery(filterQuery.range(start, end)).then((event: any) => {
start = end;
end += 5;
this.multiselectObj.addItem(event.result as { [key: string]: Object }[]);
}).catch((e: Object) => {
});
}
})
}
|
public query: Query = new Query().select(["Name", "Code"]).take(15);
public onFiltering: EmitType<FilteringEventArgs> = (e: FilteringEventArgs) => {
let char = e.text.length + 1;
let query: Query = new Query();
query = e.text !== ""? query.where("Name", "contains", e.text, true).take(char * 15) : query;
e.updateData(this.data, query);
};
|