From f177511a855bbc467bd8a166ef889dba965d558d Mon Sep 17 00:00:00 2001 From: Michael Winsauer Date: Sun, 20 Jan 2019 23:47:08 +0100 Subject: [PATCH] Remove unused functions, remove debug messages --- .../src/services/CamundaService.js | 28 ++++--------------- 1 file changed, 5 insertions(+), 23 deletions(-) diff --git a/service-website/src/services/CamundaService.js b/service-website/src/services/CamundaService.js index e4e5cef..bd73ee6 100644 --- a/service-website/src/services/CamundaService.js +++ b/service-website/src/services/CamundaService.js @@ -10,7 +10,6 @@ class CamundaService { this.submitPdfForm = this.submitPdfForm.bind(this); this.delay = this.delay.bind(this); this.getPdfDownloadLink = this.getPdfDownloadLink.bind(this); - this.completeTask = this.completeTask.bind(this); } submitPdfForm(terms) { @@ -18,27 +17,25 @@ class CamundaService { terms.forEach(term => { termsValue.push({term}); }); - console.log('termsValue: ', termsValue); const submitFormUrl = 'process-definition/key/sentiment-analysis/submit-form'; const data = { variables: { terms: { value: JSON.stringify(termsValue), - type: "Json" - } - } + type: "Json", + }, + }, }; this.axiosInstance .post(submitFormUrl, data) .then(response => { const data = response.data; - console.log(data); const id = data['id']; this.getPdfDownloadLink(id) }) .catch(error => { console.log(error); - }) + }); } delay(ms) { @@ -49,8 +46,6 @@ class CamundaService { getPdfDownloadLink(id) { const downloadUrl = this.baseUrl + 'process-instance/' + id + '/variables/reportPDF/data'; - console.log('download: ' + downloadUrl); - this.axiosInstance .get(downloadUrl) .then(response => { @@ -61,20 +56,7 @@ class CamundaService { .then(() => { this.getPdfDownloadLink(id); }); - }) - } - - completeTask(id) { - const completeTaskUrl = 'task/' + id + '/complete'; - this.axiosInstance - .post(completeTaskUrl) - .then(response => { - const data = response.data; - console.log(data); - }) - .catch(error => { - console.log(error); - }) + }); } } -- 2.43.0