Skip to content

Commit

Permalink
update vsphere machine config to use new networks endpoint
Browse files Browse the repository at this point in the history
  • Loading branch information
mantis-toboggan-md committed Oct 15, 2024
1 parent 4196a42 commit f4aad41
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 5 deletions.
10 changes: 7 additions & 3 deletions shell/components/form/ArrayList.vue
Original file line number Diff line number Diff line change
Expand Up @@ -138,10 +138,14 @@ export default {
}
},
watch: {
value() {
this.lastUpdateWasFromValue = true;
this.rows = (this.value || []).map((v) => ({ value: v }));
value: {
deep: true,
handler() {
this.lastUpdateWasFromValue = true;
this.rows = (this.value || []).map((v) => ({ value: v }));
}
},
rows: {
deep: true,
handler(newValue, oldValue) {
Expand Down
6 changes: 4 additions & 2 deletions shell/machine-config/vmwarevsphere.vue
Original file line number Diff line number Diff line change
Expand Up @@ -546,8 +546,10 @@ export default {
async loadNetworks() {
set(this, 'networksResults', null);
const options = await this.requestOptions('networks', this.value.datacenter);
const content = this.mapPathOptionsToContent(options);
const options = await this.requestOptions('networks-extended', this.value.datacenter);
const content = options.map((opt) => {
return { label: `${ opt.name } (${ opt.moid })`, value: opt.moid };
});
this.resetValueIfNecessary('network', content, options, true);
Expand Down

0 comments on commit f4aad41

Please sign in to comment.