I have a popover in my Ionic framework app with options: sharing and deleting. I need to display a confirmation popup when the delete option is selected, but I don't know how to do this.
How can I do that? Do I need to create a separate controller for popover? I already made a popup from ActionSheet, but it is somehow different.
This is the controller:
$ionicPopover.fromTemplateUrl('templates/popover.html', { scope: $scope }).then(function(popover) { $scope.popover = popover; }); // Triggered on a button click, or some other target $scope.openPopover = function($event) { $scope.popover.show($event); };
And this is the popover pattern:
<ion-popover-view style="height: 120px"> <ion-content> <div class="list"> <a class="item"> Compartir </a> <a class="item"> Eliminar </a> </div> </ion-content> </ion-popover-view>
javascript angularjs ionic-framework ionic
David prieto
source share