Skip to content

Commit

Permalink
Set inheritAttrs=false in Component using CruResource
Browse files Browse the repository at this point in the history
Signed-off-by: Francesco Torchia <[email protected]>
  • Loading branch information
torchiaf committed Oct 9, 2024
1 parent 33ebf76 commit 0502cf1
Show file tree
Hide file tree
Showing 26 changed files with 52 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,8 @@ export default {
mixins: [CreateEditView, VM_MIXIN],
inheritAttrs: false,
props: {
value: {
type: Object,
Expand Down
2 changes: 2 additions & 0 deletions pkg/harvester/detail/harvesterhci.io.vmsnapshot/index.vue
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,8 @@ export default {
mixins: [CreateEditView, VM_MIXIN],
inheritAttrs: false,
props: {
value: {
type: Object,
Expand Down
2 changes: 2 additions & 0 deletions pkg/harvester/edit/harvesterhci.io.addon/index.vue
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,8 @@ export default {
mixins: [CreateEditView],
inheritAttrs: false,
props: {
value: {
type: Object,
Expand Down
2 changes: 2 additions & 0 deletions pkg/harvester/edit/harvesterhci.io.addon/rancher-vcluster.vue
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,8 @@ export default {
name: 'EditAddonVcluster',
components: { LabeledInput, RadioGroup },
inheritAttrs: false,
props: {
value: {
type: Object,
Expand Down
2 changes: 2 additions & 0 deletions pkg/harvester/edit/harvesterhci.io.cloudtemplate.vue
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,8 @@ export default {
mixins: [CreateEditView],
inheritAttrs: false,
data() {
return {
config: this.value.data?.cloudInit || '',
Expand Down
1 change: 1 addition & 0 deletions pkg/harvester/edit/harvesterhci.io.host/index.vue
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,7 @@ export default {
MessageLink,
},
mixins: [CreateEditView],
inheritAttrs: false,
props: {
value: {
type: Object,
Expand Down
2 changes: 2 additions & 0 deletions pkg/harvester/edit/harvesterhci.io.keypair.vue
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,8 @@ export default {
mixins: [CreateEditView],
inheritAttrs: false,
props: {
value: {
type: Object,
Expand Down
2 changes: 2 additions & 0 deletions pkg/harvester/edit/harvesterhci.io.logging.output.vue
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,8 @@ export default {
mixins: [CreateEditView],
inheritAttrs: false,
async fetch() {
await this.$store.dispatch('harvester/findAll', { type: SECRET });
},
Expand Down
2 changes: 2 additions & 0 deletions pkg/harvester/edit/harvesterhci.io.management.cluster.vue
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,8 @@ export default {
mixins: [CreateEditView],
inheritAttrs: false,
props: {
mode: {
type: String,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,8 @@ export default {
mixins: [CreateEditView],
inheritAttrs: false,
async fetch() {
const inStore = this.$store.getters['currentProduct'].inStore;
const alertmanagerConfigId = this.value.id;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,8 @@ export default {
mixins: [CreateEditView],
inheritAttrs: false,
props: {
value: {
type: Object,
Expand Down
2 changes: 2 additions & 0 deletions pkg/harvester/edit/harvesterhci.io.schedulevmbackup.vue
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,8 @@ export default {
mixins: [CreateEditView],
inheritAttrs: false,
async fetch() {
const hash = await allHash({
settings: this.$store.dispatch('harvester/findAll', { type: HCI.SETTING }),
Expand Down
2 changes: 2 additions & 0 deletions pkg/harvester/edit/harvesterhci.io.secret.vue
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,8 @@ export default {
mixins: [CreateEditView],
inheritAttrs: false,
async fetch() {
if ( this.isCloud ) {
this.nodeDrivers = await this.$store.dispatch('management/findAll', { type: MANAGEMENT.NODE_DRIVER });
Expand Down
2 changes: 2 additions & 0 deletions pkg/harvester/edit/harvesterhci.io.setting.vue
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,8 @@ export default {
mixins: [CreateEditView],
inheritAttrs: false,
data() {
const t = this.$store.getters['i18n/t'];
const setting =
Expand Down
2 changes: 2 additions & 0 deletions pkg/harvester/edit/harvesterhci.io.storage/index.vue
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,8 @@ export default {
mixins: [CreateEditView],
inheritAttrs: false,
data() {
const reclaimPolicyOptions = [{
label: this.t('storageClass.customize.reclaimPolicy.delete'),
Expand Down
2 changes: 2 additions & 0 deletions pkg/harvester/edit/harvesterhci.io.virtualmachineimage.vue
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,8 @@ const rawORqcow2 = 'raw_qcow2';
export default {
name: 'EditImage',
inheritAttrs: false,
emits: ['update:value'],
components: {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -53,6 +53,8 @@ export default {
mixins: [CreateEditView, VM_MIXIN],
inheritAttrs: false,
props: {
value: {
type: Object,
Expand Down
2 changes: 2 additions & 0 deletions pkg/harvester/edit/harvesterhci.io.volume.vue
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,8 @@ export default {
mixins: [CreateEditView],
inheritAttrs: false,
async fetch() {
const inStore = this.$store.getters['currentProduct'].inStore;
const _hash = {
Expand Down
2 changes: 2 additions & 0 deletions pkg/harvester/edit/harvesterhci.io.volumesnapshot.vue
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,8 @@ export default {
mixins: [CreateEditView],
inheritAttrs: false,
computed: {
volume() {
return this.volumes.find((V) => {
Expand Down
2 changes: 2 additions & 0 deletions pkg/harvester/edit/kubevirt.io.virtualmachine/index.vue
Original file line number Diff line number Diff line change
Expand Up @@ -78,6 +78,8 @@ export default {
mixins: [CreateEditView, VM_MIXIN],
inheritAttrs: false,
props: {
value: {
type: Object,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,8 @@ export default {
mixins: [CreateEditView],
inheritAttrs: false,
async fetch() {
const inStore = this.$store.getters['currentProduct'].inStore;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,8 @@ export default {
mixins: [CreateEditView],
inheritAttrs: false,
props: {
value: {
type: Object,
Expand Down
3 changes: 3 additions & 0 deletions pkg/harvester/edit/management.cattle.io.project.vue
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,9 @@ export default {
},
mixins: [CreateEditView, FormValidation],
inheritAttrs: false,
async fetch() {
if ( this.$store.getters['management/canList'](MANAGEMENT.POD_SECURITY_POLICY_TEMPLATE) ) {
this.allPSPs = await this.$store.dispatch('management/findAll', { type: MANAGEMENT.POD_SECURITY_POLICY_TEMPLATE });
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,8 @@ export default {
mixins: [CreateEditView],
inheritAttrs: false,
computed: {
doneLocationOverride() {
return this.value.doneOverride;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,8 @@ export default {
mixins: [CreateEditView],
inheritAttrs: false,
data() {
const originNics = clone(this.value?.spec?.uplink?.nics || []);
Expand Down
2 changes: 2 additions & 0 deletions pkg/harvester/pages/c/_cluster/airgapupgrade/index.vue
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,8 @@ export default {
Checkbox, CruResource, LabeledSelect, LabeledInput, RadioGroup, UpgradeInfo
},
inheritAttrs: false,
async fetch() {
await this.$store.dispatch('harvester/findAll', { type: HCI.IMAGE });
Expand Down

0 comments on commit 0502cf1

Please sign in to comment.