diff --git a/src/pages/UserHistorySavedSearchList.vue b/src/pages/UserHistorySavedSearchList.vue index 3435c69a18..4dc980fdd4 100644 --- a/src/pages/UserHistorySavedSearchList.vue +++ b/src/pages/UserHistorySavedSearchList.vue @@ -7,7 +7,7 @@ :key="event.id" class="user-history-saved-search-list__list__item d-inline-flex justify-content-between" > - + {{ event.name }} @@ -90,10 +90,6 @@ export default { AppliedSearchFiltersItem, UserHistorySaveSearchForm }, - filters: { - humanDate, - humanTime - }, props: { events: { type: Array @@ -125,8 +121,14 @@ export default { const ignored = ['from', 'size', 'sort', 'field'] return ignored.includes(name) || (name === 'q' && ['', '*'].includes(value)) }, + getSearchParamsFromURI(uri) { + return new URLSearchParams(uri.split('?').slice(1).pop()) + }, + getSearchParamsQuery(uri) { + return Object.fromEntries(this.getSearchParamsFromURI(uri)) + }, createFiltersFromURI(uri) { - const urlSearchParams = new URLSearchParams(uri.split('?').slice(1).pop()) + const urlSearchParams = this.getSearchParamsFromURI(uri) const filters = [] for (let [name, value] of urlSearchParams.entries()) { if (this.isIgnoredFilter({ name, value })) {