Vue migration - remove Vuew.set & this.$set; add vue-migrate script

Signed-off-by: Francesco Torchia <francesco.torchia@suse.com>
This commit is contained in:
Francesco Torchia
2024-10-23 17:00:48 +02:00
parent c983ed8384
commit ea12a81174
85 changed files with 938 additions and 256 deletions
@@ -175,10 +175,10 @@ export default {
this.value.cleanForNew();
this.customName = randomStr(10);
this.$set(this.value.metadata, 'annotations', {
this.value.metadata['annotations'] = {
...this.value.metadata.annotations,
[HCI_ANNOTATIONS.TEMPLATE_VERSION_CUSTOM_NAME]: this.customName
});
};
const name = this.templateValue.metadata.name || template.metadata.name;
const namespace = this.templateValue.metadata.namespace || template.metadata.namespace;
@@ -187,7 +187,7 @@ export default {
this.value.metadata.namespace = namespace;
}
this.$set(this.value.spec, 'templateId', `${ namespace }/${ name }`);
this.value.spec['templateId'] = `${ namespace }/${ name }`;
const res = await this.value.save();
await this.saveSecret(res);