Trying to add $resource, need to test with promises