Some JS Cleanup

Mostly just implicit declarations cleanup, making stuff end up in global namespace that didn't need to be

removed an extraneous comma on the groups tree initAjax stuff which causing an error in some browsers (surprisingly not all)