When using Ionic List Item with ng-click and option-button, when you click on the option button the ng-click for the option button and the list item itself both fire. Is there a way around that?
<ion-item class="item" ng-repeat="radio in genrelist" ng-click="radio_link()">
{{radio.name}}
<ion-option-button class="button-positive" ng-if="radio.option_addToPlaylist" ng-click="addToPlaylist()">Add to Playlist</ion-option-button>
</ion-item>
So when I click on the option item , both radio_link() and addToPlaylist() fire and I only wanted the option button to fire.
@mhartington
I am using 1.2.8 but still it behaves same .
I think in your case when you are enabling icon click you disabled the item click. What if both are enabled ??
Can u plz help me to resolve this issue??
I am saying that when you click button from header and enable the delete for the list items, you cant click on your list item that is disabled, bcoz that disables the click on items. But if both things are enable you can see this issue.
@mhartington I have added the css you mentioned to style.css, however I still face the issue that both the ng-click of the list element AND the ng-click of the button fireā¦
Any ideas?
@pits Any solution? I have a similar problem if I use a <ion-item> with āng-clickā and a <ion-option-button> in it with a ng-click action. If I click on the ion-option-button the action form the io-item is executed.
I use the Ionic 1.0.0-beta14
This is still happening, if the ion-option-button has an ng-if statement inside, itāll trigger the ng-click from the option and the ng-click from the ion-item. Is there a fix to this other than the ng-show.
EDIT: IF ANYONE HAS A PROBLEM WITH THIS!!
I used ion-stop-event=āclickā. This will cancel event propagation.
Hi, i was wondering if ion-select supports click function. I did my research but i ran out of luckā¦
For an example, i need to create a function using ion-option, so when there is a particular option that is selected, it will prompt another ion-optionā¦
or should i use ngIf? cause i have a condition that under my second ion-option
if options.type == "late"
it will prompt another ion-option and display what is reasons of being late