Skip to content

Commit 0f945ba

Browse files
[UI] Set rebalance true by default in cancel maintenance dialog
1 parent 835a5ab commit 0f945ba

File tree

2 files changed

+7
-2
lines changed

2 files changed

+7
-2
lines changed

ui/src/config/section/infra/managementServers.js

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -110,7 +110,6 @@ export default {
110110
icon: 'close-circle-outlined',
111111
label: 'label.cancel.shutdown',
112112
message: 'message.cancel.shutdown',
113-
docHelp: 'installguide/configuration.html#adding-a-zone',
114113
dataView: true,
115114
popup: true,
116115
show: (record, store) => { return ['PreparingForShutDown', 'ReadyToShutDown', 'ShuttingDown'].includes(record.state) },

ui/src/views/AutogenView.vue

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1189,7 +1189,7 @@ export default {
11891189
this.getFirstIndexFocus()
11901190
11911191
this.showAction = true
1192-
const listIconForFillValues = ['copy-outlined', 'CopyOutlined', 'edit-outlined', 'EditOutlined', 'share-alt-outlined', 'ShareAltOutlined']
1192+
const listIconForFillValues = ['copy-outlined', 'CopyOutlined', 'edit-outlined', 'EditOutlined', 'share-alt-outlined', 'ShareAltOutlined', 'minus-square-outlined']
11931193
for (const param of this.currentAction.paramFields) {
11941194
if (param.type === 'list' && ['tags', 'hosttags', 'storagetags', 'storageaccessgroups', 'files'].includes(param.name)) {
11951195
param.type = 'string'
@@ -1415,6 +1415,8 @@ export default {
14151415
fieldValue = this.resource[fieldName] ? this.resource[fieldName] : null
14161416
if (fieldValue) {
14171417
this.form[field.name] = fieldValue
1418+
} else if (field.type === 'boolean' && field.name === 'rebalance' && this.currentAction.api === 'cancelMaintenance') {
1419+
this.form[field.name] = true
14181420
}
14191421
})
14201422
},
@@ -1571,6 +1573,10 @@ export default {
15711573
}
15721574
}
15731575
1576+
if (['cancelMaintenance'].includes(action.api) && (params.rebalance === undefined || params.rebalance === null || params.rebalance === '')) {
1577+
params.rebalance = true
1578+
}
1579+
15741580
for (const key in values) {
15751581
const input = values[key]
15761582
for (const param of action.params) {

0 commit comments

Comments
 (0)