From 5454a95f5badb9b83b1faa993e93e319c49c928e Mon Sep 17 00:00:00 2001 From: Seven Du Date: Tue, 30 Jul 2013 23:58:15 +0800 Subject: [PATCH] allow debug event --- htdocs/portal/assets/js/fsportal.js | 7 ++++++- htdocs/portal/index.html | 1 - 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/htdocs/portal/assets/js/fsportal.js b/htdocs/portal/assets/js/fsportal.js index ab99306846..cf9f87f1fe 100644 --- a/htdocs/portal/assets/js/fsportal.js +++ b/htdocs/portal/assets/js/fsportal.js @@ -715,10 +715,15 @@ App.usersController = Ember.ArrayController.create({ }); App.initialize(); - +var global_debug_event = false; function eventCallback(data) { console.log(data["Event-Name"]); + + if (global_debug_event) { + console.log(data); + } + if (data["Event-Name"] == "CHANNEL_CREATE") { var channel = { uuid: data["Unique-ID"], diff --git a/htdocs/portal/index.html b/htdocs/portal/index.html index d9a8d5ab51..c1e9d3cfe4 100644 --- a/htdocs/portal/index.html +++ b/htdocs/portal/index.html @@ -777,7 +777,6 @@ socket.onmessage =function(msg) { // console.log(msg.data); var data = JSON.parse(msg.data); - console.log(data["Event-Name"]); eventCallback(data); }