aboutsummaryrefslogtreecommitdiffstats
path: root/ui-react/src/api/LoopService.js
diff options
context:
space:
mode:
Diffstat (limited to 'ui-react/src/api/LoopService.js')
-rw-r--r--ui-react/src/api/LoopService.js23
1 files changed, 23 insertions, 0 deletions
diff --git a/ui-react/src/api/LoopService.js b/ui-react/src/api/LoopService.js
index e2e23482..ead2cf80 100644
--- a/ui-react/src/api/LoopService.js
+++ b/ui-react/src/api/LoopService.js
@@ -152,4 +152,27 @@ export default class LoopService {
return "";
});
}
+
+ static refreshOpPolicyJson(loopName) {
+ return fetch('/restservices/clds/v2/loop/refreshOpPolicyJsonSchema/' + loopName, {
+ method: 'PUT',
+ headers: {
+ "Content-Type": "application/json"
+ },
+ credentials: 'same-origin'
+ })
+ .then(function (response) {
+ console.debug("Refresh Operational Policy Json Schema response received: ", response.status);
+ if (response.ok) {
+ return response.json();
+ } else {
+ console.error("Refresh Operational Policy Json Schema query failed");
+ return {};
+ }
+ })
+ .catch(function (error) {
+ console.error("Refresh Operational Policy Json Schema error received", error);
+ return {};
+ });
+ }
}