small change to call to close tracking api
authorymh <ymh.work@gmail.com>
Mon, 25 Jul 2016 16:18:55 +0200
changeset 96 12dab8a7797c
parent 95 c8c95c522f48
child 97 0d214843d99b
small change to call to close tracking api
server/src/assets/js/mtdc-tracking-worker.js
server/src/metaeducation/static/metaeducation/js/mtdc-tracking-worker.js
--- a/server/src/assets/js/mtdc-tracking-worker.js	Mon Jul 25 15:53:48 2016 +0200
+++ b/server/src/assets/js/mtdc-tracking-worker.js	Mon Jul 25 16:18:55 2016 +0200
@@ -187,15 +187,15 @@
                 $.ajax({
                     method: 'POST',
                     url: this.trackingCloseUrl,
-                    async: false,
+                    async: true,
                     headers: {
                         'X-CSRFToken': this.csrftoken
                     },
                     data: {
                         'renkan_guid': this.renkan.project.get('id'),
                         'registration': this.registration
-                    }
-
+                    },
+                    contentType: 'application/json'
                 }).fail(function(){
                     console.log('send tracking data failed');
                 }); // this is fire and forget. Nothong tpo do on failed
--- a/server/src/metaeducation/static/metaeducation/js/mtdc-tracking-worker.js	Mon Jul 25 15:53:48 2016 +0200
+++ b/server/src/metaeducation/static/metaeducation/js/mtdc-tracking-worker.js	Mon Jul 25 16:18:55 2016 +0200
@@ -185,15 +185,15 @@
                 $.ajax({
                     method: 'POST',
                     url: this.trackingCloseUrl,
-                    async: false,
+                    async: true,
                     headers: {
                         'X-CSRFToken': this.csrftoken
                     },
                     data: {
                         'renkan_guid': this.renkan.project.get('id'),
                         'registration': this.registration
-                    }
-
+                    },
+                    contentType: 'application/json'
                 }).fail(function () {
                     console.log('send tracking data failed');
                 }); // this is fire and forget. Nothong tpo do on failed