Merge pull request #9504 from jwangyangls/enable-rule

Add enable rule when Edit replication
This commit is contained in:
jwangyangls 2019-10-21 20:58:41 +08:00 committed by GitHub
commit 7a8a07e1f6
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 7 additions and 0 deletions

View File

@ -209,6 +209,10 @@
</clr-tooltip>
</label>
</div>
<div class="clr-checkbox-wrapper clr-form-control" [hidden]="policyId < 0">
<input type="checkbox" [checked]="true" id="enablePolicy" formControlName="enabled" class="clr-checkbox">
<label for="enablePolicy" class="clr-control-label">{{'REPLICATION.ENABLED_RULE' | translate}}</label>
</div>
</div>
</div>
<div class="loading-center">

View File

@ -203,6 +203,7 @@ export class CreateEditRuleComponent implements OnInit, OnDestroy {
})
}),
filters: this.fb.array([]),
enabled: true,
deletion: false,
override: true
});
@ -228,6 +229,7 @@ export class CreateEditRuleComponent implements OnInit, OnDestroy {
}
},
deletion: false,
enabled: true,
override: true
});
this.isPushMode = true;
@ -251,6 +253,7 @@ export class CreateEditRuleComponent implements OnInit, OnDestroy {
dest_registry: rule.dest_registry,
trigger: rule.trigger,
deletion: rule.deletion,
enabled: true,
override: rule.override
});
let filtersArray = this.getFilterArray(rule);