correct minor errors in DataSelectCtrl.

uninitialized variables triggering "undefined" errors.
enable selection of data on single click in a row
js code style and documentation
make jshint happy.