Replace all Capybara/PhantomJS code with simple json api call, move all code to Day model