Files
DiceCloud/rpg-docs/client/views/character/attacks/attackEditList/attackEditList.js

19 lines
367 B
JavaScript

Template.attackEditList.helpers({
attacks: function(){
var cursor = Attacks.find({"parent.id": this.parentId, charId: this.charId});
return cursor;
}
});
Template.attackEditList.events({
"tap #addAttackButton": function(){
Attacks.insert({
charId: this.charId,
parent: {
id: this.parentId,
collection: this.parentCollection
}
});
},
});