Rails4 Upgrade

For #386 rails 4 upgrade. based on PR #425 contributed by @ichord. Please create rails4 related PR from this branch, and choose this branch as base when send the PR.

## Gems Dependencies

- [x] upgrade gems (by @ichord )
- [x] jasmine (<del> #433 </del>)
- [x] `devise_invitable` mail template not found in test (<del> #434  </del>)

## Rails Config

- [x] migrate config (by @ichord )
- [x] config.secret_key_base (add `secret_key_base` but keep the old config, <del> #437 </del>)

## Strong paramters

- [x] migrate to strong parameters (by @ichord )
- [x] review controllers strong parameters settings (<del> #441 </del>)
- [x] cleanup `attr_accessible`? (<del> #441 </del>)

## Misc

- [x] PUT -> PATCH (<del> #440 </del>)
- [x] Deployment and verify production environment (<del> #444 </del>)

## RSpec

- [x] rspec ./spec/helpers/event_helper_spec.rb:90 # EventHelper#event_follow_info (<del> #428 </del>)
- [x] rspec ./spec/features/user_registration_spec.rb:8 # user registration through invitation (<del> #429 </del>) 

- [x] rspec ./spec/features/user_registration_spec.rb:32 # user registration directly (<del> #429 </del>)

  invitation email view template not found (<del> #434 </del>)

- [x] rspec ./spec/features/event_page_spec.rb:58 # event page when user has signed in click join_event button will be seccses (<del> #431 </del>, `exists?` now returns `nil` or Integer )

## Ad hoc test

Ensure these components work

- [x] create event and join event
- [x] delayed_job
- [x] mail
- [x] sms
- [x] check ruby 1.9 compatibility
- [x] <del> check jruby compatibility </del> bundler version is too old
- [x] check Windows compatibility (<del> #446 </del>)

<!---
@huboard:{"order":352.0}
-->