Fixes ternary operator causing wrong concatenation of fetch_only attributes for creation+date and author_name.
This commit is contained in:
parent
2655c0256d
commit
cf102d0f31
|
@ -1044,13 +1044,13 @@
|
|||
let authorNameMetadatum = this.localDisplayedMetadata.find(metadatum => metadatum.slug == 'author_name');
|
||||
|
||||
let descriptionMetadatum = this.localDisplayedMetadata.find(metadatum => metadatum.metadata_type_object != undefined ? metadatum.metadata_type_object.related_mapped_prop == 'description' : false);
|
||||
|
||||
|
||||
// Updates Search
|
||||
this.$eventBusSearch.addFetchOnly(
|
||||
thumbnailMetadatum != undefined && thumbnailMetadatum.display ? 'thumbnail' : null +','+
|
||||
creationDateMetadatum != undefined && creationDateMetadatum.display ? 'creation_date' : null +','+
|
||||
authorNameMetadatum != undefined && authorNameMetadatum.display ? 'author_name': null +','+
|
||||
(this.isRepositoryLevel ? 'title' : null) +','+
|
||||
((thumbnailMetadatum != undefined && thumbnailMetadatum.display) ? 'thumbnail' : null) + ',' +
|
||||
((creationDateMetadatum != undefined && creationDateMetadatum.display) ? 'creation_date' : null) + ',' +
|
||||
((authorNameMetadatum != undefined && authorNameMetadatum.display) ? 'author_name': null) + ',' +
|
||||
(this.isRepositoryLevel ? 'title' : null) + ',' +
|
||||
(this.isRepositoryLevel && descriptionMetadatum.display ? 'description' : null), false, fetchOnlyMetadatumIds.toString());
|
||||
|
||||
// Closes dropdown
|
||||
|
|
|
@ -189,6 +189,7 @@ export default {
|
|||
}
|
||||
},
|
||||
addFetchOnly( metadatum, ignorePrefs, metadatumIDs ){
|
||||
|
||||
this.$store.dispatch('search/add_fetch_only', metadatum );
|
||||
this.$store.dispatch('search/add_fetch_only_meta', metadatumIDs);
|
||||
this.updateURLQueries();
|
||||
|
|
Loading…
Reference in New Issue