X-Git-Url: http://git.onelab.eu/?a=blobdiff_plain;f=plugins%2Fquerycode%2Fquerycode.js;h=e8719c3a9d5db49440dd518d4d52b58df3fdd24d;hb=a2ae7986853adb271361957a08effd0c9537e7a3;hp=15f9b1e51e708663261c416eb3c56bd8bd4030ef;hpb=5d3074bbb1f510aeaef98662175560f2c418be2f;p=unfold.git diff --git a/plugins/querycode/querycode.js b/plugins/querycode/querycode.js index 15f9b1e5..e8719c3a 100644 --- a/plugins/querycode/querycode.js +++ b/plugins/querycode/querycode.js @@ -7,12 +7,6 @@ * License: GPLv3 */ -function debug_object (msg, o) { - var keys=[]; - for (var k in o) keys.push(k); - console.log (msg + " Keys : " + keys); -} - // xxx TODO // . turn back on syntax highlighting @@ -131,7 +125,7 @@ function debug_object (msg, o) { }); ofs = '[' + ofs + ']'; - output += 'pp srv.call("' + title_case(query.action) +'", auth, "' + query.method + '", "' + query.timestamp + '", ' + ifs + ', ' + ofs + ')'; + output += 'pp srv.call("' + mixed_case(query.action) +'", auth, "' + query.method + '", "' + query.timestamp + '", ' + ifs + ', ' + ofs + ')'; var output = '
' + output + "
"; return output; @@ -164,12 +158,12 @@ function debug_object (msg, o) { }); ofs = '[' + ofs + ']'; - output += 'srv.' + title_case(query.action) + '(auth, "' + query.method + '", ' + ifs + ', {}, ' + ofs + ')'; + output += 'srv.' + mixed_case(query.action) + '(auth, "' + query.method + '", ' + ifs + ', {}, ' + ofs + ')'; var output = '
' + output + "
"; return output; } - function title_case (txt){ return txt.charAt(0).toUpperCase() + txt.substr(1).toLowerCase();} + function mixed_case (txt){ return txt.charAt(0).toUpperCase() + txt.substr(1).toLowerCase();} })(jQuery); // end closure wrapper