From 791be12c074e5f5e77989f170e1a36c726e75f9a Mon Sep 17 00:00:00 2001 From: Lukas_Skywalker Date: Wed, 22 May 2024 10:01:35 +0200 Subject: [PATCH] WPC-1419: Fix search for multiple search terms When searching for multiple terms, the search should only match articles where all of the terms are present. This was changed in the frontend in https://hauptstadt.atlassian.net/browse/HA-176 and then later in the backend in https://wepublish.atlassian.net/browse/WPC-1419 by adding an ampersand. When both fixes are run, the search terms are broken and the search produces invalid SQL. This change removes the ampersand injection in the frontend. --- components/navigation/header/menu/MenuRubricEntries.vue | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/components/navigation/header/menu/MenuRubricEntries.vue b/components/navigation/header/menu/MenuRubricEntries.vue index 253f02e..ae7dc0a 100644 --- a/components/navigation/header/menu/MenuRubricEntries.vue +++ b/components/navigation/header/menu/MenuRubricEntries.vue @@ -75,8 +75,7 @@ export default Vue.extend({ if (activeElement) { activeElement.blur() } - const preparedSearchQuery = this.searchQuery.replace(' ', ' & ') - const link = `/p/search?query=${preparedSearchQuery}` + const link = `/p/search?query=${this.searchQuery}` this.searchQuery = '' await this.$router.push(link) this.$store.commit('navigation/closeMenu')