Now metadata select list is updated in advanced search shortcut after a repository metadata is updated or created
This commit is contained in:
parent
ec8b1056c3
commit
7aab768b6d
|
@ -238,6 +238,24 @@
|
|||
this.searchAdvanced();
|
||||
}
|
||||
},
|
||||
mounted(){
|
||||
this.$root.$on('metadatumUpdated', (isRepositoryLevel) => {
|
||||
if(isRepositoryLevel) {
|
||||
this.metadataIsLoading = true;
|
||||
|
||||
this.fetchMetadata({
|
||||
collectionId: this.isRepositoryLevel ? false : this.$route.params.collectionId,
|
||||
isRepositoryLevel: this.isRepositoryLevel,
|
||||
isContextEdit: false,
|
||||
includeDisabled: false,
|
||||
isAdvancedSearch: true
|
||||
}).then((metadata) => {
|
||||
this.metadata = metadata;
|
||||
this.metadataIsLoading = false;
|
||||
});
|
||||
}
|
||||
});
|
||||
},
|
||||
created(){
|
||||
|
||||
this.metadataIsLoading = true;
|
||||
|
|
|
@ -319,6 +319,8 @@
|
|||
this.formErrors = {};
|
||||
this.formErrorMessage = '';
|
||||
this.closedByForm = true;
|
||||
|
||||
this.$root.$emit('metadatumUpdated', this.isRepositoryLevel);
|
||||
this.$emit('onEditionFinished');
|
||||
})
|
||||
.catch((errors) => {
|
||||
|
@ -353,6 +355,8 @@
|
|||
this.formErrors = {};
|
||||
this.formErrorMessage = '';
|
||||
this.closedByForm = true;
|
||||
|
||||
this.$root.$emit('metadatumUpdated', this.isRepositoryLevel);
|
||||
this.$emit('onEditionFinished');
|
||||
})
|
||||
.catch((errors) => {
|
||||
|
|
Loading…
Reference in New Issue