diff options
Diffstat (limited to 'ui-react/src/api')
-rw-r--r-- | ui-react/src/api/LoopCache.js | 7 | ||||
-rw-r--r-- | ui-react/src/api/LoopService.js | 4 |
2 files changed, 9 insertions, 2 deletions
diff --git a/ui-react/src/api/LoopCache.js b/ui-react/src/api/LoopCache.js index c54337f2f..4f22dc2bb 100644 --- a/ui-react/src/api/LoopCache.js +++ b/ui-react/src/api/LoopCache.js @@ -219,4 +219,11 @@ export default class LoopCache { getComponentStates() { return this.loopJsonCache.components; } + + getTemplateName() { + if (this.loopJsonCache["loopTemplate"] !== undefined) { + return this.loopJsonCache["loopTemplate"].name; + } + return null; + } } diff --git a/ui-react/src/api/LoopService.js b/ui-react/src/api/LoopService.js index 9d3b36983..3b9ed86fa 100644 --- a/ui-react/src/api/LoopService.js +++ b/ui-react/src/api/LoopService.js @@ -239,8 +239,8 @@ export default class LoopService { }) } - static removeOperationalPolicyType(loopName, policyType, policyVersion) { - return fetch('/restservices/clds/v2/loop/removeOperationaPolicy/' + loopName + '/policyModel/' + policyType +'/' + policyVersion , { + static removeOperationalPolicyType(loopName, policyType, policyVersion, policyName) { + return fetch('/restservices/clds/v2/loop/removeOperationaPolicy/' + loopName + '/policyModel/' + policyType +'/' + policyVersion + '/' + policyName , { method: 'PUT', headers: { "Content-Type": "application/json" |