Fixes feature that displays only selected items and removes some unused functions.
This commit is contained in:
parent
7b2bdbb811
commit
8af7b37b9e
|
@ -2276,10 +2276,6 @@ export default {
|
|||
deep: true
|
||||
}
|
||||
},
|
||||
mounted() {
|
||||
if (this.highlightsItem)
|
||||
setTimeout(() => this.$eventBusSearch.highlightsItem(null), 3000);
|
||||
},
|
||||
created() {
|
||||
this.shouldUseLegacyMasonyCols = wp !== undefined && wp.hooks !== undefined && wp.hooks.hasFilter('tainacan_use_legacy_masonry_view_mode_cols') && wp.hooks.applyFilters('tainacan_use_legacy_masonry_view_mode_cols', false);
|
||||
},
|
||||
|
@ -2513,7 +2509,17 @@ export default {
|
|||
});
|
||||
},
|
||||
filterBySelectedItems() {
|
||||
this.$eventBusSearch.filterBySelectedItems(this.selectedItems);
|
||||
let newQuery = {
|
||||
postin: JSON.parse(JSON.stringify(this.selectedItems)),
|
||||
}
|
||||
|
||||
if ( this.$route.query['fetch_only'] )
|
||||
newQuery['fetch_only'] = this.$route.query['fetch_only'];
|
||||
|
||||
if ( this.$route.query['fetch_only_meta'] )
|
||||
newQuery['fetch_only_meta'] = this.$route.query['fetch_only_meta'];
|
||||
|
||||
this.$router.replace({ path: this.$route.path, query: newQuery });
|
||||
},
|
||||
openItem() {
|
||||
if (this.contextMenuItem != null) {
|
||||
|
|
|
@ -449,7 +449,7 @@
|
|||
},
|
||||
executeBulkEditionProcedure(criterion){
|
||||
let procedure = this.bulkEditionProcedures[criterion];
|
||||
console.log(procedure.newValue)
|
||||
|
||||
if (procedure.action === this.editionActions.redefine) {
|
||||
Object.assign(this.bulkEditionProcedures[criterion], { 'isExecuting': true });
|
||||
|
||||
|
|
|
@ -187,13 +187,6 @@ export default {
|
|||
cleanSelectedItems() {
|
||||
app.config.globalProperties.$store.dispatch('search/cleanSelectedItems');
|
||||
},
|
||||
async filterBySelectedItems(selectedItems) {
|
||||
await app.config.globalProperties.$router.replace({ path: app.config.globalProperties.$route.path, query: { postin: selectedItems } });
|
||||
},
|
||||
highlightsItem(itemId) {
|
||||
app.config.globalProperties.$store.dispatch('search/highlightsItem', itemId);
|
||||
this.updateURLQueries();
|
||||
},
|
||||
exitViewModeWithoutPagination() {
|
||||
app.config.globalProperties.$eventBusSearchEmitter.emit( 'exitViewModeWithoutPagination', true);
|
||||
},
|
||||
|
@ -251,6 +244,7 @@ export default {
|
|||
app.config.globalProperties.$store.dispatch('search/cleanFilterTags');
|
||||
app.config.globalProperties.$store.dispatch('search/cleanMetaQueries', { keepCollections: true });
|
||||
app.config.globalProperties.$store.dispatch('search/cleanTaxQueries');
|
||||
app.config.globalProperties.$store.dispatch('search/removePostIn');
|
||||
this.updateURLQueries();
|
||||
}
|
||||
}
|
||||
|
|
|
@ -183,7 +183,3 @@ export const cleanSelectedItems = ({ commit }) => {
|
|||
export const removeSelectedItem = ({ commit }, selectedItem ) => {
|
||||
commit('removeSelectedItem', selectedItem);
|
||||
};
|
||||
|
||||
export const highlightsItem = ({ commit }, itemId ) => {
|
||||
commit('setHighlightedItem', itemId);
|
||||
};
|
||||
|
|
Loading…
Reference in New Issue