I'm trying to fire a meteor event by clicking on a button inside a bootstrap popover window. However, the event is not getting fired.
Here is my code:
<button name="newLetter" class="glyphicon glyphicon-plus newLetter" type="button" data-container="body" data-toggle="popover" data-placement="right"></button>
<div id="popover-content" class="hide">
<textarea></textarea>
<button class='glyphicon glyphicon-ok btn btn-success btn-xs addNewLetter'></button>
</div>
Template.templateName.events({
'click .newLetter': function(e, t) {
$(".newLetter").popover({
html: true,
title: 'New Letter',
content: function() {
return $("#popover-content").html();
}
});
},
'click .addNewLetter': function(e, t) {
console.log('test');
}
});
Any help would be greatly appreciated.