summaryrefslogtreecommitdiffstats
path: root/ui-react/src/components/dialogs/OperationalPolicy
diff options
context:
space:
mode:
authorsebdet <sebastien.determe@intl.att.com>2019-07-12 12:25:56 +0200
committersebdet <sebastien.determe@intl.att.com>2019-07-12 12:25:56 +0200
commite44fdb1905fae612b12b56886af8f387e516e485 (patch)
treea59eb65fe06c08f92dfdda3961784580228b7c29 /ui-react/src/components/dialogs/OperationalPolicy
parent4946e5b7d80fa1a7baa1c6042100fa1dee24ee31 (diff)
Rework the structure
Rework of the project structure and static loop cache added for the entire site Issue-ID: CLAMP-418 Change-Id: Ia2cf62431cd9139c91bf74bb639b502a368ce761 Signed-off-by: sebdet <sebastien.determe@intl.att.com>
Diffstat (limited to 'ui-react/src/components/dialogs/OperationalPolicy')
-rw-r--r--ui-react/src/components/dialogs/OperationalPolicy/OperationalPolicyModal.js8
1 files changed, 3 insertions, 5 deletions
diff --git a/ui-react/src/components/dialogs/OperationalPolicy/OperationalPolicyModal.js b/ui-react/src/components/dialogs/OperationalPolicy/OperationalPolicyModal.js
index e52d930a2..7d339313e 100644
--- a/ui-react/src/components/dialogs/OperationalPolicy/OperationalPolicyModal.js
+++ b/ui-react/src/components/dialogs/OperationalPolicy/OperationalPolicyModal.js
@@ -24,7 +24,7 @@
import React from 'react'
import Button from 'react-bootstrap/Button';
import Modal from 'react-bootstrap/Modal';
-import LoopCache from '../../backend_communication/LoopCache'
+import { LOOP_CACHE } from '../../../api/LoopCache'
import './OperationalPolicy.css'
import styled from 'styled-components';
@@ -37,8 +37,6 @@ export default class OperationalPolicyModal extends React.Component {
constructor(props, context) {
super(props, context);
- this.loopCache = new LoopCache();
-
this.handleClose = this.handleClose.bind(this);
this.initPolicySelect = this.initPolicySelect.bind(this);
@@ -59,7 +57,7 @@ export default class OperationalPolicyModal extends React.Component {
initPolicySelect() {
if (this.allPolicies['operational_policy'] === undefined || this.allPolicies['operational_policy'] === null) {
- this.allPolicies = this.loopCache.getOperationalPolicyProperty();
+ this.allPolicies = LOOP_CACHE.getOperationalPolicyProperty();
}
// Provision all policies ID first
if (this.policyIds.length == 0 && this.allPolicies['operational_policy'] != undefined) {
@@ -197,7 +195,7 @@ export default class OperationalPolicyModal extends React.Component {
<label className="col-sm-4 control-label" htmlFor="clname">ControlLoopName</label>
<div className="col-sm-8">
<input type="text" className="form-control" name="controlLoopName"
- readOnly="readonly" id="clname" value={this.loopCache.getLoopName()} />
+ readOnly="readonly" id="clname" value={LOOP_CACHE.getLoopName()} />
</div>
</div>
</form>