diff options
author | Ram Krishna Verma <ram_krishna.verma@bell.ca> | 2021-09-01 15:00:24 -0400 |
---|---|---|
committer | Ram Krishna Verma <ram_krishna.verma@bell.ca> | 2021-09-01 16:09:01 -0400 |
commit | 61adc09d3b9dcce1b35693704f275c160b3d167d (patch) | |
tree | eb959fa195bd6061c32376cf790368c5a33d5c97 /gui-editors/gui-editor-apex/src | |
parent | db784313b8ba29f5d4396c1cc96bb5f3c853677f (diff) |
Fix sonar issues in policy/gui
Issue-ID: POLICY-3095
Change-Id: Ida760b380acbc5784f685e0a4c95c09f017ebf57
Signed-off-by: Ram Krishna Verma <ram_krishna.verma@bell.ca>
Diffstat (limited to 'gui-editors/gui-editor-apex/src')
-rw-r--r-- | gui-editors/gui-editor-apex/src/main/resources/webapp/js/ApexPolicyEditForm.js | 8 | ||||
-rw-r--r-- | gui-editors/gui-editor-apex/src/main/resources/webapp/js/ApexPolicyTab.js | 6 |
2 files changed, 7 insertions, 7 deletions
diff --git a/gui-editors/gui-editor-apex/src/main/resources/webapp/js/ApexPolicyEditForm.js b/gui-editors/gui-editor-apex/src/main/resources/webapp/js/ApexPolicyEditForm.js index 59af8f5..edaf7b7 100644 --- a/gui-editors/gui-editor-apex/src/main/resources/webapp/js/ApexPolicyEditForm.js +++ b/gui-editors/gui-editor-apex/src/main/resources/webapp/js/ApexPolicyEditForm.js @@ -334,10 +334,10 @@ function editPolicyForm_activate(parent, operation, policy, tasks, events, conte triggerLabel.innerHTML = "Policy Trigger Event: "; var triggerevent = null; if (policy != null && policy.firstState != null && policy.firstState != "" && policy.state != null) { - for (i = 0; i < policy.state.entry.length; i++) { - if (policy.state.entry[i] != null && policy.state.entry[i].key != null) { - statename = policy.state.entry[i].key; - var state = policy.state.entry[i].value; + for (let entry of policy.state.entry) { + if (entry != null && entry.key != null) { + statename = entry.key; + var state = entry.value; if (statename != null && statename == policy.firstState) { triggerevent = { "name" : state.trigger.name, diff --git a/gui-editors/gui-editor-apex/src/main/resources/webapp/js/ApexPolicyTab.js b/gui-editors/gui-editor-apex/src/main/resources/webapp/js/ApexPolicyTab.js index c6ef0db..2aa96e4 100644 --- a/gui-editors/gui-editor-apex/src/main/resources/webapp/js/ApexPolicyTab.js +++ b/gui-editors/gui-editor-apex/src/main/resources/webapp/js/ApexPolicyTab.js @@ -81,9 +81,9 @@ function policyTab_activate() { "</td>"; policyTableRow += "<td><table class='ebTable'><thead><tr class='headerRow'><th>Task Reference</th><th>Output Type</th><th>Output</th></thead><tbody>"; - for (let entry of state.taskReferences.entry) { - var taskKey = entry.key; - var taskRef = entry.value; + for (let taskEntry of state.taskReferences.entry) { + var taskKey = taskEntry.key; + var taskRef = taskEntry.value; policyTableRow += "<tr><td>" + |