Joe Sharples
Posts: 0
Joined: Mon Aug 18, 2014 1:31 pm

List items visible only when a user has started to type in the datafilter

Hi Guys,

I'm wanting to have the data filter for a list visible but the list items not visible.

Then when a user starts typing in the data filter I want the items to show that relate to what the user is typing.

Thanks,
Joe

Louis
Posts: 0
Joined: Wed Nov 05, 2014 2:03 pm

List items visible only when a user has started to type in the datafilter

bump - also interested if anyone knows how to.

Louis
Posts: 0
Joined: Wed Nov 05, 2014 2:03 pm

List items visible only when a user has started to type in the datafilter

Thank you, Evgene!

For anyone else who is interested:

Select your list more properties attribute codedata-filter-reveal/code and value codetrue/code add

Joe Sharples
Posts: 0
Joined: Mon Aug 18, 2014 1:31 pm

List items visible only when a user has started to type in the datafilter

Hi,

I have a list where all the response of a service is mapped dynamically.
the list is visible and the datafilter is hidden.
on button click the datafilter shows using :
Apperyio("ListName").prev(".ui-filterable").show();

I want to use the data-filter-reveal attribute so the listitem hides until a user starts typing. but i don't want to add this using 'more properties attribute data-filter-reveal and value true add' in the builder, because when the page first loads i want the list to be visible. Only when the user clicks the button to show the datafilter i want the list items to hide and only be shown when a user starts to type.

I tried using on button click.
Apperio('ListName').attr("data-filter-reveal", true);

using dev tools I can see that the attribute was successfully added. but it didnt hide the list items.

how can i make the data-filter-reveal attribute work on button click?

Thank you

Joe Sharples
Posts: 0
Joined: Mon Aug 18, 2014 1:31 pm

List items visible only when a user has started to type in the datafilter

i also tried adding:
Apperyio('ListName').listview('refresh');
but this didnt work

Joe Sharples
Posts: 0
Joined: Mon Aug 18, 2014 1:31 pm

List items visible only when a user has started to type in the datafilter

I added to button click:
$("[name=listItemName]").addClass("ui-screen-hidden");

this hides all list items until user starts to type.

Although if a user clears his search the full list shows rather than hiding.

Joe Sharples
Posts: 0
Joined: Mon Aug 18, 2014 1:31 pm

List items visible only when a user has started to type in the datafilter

I don't need a solution for this now

Return to “Issues”