Bruce7551108
Posts: 0
Joined: Sun May 24, 2015 3:56 am

Unable to have click event on a select component.

Hi,
I am not able to have a click even on a select component. Please use the link that I have my app..

http://appery.io/app/mobile-frame?src...

I have a click event for this select component just an alert to display a word. But it doesn't get triggered.

Please look into this and let me know what I am missing. Or, is this a bug?

Thanks,
Bruce

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

Unable to have click event on a select component.

Hi Bruce -

In my app works as expected and on Click event and on event Value changed.

Please try it with event Value changed and let us know the result.

Bruce7551108
Posts: 0
Joined: Sun May 24, 2015 3:56 am

Unable to have click event on a select component.

Hi Illya,
Thanks for your quick reply.

I want the click event to fire. Reason being, I will have to fill the select component with a dynamic list only after the click. Basically, I am trying to build a Master-Detail with select components with click events. I tired value change, but it doesn't fix my use-case.

Any other work-around to get the click event to fire?

If this is a bug, are you planning to fix it soon?

Thanks,
Bruce.

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

Unable to have click event on a select component.

JavaScript alert works on click event on the select component, if it created from new blank project on our side.

There could be some issues with yours particular project, I've forwarded this to our developers they will take a look, but this could take some time.

Serhii Kulibaba
Posts: 150
Joined: Tue Aug 27, 2013 1:47 pm

Unable to have click event on a select component.

Hello Bruce,

Unfortunatelly, it is the bug. But you can use workaround:

1) add handler on the "page show" event
2) set action="Run JavaScript"

pre$("[name=selectName]").closest('.ui-select').off("click").on("click", function() {
// Put any your code here
});/pre

here "selectName" - name of the select component

Bruce7551108
Posts: 0
Joined: Sun May 24, 2015 3:56 am

Unable to have click event on a select component.

Hi Sergiy,
Thank you very much for suggesting a work-around. I really appreciate that. I think we are almost there...

I actually want to invoke a database service when the select component is clicked. Could you please suggest me how I could do that?

Thanks Again,
Bruce.

Bruce7551108
Posts: 0
Joined: Sun May 24, 2015 3:56 am

Unable to have click event on a select component.

Hi Sergiy,
I tried by putting serviceInstanceName.execute({}); in the Javascript code, but it is taking me back to my login page again. Any idea why?

Thanks,
Bruce.

Alena Prykhodko
Posts: 0
Joined: Tue Apr 09, 2013 7:36 am

Unable to have click event on a select component.

Hi Bruce,

Are there any error in console?

This code executes service, make sure you do not have on service success event navigate to Login page action or so.

Bruce7551108
Posts: 0
Joined: Sun May 24, 2015 3:56 am

Unable to have click event on a select component.

Hi Alena,
Thanks for your reply. I have a "Success" mapping for this service. But I don't have any "Navigate to Login Page" action for this service.

Thanks,
Bruce.

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

Unable to have click event on a select component.

Hi Bruce -

Are you using any mapping in this service?

Please check network tab in browser dev.tools what are request/response for this service.

Return to “Issues”