Community
cancel
Showing results for 
Search instead for 
Did you mean: 
J_S_
Beginner
44 Views

Webservice call onClick list item

Hi there, 

I’m getting stuck on how XDK handle controllers and web services calls when using visual designer.

I’m implementing, using Framework 7, a text search for a web service and can consume it, getting back the data and show in a item list (image_1 attached).

Now i’d like to handle the selected item, like ng-click, so that i’ve to pass the parameter ku_article (ex: 0042027 in image_1) to another web service in order to get back all the details of the article and display in another page.

Actually, seems there is a function in the code that is going to handle it, namely: select_entry($event, entry). 

Question is, how is possible to write my own function that call another web service taking as parameters the entry.sku_article clicked? where to implement it? should i modify select_entry($event, entry)?

Thanks again

 

Tags (2)
0 Kudos
4 Replies
PaulF_IntelCorp
Employee
44 Views

There are some excellent webinars that were produced very recently that you might want to review. See this page > https://software.intel.com/en-us/xdk/docs/webinars-videos-links and the webinar by Anjali Gola.

J_S_
Beginner
44 Views

 

Hi Paul,

I've seen all of that, the one you are suggesting have corrupted audio after minute 20 and it's not very clear.

 

 

 

 

 

Chris_P_Intel
Employee
44 Views

If you are using the Design view, then see the information in this forum reply: https://software.intel.com/en-us/forums/intel-xdk/topic/606422#comment-1855985

 

The code in that reply shows you how to add an event listener to an item, and how to use that items click handler to get the data instance associated with it.   

var entry = data_support.entry_from_$this($(this));      //entry: {title: pubDate:}

 

 

J_S_
Beginner
44 Views

Hi, 

thanks for the hint! it help a lot!!

Btw Framework7 is not showing interactivity actions for media items as well. Would be possible to add? 

Thx again!

 

 

 

Reply