From f6aae2b11a4906ac484ea7410997eef0fb022a99 Mon Sep 17 00:00:00 2001 From: JeremyDec <34273689+JeremyDec@users.noreply.github.com> Date: Wed, 10 Apr 2019 17:51:53 +0200 Subject: [PATCH] feat(xdsl.incident): add api bindings (#153) --- src/xdsl/incident/xdsl-incident.service.js | 9 +++++++++ src/xdsl/incident/xdsl-incident.v6.service.js | 15 +++++++++++++++ src/xdsl/xdsl.service.js | 3 +++ 3 files changed, 27 insertions(+) create mode 100644 src/xdsl/incident/xdsl-incident.service.js create mode 100644 src/xdsl/incident/xdsl-incident.v6.service.js diff --git a/src/xdsl/incident/xdsl-incident.service.js b/src/xdsl/incident/xdsl-incident.service.js new file mode 100644 index 00000000..92b0e507 --- /dev/null +++ b/src/xdsl/incident/xdsl-incident.service.js @@ -0,0 +1,9 @@ +angular.module("ovh-api-services").service("OvhApiXdslIncident", function ($injector) { + "use strict"; + + return { + v6: function () { + return $injector.get("OvhApiXdslIncidentV6"); + } + }; +}); diff --git a/src/xdsl/incident/xdsl-incident.v6.service.js b/src/xdsl/incident/xdsl-incident.v6.service.js new file mode 100644 index 00000000..09fdf5f1 --- /dev/null +++ b/src/xdsl/incident/xdsl-incident.v6.service.js @@ -0,0 +1,15 @@ +angular.module("ovh-api-services").service("OvhApiXdslIncidentV6", function ($cacheFactory, $resource) { + "use strict"; + + var cache = $cacheFactory("OvhApiXdslIncidentV6"); + + return $resource("/xdsl/:serviceName/incident", { + serviceName: "@serviceName" + }, { + get: { + method: "GET", + cache: cache, + isArray: false + } + }); +}); diff --git a/src/xdsl/xdsl.service.js b/src/xdsl/xdsl.service.js index c9d6c054..9f61f1ea 100644 --- a/src/xdsl/xdsl.service.js +++ b/src/xdsl/xdsl.service.js @@ -16,6 +16,9 @@ angular.module("ovh-api-services").service("OvhApiXdsl", function ($injector, $c Email: function () { return $injector.get("OvhApiXdslEmail"); }, + Incident: function () { + return $injector.get("OvhApiXdslIncident"); + }, Lines: function () { return $injector.get("OvhApiXdslLines"); },