Fixes $parent access to some components in the item metadata submission form.
This commit is contained in:
parent
cf00e20d8f
commit
122e4aa9b8
|
@ -434,6 +434,9 @@
|
|||
:metadata-name-filter-string="metadataNameFilterString"
|
||||
:is-collapsed="metadataCollapses[index]"
|
||||
:hide-collapses="$adminOptions.hideItemEditionCollapses || isMetadataNavigation"
|
||||
:hide-metadata-types="hideMetadataTypes"
|
||||
:hide-help-buttons="false"
|
||||
:help-info-bellow-label="false"
|
||||
:is-mobile-screen="isMobileScreen"
|
||||
:is-last-metadatum="index > 2 && (index == itemMetadata.length - 1)"
|
||||
:is-focused="focusedMetadatum === index"
|
||||
|
|
|
@ -29,13 +29,13 @@
|
|||
*
|
||||
</span>
|
||||
<span
|
||||
v-if="!$parent.hideMetadataTypes"
|
||||
v-if="!hideMetadataTypes"
|
||||
class="metadata-type">
|
||||
({{ itemMetadatum.metadatum.metadata_type_object.name }})
|
||||
</span>
|
||||
<help-button
|
||||
v-if="!$parent.hideHelpButtons &&
|
||||
!$parent.helpInfoBellowLabel &&
|
||||
v-if="!hideHelpButtons &&
|
||||
!helpInfoBellowLabel &&
|
||||
itemMetadatum.metadatum &&
|
||||
itemMetadatum.metadatum.description_bellow_name !== 'yes' &&
|
||||
itemMetadatum.metadatum.description"
|
||||
|
@ -51,7 +51,7 @@
|
|||
v-if="itemMetadatum.metadatum &&
|
||||
itemMetadatum.metadatum.description &&
|
||||
(
|
||||
(!$parent.hideHelpButtons && $parent.helpInfoBellowLabel) ||
|
||||
(!hideHelpButtons && helpInfoBellowLabel) ||
|
||||
(itemMetadatum.metadatum.description_bellow_name === 'yes')
|
||||
)">
|
||||
{{ itemMetadatum.metadatum.description }}
|
||||
|
@ -121,7 +121,7 @@
|
|||
v-if="itemMetadatum.metadatum &&
|
||||
itemMetadatum.metadatum.description &&
|
||||
(
|
||||
(!$parent.hideHelpButtons && $parent.helpInfoBellowLabel) ||
|
||||
(!hideHelpButtons && helpInfoBellowLabel) ||
|
||||
(itemMetadatum.metadatum.description_bellow_name === 'yes')
|
||||
)">
|
||||
{{ itemMetadatum.metadatum.description }}
|
||||
|
@ -153,6 +153,9 @@
|
|||
itemMetadatum: Object,
|
||||
isCollapsed: true,
|
||||
hideCollapses: false,
|
||||
hideMetadataTypes: Boolean,
|
||||
hideHelpButtons: Boolean,
|
||||
helpInfoBellowLabel: Boolean,
|
||||
isLastMetadatum: false,
|
||||
metadataNameFilterString: '',
|
||||
isMobileScreen: false,
|
||||
|
|
|
@ -499,6 +499,9 @@
|
|||
v-if="enabledMetadata[index] == 'true'"
|
||||
:item-metadatum="itemMetadatum"
|
||||
:hide-collapses="hideCollapses"
|
||||
:hide-metadata-types="hideMetadataTypes"
|
||||
:hide-help-buttons="hideHelpButtons"
|
||||
:help-info-bellow-label="helpInfoBellowLabel"
|
||||
:is-collapsed="metadataCollapses[index]"
|
||||
@changeCollapse="onChangeCollapse($event, index)"/>
|
||||
|
||||
|
@ -953,7 +956,6 @@ export default {
|
|||
});
|
||||
},
|
||||
mounted() {
|
||||
|
||||
// Checks if only one type of document is allowed. In this case we preset document type
|
||||
if (!this.hideFileModalButton && this.hideTextModalButton && this.hideLinkModalButton)
|
||||
this.form.document_type = 'attachment';
|
||||
|
|
Loading…
Reference in New Issue