Skip to content

Commit

Permalink
UI: Prevent replication disable action from sending data payload (#24292
Browse files Browse the repository at this point in the history
)

* Prevent replication disable action from sending data payload

* Add changelog
  • Loading branch information
hashishaw authored Nov 29, 2023
1 parent 31f399d commit b0ed429
Show file tree
Hide file tree
Showing 3 changed files with 12 additions and 2 deletions.
3 changes: 3 additions & 0 deletions changelog/24292.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
```release-note:bug
ui: Fix payload sent when disabling replication
```
7 changes: 7 additions & 0 deletions ui/lib/core/addon/components/replication-action-disable.js
Original file line number Diff line number Diff line change
Expand Up @@ -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);
},
},
});
Original file line number Diff line number Diff line change
Expand Up @@ -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)
}}
Expand Down

0 comments on commit b0ed429

Please sign in to comment.