Message to display when a selected corrective policy is changed to general or deleted

feature/appm-store/pbac
Saad Sahibjan 5 years ago
parent ec3f5afcb7
commit 8178a3cd8f

@ -20,5 +20,16 @@ Once this is supported for other device type the below condition can be removed.
</div> </div>
<br class="c-both"/> <br class="c-both"/>
</div> </div>
<div id="corrective-action-policy-id-missing-msg" class="hidden">
<br/>
<br/>
<span class="alert alert-info">
<strong>
<i class="icon fw fw-info"></i>
Corrective policy has been automatically changed to NONE since a previously selected corrective policy
has been updated to a GENERAL policy or it has been deleted.
</strong>
</span>
</div>
</div> </div>
{{/equal}} {{/equal}}

@ -305,7 +305,11 @@ stepForwardFrom["policy-profile"] = function () {
currentlyEffected.correctiveActions.length > 0) { currentlyEffected.correctiveActions.length > 0) {
currentlyEffected.correctiveActions.forEach(function (correctiveAction) { currentlyEffected.correctiveActions.forEach(function (correctiveAction) {
if ("POLICY" === correctiveAction.actionType) { if ("POLICY" === correctiveAction.actionType) {
$("#corrective-policy-input").val(correctiveAction.policyId); if ($("#corrective-policy-input option[value=" + correctiveAction.policyId + "]").length > 0) {
$("#corrective-policy-input").val(correctiveAction.policyId);
} else {
$("#corrective-action-policy-id-missing-msg").removeClass("hidden");
}
// returned from for each since currently only supported corrective action type is // returned from for each since currently only supported corrective action type is
// POLICY. // POLICY.
return true; return true;

Loading…
Cancel
Save