Merge branch 'release/0.17.3' of https://github.com/tainacan/tainacan into release/0.17.3
This commit is contained in:
commit
e4eb7f1f56
|
@ -276,7 +276,7 @@ export default {
|
|||
return this.selectedItems && this.selectedItems.length ? 1 : Math.ceil(Number(this.totalItems)/Number(this.maxItemsPerPage));
|
||||
},
|
||||
exposerBaseURL() {
|
||||
let baseURL = this.collectionId != undefined ? '/collection/' + this.collectionId + '/items/' : '/items/';
|
||||
let baseURL = this.collectionId ? '/collection/' + this.collectionId + '/items/' : '/items/';
|
||||
let currentParams = JSON.parse(JSON.stringify(this.$route.query));
|
||||
|
||||
// Removes Fetch Only
|
||||
|
|
|
@ -32,7 +32,7 @@ export const viewModesMixin = {
|
|||
}
|
||||
},
|
||||
mounted() {
|
||||
this.isSlideshowViewModeEnabled = this.enabledViewModes.findIndex((viewMode) => viewMode == 'slideshow') >= 0;
|
||||
this.isSlideshowViewModeEnabled = (this.enabledViewModes && Array.isArray(this.enabledViewModes)) ? (this.enabledViewModes.findIndex((viewMode) => viewMode == 'slideshow') >= 0) : false;
|
||||
},
|
||||
methods: {
|
||||
getItemLink(itemUrl, index) {
|
||||
|
|
|
@ -775,7 +775,7 @@
|
|||
const userPrefViewMode = this.$userPrefs.get(prefsViewMode);
|
||||
|
||||
let existingViewModeIndex = Object.keys(this.registeredViewModes).findIndex(viewMode => viewMode == userPrefViewMode);
|
||||
let enabledViewModeIndex = this.enabledViewModes.findIndex((viewMode) => viewMode == userPrefViewMode);
|
||||
let enabledViewModeIndex = (this.enabledViewModes && Array.isArray(this.enabledViewModes)) ? this.enabledViewModes.findIndex((viewMode) => viewMode == userPrefViewMode) : -1;
|
||||
if (existingViewModeIndex >= 0 && enabledViewModeIndex >= 0)
|
||||
this.$eventBusSearch.setInitialViewMode(userPrefViewMode);
|
||||
else
|
||||
|
|
Loading…
Reference in New Issue