말은, 나는 다음과 같은 자원이 있습니다
angular.module('app.resources.demo-resource', ['ngResource'])
.service('demoResource',
function ($resource) {
return $resource('/api/path', { }, { put: { method: 'PUT' } });
});
을하고 나중에 약속을 사용하여 PUT 요청을 호출합니다. 어떻게 올바르게 수행 할 수 있습니까?
newResource.$put().then(...)
또는 newResource.put().then(...)
?
두 변형이 모두 존재하며 그 차이점은 무엇입니까?