Checks if metadata is repository level before deleting it on store.
This commit is contained in:
parent
b080a40111
commit
1dc9340b5d
|
@ -103,7 +103,7 @@
|
|||
:class="{'is-loading': runButtonLoading}"
|
||||
@click.prevent="runExporter()"
|
||||
:disabled="!formIsValid()"
|
||||
class="button is-pulled-right is-turquoise5">
|
||||
class="button is-pulled-right is-success">
|
||||
{{ $i18n.get('run') }}
|
||||
</button>
|
||||
</div>
|
||||
|
|
|
@ -190,7 +190,7 @@ export default {
|
|||
}
|
||||
}
|
||||
.document-buttons-row {
|
||||
bottom: -6px;
|
||||
bottom: -12px;
|
||||
left: 0.875em;
|
||||
position: absolute;
|
||||
}
|
||||
|
|
|
@ -179,8 +179,7 @@ export const deleteMetadatum = ({commit}, {collectionId, metadatumId, isReposito
|
|||
axios.tainacan.delete(endpoint)
|
||||
.then(res => {
|
||||
const metadatum = res.data;
|
||||
|
||||
if (metadatum.metadata_section_id)
|
||||
if (metadatum.metadata_section_id && !isRepositoryLevel)
|
||||
commit('deleteMetadatumInsideMetadataSection', metadatum)
|
||||
else
|
||||
commit('deleteMetadatum', metadatum);
|
||||
|
|
Loading…
Reference in New Issue