Refactored app.js to controller.js and resources.js. Added product route for $resource