Massive Controller Code Cleanup

- Remove the occurrences of #find with #where.to_a so as to avoid the exception generation.
- Use the new Ruby syntax
- Avoid nested parameters in the controller actions
- Refactor some code so as to reduce the clutter in the file
- Remove hidden field for :id as they are no longer needed. This will also help in case of strict strong_parameters
- Remove additional parameters for datetime_select in starttime and endtime from strong_parameters as mentioned in the [PR](https://github.com/rails/strong_parameters/pull/39)