25 lines
601 B
JavaScript
25 lines
601 B
JavaScript
|
|
|
||
|
|
import './Measures.html';
|
||
|
|
|
||
|
|
Template.Measures.helpers({
|
||
|
|
// someFunctionNameCalledByTemplate: function() {
|
||
|
|
// return something;
|
||
|
|
// }
|
||
|
|
measures: function () {
|
||
|
|
return Measures.find({});
|
||
|
|
}
|
||
|
|
});
|
||
|
|
|
||
|
|
Template.Measures.events({
|
||
|
|
// 'click .something': function() {
|
||
|
|
// Meteor.call('someMethodOnServer', this.something, someotherparam);
|
||
|
|
// Session.set('someValue', Session.get('someOtherValue'));
|
||
|
|
// console.log("Got here");
|
||
|
|
// }
|
||
|
|
|
||
|
|
'click .trash': function() {
|
||
|
|
//Calls deleteMeasure which is in the collection for Measures.
|
||
|
|
Meteor.call('deleteMeasure', this._id);
|
||
|
|
console.log("Got here");
|
||
|
|
}
|
||
|
|
});
|