LT-293: send proper timepoint id to server when removing an association and update the view, removing this associations

This commit is contained in:
Eloízio Salgado authored and Erik Ziegler committed 2016-11-15 08:25:09 +01:00
1 parent 998cdce9fb
commit 987be26047
5 files changed
+90 -23

No files matched your search

@@ -64,3 +64,34 @@ export const storeTimepoints = (timepointData) => {
});
});
};
export const updateTimepoint = (timepointData, query) => {
console.log('updateTimepoint');
console.log(timepointData);
console.log(query);
return new Promise((resolve, reject) => {
Meteor.call('updateTimepoint', timepointData, query, (error, response) => {
if (error) {
reject(error);
} else {
resolve(response);
}
});
});
};
export const removeTimepoint = timepointData => {
console.log('removeTimepoint');
console.log(timepointData);
return new Promise((resolve, reject) => {
Meteor.call('removeTimepoint', timepointData, (error, response) => {
if (error) {
reject(error);
} else {
resolve(response);
}
});
});
};