Work done on server-side API. Removed all html rendering from controllers. Implemented CanCan for permissions.
Have not yet written caned queries/scopes for permissions.

modified:   Gemfile.lock
modified:   app/assets/javascripts/angular/controllers/sites.js
modified:   app/assets/templates/projects_list.html

modified:   app/controllers/analysis_items_controller.rb
modified:   app/controllers/analysis_jobs_controller.rb
modified:   app/controllers/analysis_scripts_controller.rb
modified:   app/controllers/api/sessions_controller.rb
modified:   app/controllers/application_controller.rb
modified:   app/controllers/audio_events_controller.rb
modified:   app/controllers/audio_recordings_controller.rb
modified:   app/controllers/bookmarks_controller.rb
modified:   app/controllers/home_controller.rb
modified:   app/controllers/permissions_controller.rb
modified:   app/controllers/photos_controller.rb
modified:   app/controllers/progresses_controller.rb
modified:   app/controllers/projects_controller.rb
modified:   app/controllers/saved_searches_controller.rb
modified:   app/controllers/sites_controller.rb
modified:   app/controllers/tags_controller.rb
modified:   app/controllers/users_controller.rb
-- removed html rendering

modified:   app/models/ability.rb
-- added skeleton for checking database to get permissions.
modified:   app/models/permission.rb

modified:   config/initializers/devise.rb
-- added a custom FailureApp
new file:   lib/RestFailureApp.rb
-- added this to try to get rid of redirects to /security/sign_in