Add new dialog for policy
Add a new dialog component for tosca based policy, config/op should use that dialog now.
Issue-ID: CLAMP-653
Change-Id: I57523bc2d4bfbf5ca5a3acf5c59823df06fd4cd9
Signed-off-by: sebdet <sebastien.determe@intl.att.com>
diff --git a/ui-react/src/api/LoopCache.js b/ui-react/src/api/LoopCache.js
index c73ed62..b177230 100644
--- a/ui-react/src/api/LoopCache.js
+++ b/ui-react/src/api/LoopCache.js
@@ -78,6 +78,33 @@
return this.loopJsonCache["microServicePolicies"];
}
+ getOperationalPolicyForName(name) {
+ var opProperties=this.getOperationalPolicies();
+ for (var policy in opProperties) {
+ if (opProperties[policy]["name"] === name) {
+ return opProperties[policy];
+ }
+ }
+ return null;
+ }
+
+ getOperationalPolicyPropertiesForName(name) {
+ var opConfig = this.getOperationalPolicyForName(name);
+ if (opConfig !== null) {
+ return opConfig["properties"];
+ }
+ return null;
+ }
+
+ getOperationalPolicyJsonRepresentationForName(name) {
+ var opConfig = this.getOperationalPolicyForName(name);
+ if (opConfig !== null) {
+ return opConfig["jsonRepresentation"];
+ }
+ return null;
+ }
+
+
getMicroServiceForName(name) {
var msProperties=this.getMicroServicePolicies();
for (var policy in msProperties) {