diff options
Diffstat (limited to 'moon_gui/static/app/services/moon/policy/parameters/rule.service.js')
-rw-r--r-- | moon_gui/static/app/services/moon/policy/parameters/rule.service.js | 49 |
1 files changed, 0 insertions, 49 deletions
diff --git a/moon_gui/static/app/services/moon/policy/parameters/rule.service.js b/moon_gui/static/app/services/moon/policy/parameters/rule.service.js deleted file mode 100644 index b1a350ae..00000000 --- a/moon_gui/static/app/services/moon/policy/parameters/rule.service.js +++ /dev/null @@ -1,49 +0,0 @@ -/** - * @author Samy Abdallah - */ - -(function() { - - 'use strict'; - - angular - .module('moon') - .factory('ruleService', ruleService); - - ruleService.$inject = ['$resource', 'REST_URI', 'utilService']; - - function ruleService($resource, REST_URI, utilService) { - - return { - - data: { - - policy: $resource(REST_URI.POLICIES + ':policy_id/rules/:rule_id', {}, { - get: {method: 'GET'}, - create: {method: 'POST'}, - remove: {method: 'DELETE'} - }) - - }, - - findAllFromPolicyWithCallback: function(policyId, callback){ - - this.data.policy.get({policy_id: policyId}).$promise.then(function(data) { - - console.log('ruleService - findAllFromPolicyWithCallback()'); - console.log(data); - - var array = data['rules']; - - console.log(JSON.stringify(array)); - callback(utilService.transform(array, 'rules')); - - }); - - } - - - } - - } -})();
\ No newline at end of file |