Skip to content

$resource feature - not able to do with angular-cached-feature #96

@angularPublic

Description

@angularPublic

I am having a $resource defined as factory like below,

product-svc.js

(function() {
'use strict';
angular.module('module-name').factory('factory-name', factoryImplementation);
factoryImplementation.$inject = ['$resource'];

/* @ngInject */
function factoryImplementation($resource) {
	return $resource('', {}, {
		getProducts : {
			method : 'GET',
			url : 'http://locahost:8080/product',
			params : {}
		},
		getProductById : {
			method : 'GET',
			url : 'http://locahost:8080/product/:id',
			params : {}
		}		
	});
}

})();

I just replaced $resource with $cachedResource. It is not working.

Can you help how can I do this?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions