dataxu/CurrencyTracker — pull request #2 by alexei-lexx (2014-11-12 15:51:06+00:00)
Title: Curguzchin Alexei

1) Gem devise was added for an authentication. It gives us most common
Sign Up and Sign In features. Model User is generated also.

2) Now we should track country visits for each user individually.
So I remove `countries.visited` and add the table `visits` for many2many relation
between `users` and `countries`. If user has visited a country then the
corresponding record in `visits` exists. If no then there is no record.
The field `visits.created_at` can be used to define date of the visit.

3) I dont use SQL JOIN to fetch `visited` field of countries in one SQL query.
This give us less raw SQL, only objects. Also this is not a performance issue
because number of countries and currencies in the world is rather small and
almost invariably.

3) I use AngularJS MVC framework to implement UI logic in the browser:
draw table, filter rows, draw charts etc.
I add json support in RoR controller.