Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions ui/public/locales/en.json
Original file line number Diff line number Diff line change
Expand Up @@ -233,6 +233,7 @@
"label.action.migrate.systemvm.processing": "Migrating system VM...",
"label.action.migrate.systemvm.to.ps": "Migrate system VM to another primary storage",
"label.action.patch.systemvm": "Patch system VM",
"label.action.patch.systemvm.vpc": "Patch system VM - VPC Router",
"label.action.patch.systemvm.processing": "Patching system VM....",
"label.action.project.add.account": "Add account to project",
"label.action.project.add.user": "Add user to project",
Expand Down
28 changes: 27 additions & 1 deletion ui/src/config/section/infra/routers.js
Original file line number Diff line number Diff line change
Expand Up @@ -100,7 +100,7 @@ export default {
label: 'label.action.patch.systemvm',
message: 'message.action.patch.router',
dataView: true,
hidden: (record) => { return record.state === 'Running' },
show: (record) => { return record.state === 'Running' && !('vpcid' in record) },
mapping: {
id: {
value: (record) => { return record.guestnetworkid }
Expand All @@ -120,6 +120,32 @@ export default {
})
}
},
{
api: 'restartVPC',
icon: 'diff-outlined',
label: 'label.action.patch.systemvm.vpc',
message: 'message.action.patch.router',
dataView: true,
show: (record) => { return record.state === 'Running' && ('vpcid' in record) },
mapping: {
id: {
value: (record) => { return record.vpcid }
},
livepatch: {
value: (record) => { return true }
}
},
groupAction: true,
popup: true,
groupMap: (selection, values, record) => {
return selection.map(x => {
const data = record.filter(y => { return y.id === x })
return {
id: data[0].vpcid, livepatch: true
}
})
}
},
{
api: 'scaleSystemVm',
icon: 'arrows-alt-outlined',
Expand Down