created new js files to separate app functionality
separated js into config,factories,controllers files