blob: c1bc8f5d075b785c57d3a2dd8e6222828e9ccbce [file] [log] [blame]
Matteo Scandolofbd486c2016-04-13 10:19:55 -07001(function() {
2 'use strict';
Matteo Scandolo4b3bf7f2016-04-12 11:38:40 -07003
Matteo Scandolofbd486c2016-04-13 10:19:55 -07004 angular.module('{{ngModule}}')
5 {{#each resources}}
Matteo Scandolo717352a2016-04-13 17:23:28 -07006 /**
7 * @ngdoc service
8 * @name {{../ngModule}}.{{name}}
9 * @description Angular resource to fetch {{param.href}}
10 **/
Matteo Scandolofbd486c2016-04-13 10:19:55 -070011 .service('{{name}}', function($resource){
Matteo Scandolo4fc06db2016-04-29 09:14:58 -070012 return $resource('{{param.href}}'{{#if param.name}}, { {{param.name}}: '@id' }, {
13 update: { method: 'PUT' }
14 }{{/if}});
Matteo Scandolofbd486c2016-04-13 10:19:55 -070015 })
16 {{/each}}
17})();