key instead of ids
removing old code
moving to angularjs