Aeneas McBurney
Posts: 0
Joined: Mon Jun 16, 2014 7:49 am

collapsible list only showing 1 item

I have a collapsible set being populated from a search of contacts on the phone. When ever the search results return no data it shows no collapsible items which is correct. However when I do a search after that with items returned it only shows 1 collapsible ever though there are many search results. Any idea what is happening?

Illya Stepanov
Posts: 0
Joined: Mon Mar 18, 2013 8:48 am

collapsible list only showing 1 item

Hi Aeneas --

Could you please show us mapping that you're using for your collapsible list component?

Yurii Orishchuk
Posts: 0
Joined: Fri Feb 14, 2014 8:20 am

collapsible list only showing 1 item

Hi Aeneas,

Please try following solution:

Here is workaround to get your contacts service work:

  1. Open goal page.

  2. Navigate to "Data" tab.

  3. Find "contacts" service datasource.

  4. Add "Success" event handler with type "Javascript".

  5. Use following JS code:

    pre

    var contacts = data;

    for(var i = 0; i < data&#46;length; i++){

    var contact = contacts;

    if(!contact&#46;phoneNumbers)
    contact&#46;phoneNumbers = [];
    };

    /pre

  6. Set order for this event handler to be before "mapping" event handler.

    See details: http://prntscr.com/6385hv/direct

    Regards.

Aeneas McBurney
Posts: 0
Joined: Mon Jun 16, 2014 7:49 am

collapsible list only showing 1 item

Hi,

I have tried exactly what you said but I'm getting the same result as in only 1 contact showing after 0 returned from a search.

Yurii Orishchuk
Posts: 0
Joined: Fri Feb 14, 2014 8:20 am

collapsible list only showing 1 item

Hi Aeneas,

Please check your app on errors:

  1. Activate WEINRE debugger in the app.

  2. Generate your app and install on the device.

  3. Run the app on the device.

  4. See in WEINRE debugger whether is there some errors.

Return to “Issues”