UI: Prevent replication disable action from sending data payload (#24292)

* Prevent replication disable action from sending data payload

* Add changelog
This commit is contained in:
Chelsea Shaw 2023-11-29 16:40:40 -06:00 committed by GitHub
parent 31f399d147
commit b0ed4297bf
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
3 changed files with 12 additions and 2 deletions

3
changelog/24292.txt Normal file
View file

@ -0,0 +1,3 @@
```release-note:bug
ui: Fix payload sent when disabling replication
```

View file

@ -9,4 +9,11 @@ import layout from '../templates/components/replication-action-disable';
export default Actions.extend({
layout,
tagName: '',
actions: {
onSubmit(replicationMode, clusterMode, evt) {
// No data is submitted for disable request
return this.onSubmit(replicationMode, clusterMode, null, evt);
},
},
});

View file

@ -31,8 +31,8 @@
@isActive={{this.isModalActive}}
@confirmText={{this.model.replicationModeForDisplay}}
@toConfirmMsg="disabling {{this.model.replicationModeForDisplay}} Replication on this cluster"
@onConfirm={{action
"onSubmit"
@onConfirm={{fn
(action "onSubmit")
"disable"
(if (eq this.model.replicationAttrs.modeForUrl "bootstrapping") this.mode this.model.replicationAttrs.modeForUrl)
}}