Expand my Community achievements bar.

Don’t miss the AEM Skill Exchange in SF on Nov 14—hear from industry leaders, learn best practices, and enhance your AEM strategy with practical tips.
SOLVED

AutoComplete in Page dailog with custom request.

Avatar

Level 2

Hello All,

 

I have requirement  where in I need to show dropdown list in autocomplete filed.

Screen Shot 2022-12-15 at 4.39.06 PM.png

 I have a json file in the repo. which provids the search result. in this case I have to filter the search text in the json and recivie the required data and show in the dropdown. 

With datasource i am not able to acchive this because datasource will load the data on dailog load. But here i have to load the data based on the search text. 

Please help on this.

 

Thanks.

1 Accepted Solution

Avatar

Correct answer by
Community Advisor

Hi @Naresh536 

To achieve this functionality, you would need to use a jQuery plug-in that supports this - something like:

https://jqueryui.com/autocomplete/

 

check this .This may help you .

 

Thanks

View solution in original post

3 Replies

Avatar

Community Advisor

@Naresh536 yes you can achieve this with custom code..please refer to one of our AEM experts @arunpatidar blog for the same.

 

https://aemlab.blogspot.com/2018/08/searchfilter-touch-ui-dialog-dropdown.html?m=1

 

 

 

Avatar

Level 2

Hi @Shashi_Mulugu ,

 

This code is not working. let me explain my query again. 

When i type any character in dailog a rest call will trigger and get the data with search matched values and show it on the dropdown. 

(In previous ask I mentioned json is availale in repo). The josn is huge with multiple childs.

which can't be loaded.  How can be achicve this?

 

In this below example the json will be loaded on dailog load only. 

https://aemlab.blogspot.com/2018/08/searchfilter-touch-ui-dialog-dropdown.html?m=1

 

hope this clarifies.

 

Thanks.

 

 

 

 

 

Avatar

Correct answer by
Community Advisor

Hi @Naresh536 

To achieve this functionality, you would need to use a jQuery plug-in that supports this - something like:

https://jqueryui.com/autocomplete/

 

check this .This may help you .

 

Thanks