-
Notifications
You must be signed in to change notification settings - Fork 1.2k
UI support for extraconfig in deploy and update instance #11719
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from 4 commits
6e47c4c
6f35254
3a6a7a5
4d2ef00
3d9d2ba
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -91,6 +91,12 @@ | |
<a-textarea v-model:value="form.userdata"> | ||
</a-textarea> | ||
</a-form-item> | ||
<a-form-item v-if="extraConfigEnabled"> | ||
<template #label> | ||
<tooltip-label :title="$t('label.extraconfig')" :tooltip="$t('label.extraconfig.tooltip')"/> | ||
</template> | ||
<a-textarea v-model:value="form.extraconfig"/> | ||
</a-form-item> | ||
<a-form-item ref="securitygroupids" name="securitygroupids" :label="$t('label.security.groups')" v-if="securityGroupsEnabled"> | ||
<a-select | ||
mode="multiple" | ||
|
@@ -164,7 +170,8 @@ export default { | |
groups: { | ||
loading: false, | ||
opts: [] | ||
} | ||
}, | ||
extraConfigEnabled: this.$store.getters.features.additionalconfigenabled | ||
|
||
} | ||
}, | ||
beforeCreate () { | ||
|
@@ -342,6 +349,9 @@ export default { | |
if (values.userdata && values.userdata.length > 0) { | ||
params.userdata = this.$toBase64AndURIEncoded(values.userdata) | ||
} | ||
if (values.extraconfig && values.extraconfig.length > 0) { | ||
params.extraconfig = encodeURIComponent(values.extraconfig) | ||
} | ||
this.loading = true | ||
|
||
api('updateVirtualMachine', {}, 'POST', params).then(json => { | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Not related to this PR but as some point we should start using a generic Map response or some other means. Adding a new response param for a new global setting value is an unnecessary hassle
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
+1