Skip to content
This repository has been archived by the owner on Apr 3, 2023. It is now read-only.

Commit

Permalink
feat(me.billing): add call for /me/billing/capacities
Browse files Browse the repository at this point in the history
  • Loading branch information
marie-j committed Dec 21, 2018
1 parent 82e4396 commit 64745fe
Show file tree
Hide file tree
Showing 3 changed files with 31 additions and 0 deletions.
9 changes: 9 additions & 0 deletions src/me/billing/capacities/me-billing-capacities.service.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
angular.module("ovh-api-services").service("OvhApiMeBillingCapacities", function ($injector) {
"use strict";

return {
v6: function () {
return $injector.get("OvhApiMeBillingCapacitiesV6");
}
};
});
19 changes: 19 additions & 0 deletions src/me/billing/capacities/me-billing-capacities.v6.service.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
angular.module("ovh-api-services").service("OvhApiMeBillingCapacitiesV6", function ($cacheFactory, $resource) {
"use strict";

var queryCache = $cacheFactory("OvhApiMeBillingCapacitiesQueryV6");

var billingCapacitiesResource = $resource("/me/billing/capacities", {}, {
query: {
method: "GET",
isArray: false,
cache: queryCache
}
});

billingCapacitiesResource.resetQueryCache = function () {
queryCache.removeAll();
};

return billingCapacitiesResource;
});
3 changes: 3 additions & 0 deletions src/me/billing/me-billing.service.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,9 @@ angular.module("ovh-api-services").service("OvhApiMeBilling", function ($injecto
"use strict";

return {
Capacities: function () {
return $injector.get("OvhApiMeBillingCapacities");
},
InvoicesByPostalMail: function () {
return $injector.get("OvhApiMeBillingInvoicesByPostalMail");
}
Expand Down

0 comments on commit 64745fe

Please sign in to comment.