Now we will connect to our Backend service. To demonstrate this, I have created a Rails application that is hosted on Heroku. You can use this URL to fetch the data for your application:
http://employee-rails.heroku.com/employees
http://employee-rails.heroku.com/companies
Our RhoSync application will dynamically fetch data from these applications with the help of a request in the JSON format. And then we will feed this data to our phone.
If you open http://employee-rails.heroku.com/companies.json you will receive the following data in JSON format:
[ { "company": {"name":"Google", "created_at":"2011-02-11T10:51:10Z", "updated_at":"2011-02-11T10:51:10Z","id":1} }, { "company": {"name":"Apple", "created_at":"2011-02-11T10:51:22Z", "updated_at":"2011-02-11T10:51:22Z", "id":2} } }
And, when you check http://employee-rails.heroku.com/employees.json:
[ {"employee": {"name":"Abhishek Nalwaya", "address":"Chicgo", "created_at":"2011-02-11T10:52:11Z", "updated_at":"2011-02...